cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to learn some quick and useful tips to make your day easier? Check out how Calvin uses Replay to get feedback from other teams at Dropbox here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Re: Authorization and unattended batch process

Authorization and unattended batch process

GlennAlligator
Helpful | Level 6
Go to solution

Is it possible to return an access token without human intervention during the authorization process?  I am writing a batch process to be run on a server that connects to a dropbox app with AppKey:AppSecret and checks for newly created files and copy them to a server and record the file details.  However, it seems that the decision to authorise and send an access key cannot be automated and requires the owner to press something.  Am I being particularly stupid and missing something obvious?

Thanks in advance

Glenn

 

1 Accepted Solution

Accepted Solutions

GlennAlligator
Helpful | Level 6
Go to solution

Yes got it working now.  I thought the access token would only have a very short persistence and that it needed to be rebuilt for every session.  As the access token never expires that will work great.

Thanks

 

View solution in original post

5 Replies 5

TaylorKrusen
Dropbox Staff
Go to solution

Hi Glenn, 

You can't return an access token without some element of human approval. Almost all  OAuth Flow implementations require that a user gives consent to share their data with your application. 

 

GlennAlligator
Helpful | Level 6
Go to solution

Thanks for your reply Taylor.

Yes, this is how it looks so I'll have to find another way.  Many Implementations of the Implicit mode include X509 certificates which I think gives you better security than just relying on  Key/Secret pair.  I know that Implicit mode is frowned upon generally but so many processes are run as back-end server batches which by the very nature are unattended and run at 2 o'clock in the morning.  I don't mind jumping thru as many software hoops as might be required but to not have a way of setting up unattended server batches is a major failing in dropbox.

TaylorKrusen
Dropbox Staff
Go to solution

Hi Glenn, 

Is there a specific reason that your application needs to reconnect with the Dropbox app every time the script runs?

Generally speaking, most integrations would use a stored Access Token in order to run their script and automate the collection of data. OAuth Flows are really only necessary when you need users to explicitly authorize your app to use their data. 

GlennAlligator
Helpful | Level 6
Go to solution

Yes got it working now.  I thought the access token would only have a very short persistence and that it needed to be rebuilt for every session.  As the access token never expires that will work great.

Thanks

 

TaylorKrusen
Dropbox Staff
Go to solution

Excellent! Happy to hear that. 

Please feel free to post again if another question come up in the future!

Need more support?