# Dropbox API token expiration

**URL:** <https://community.n8n.io/t/dropbox-api-token-expiration/39690>\
**Category:** Questions\
**Tags:** dropbox\
**Created:** [February 4, 2024, 10:10am UTC](https://community.n8n.io/t/dropbox-api-token-expiration/39690 "2024-02-04T10:10:15Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Oleg\_Zvyagintsev](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/oleg_zvyagintsev/32/34980_2.png) [@Oleg\_Zvyagintsev](https://community.n8n.io/u/Oleg_Zvyagintsev)\
**Post date:** [February 4, 2024, 10:10am UTC](https://community.n8n.io/t/dropbox-api-token-expiration/39690/1 "2024-02-04T10:10:15Z")

</div>

## Question

Dropbox only allows shortlived API tockens (4 hours according to their article). And they say you need to use refresh tokens to use it without manually refreshong tokens.

How to deal with expiring tokens in n8n?

Right now I want to make automatic backups of my workflow daily, but that’s impossible for me without going and manually refreshing the token. But it’s more general qusetion, I just want n8n has continious access to my dropbox.

Is that even possible for me to figure out if I’m not a dev?

## Workflow (it’s working well, problem is expiration)

## Information on your n8n setup

- **n8n version:** 1.26.0
- **Database (default: SQLite):** default: SQLite
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):** default: own, main
- **Running n8n via (Docker, npm, n8n cloud, desktop app):** Docker
- **Operating system:** Ubuntu

---

<div class="post-metadata">

**Author:** ![n8n](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/n8n/32/196425_2.png) [@n8n](https://community.n8n.io/u/n8n)\
**Post date:** [February 4, 2024, 10:10am UTC](https://community.n8n.io/t/dropbox-api-token-expiration/39690/2 "2024-02-04T10:10:16Z")

</div>

It looks like your topic is missing some important information. Could you provide the following if applicable.

- **n8n version:**
- **Database (default: SQLite):**
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):**
- **Running n8n via (Docker, npm, n8n cloud, desktop app):**
- **Operating system:**

---

<div class="post-metadata">

**Author:** ![liam](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/liam/32/34968_2.png) [@liam](https://community.n8n.io/u/liam)\
**Post date:** [February 4, 2024, 7:54pm UTC](https://community.n8n.io/t/dropbox-api-token-expiration/39690/3 "2024-02-04T19:54:26Z")

</div>

You should go through the OAuth2 setup. That’s the most secure way anyway.

It can seem hard at first but they’re all set up a similar way. There is no code, just a setup process.  
Here are the steps for dropbox

## Go to [this site](https://dropbox.com/developers/apps) and create an app

 ![step-0](https://europe1.discourse-cdn.com/n8n/original/3X/3/b/3bd1640411925395f65a8b9ba253dbe97533f032.jpeg)

## Select these options and press create app

 ![step-1](https://europe1.discourse-cdn.com/n8n/original/3X/3/f/3fe5cd3f1f69d7a4c854f56af0d6600a691ea376.jpeg)

## Under the permissions tab, select all the scopes you want and press submit

 ![step-2](https://europe1.discourse-cdn.com/n8n/original/3X/a/e/ae28edf0462898dceb98e6a824f8d3263d30183d.jpeg)  
It won’t save without pressing submit

## In your n8n connector, copy the uri redirect link

Make sure you’re in the 0Auth2 Setup

 ![step-3](https://europe1.discourse-cdn.com/n8n/original/3X/0/e/0e63152d2ae3c1c6f60066126dab7ae5deaa0ffa.jpeg)

## Back in the setting tab on dropbox, Paste it in the URI box on dropbox and press add

 ![step-4](https://europe1.discourse-cdn.com/n8n/original/3X/a/0/a093fdf1a0501defe68a627ec62c711845142273.jpeg)

## Copy and paste the keys then click connect my account

App key to Client ID and App Secret to Client Secret  
IMPORTANT: Keep these private, these are the same as passewords

 ![step-5](https://europe1.discourse-cdn.com/n8n/original/3X/0/f/0fc38c8100edb574b6c931d041a14adda2dfa82d.jpeg)

## Press continue and allow then you’re good to go

 ![step-6](https://europe1.discourse-cdn.com/n8n/original/3X/3/a/3ab22332ccc0a814a1c049658713dd700cabecb6.jpeg)

 ![step-7](https://europe1.discourse-cdn.com/n8n/original/3X/9/c/9cee3721b17d70c032cd5e315d942770864fbb17.jpeg)

You should now have oauth all setup now.  
If it doesnt work try deleting your old dropbox credentials

---

<div class="post-metadata">

**Author:** ![Oleg\_Zvyagintsev](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/oleg_zvyagintsev/32/34980_2.png) [@Oleg\_Zvyagintsev](https://community.n8n.io/u/Oleg_Zvyagintsev)\
**Post date:** [February 8, 2024, 11:57am UTC](https://community.n8n.io/t/dropbox-api-token-expiration/39690/4 "2024-02-08T11:57:32Z")

</div>

Thank you Liam, works wonderfully.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/system/32/195824_2.png) [@system](https://community.n8n.io/u/system)\
**Post date:** [February 15, 2024, 11:58am UTC](https://community.n8n.io/t/dropbox-api-token-expiration/39690/5 "2024-02-15T11:58:31Z")

</div>

Closed on February 15, 2024, 11:58am UTC

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
