You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

GlennAlligator's avatar
GlennAlligator
Helpful | Level 6
6 years ago

Authorization and unattended batch process

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

 

  • 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

     

  • 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's avatar
      GlennAlligator
      Helpful | Level 6

      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's avatar
        TaylorKrusen
        Icon for Dropbox Staff rankDropbox Staff

        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. 

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,877 PostsLatest Activity: 5 hours ago
325 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!