Curious about A, B, C, and D drives? Learn what they mean and how to use them effectively with Dropbox in this handy guide! - check it out now!

Forum Discussion

Andika Scofield's avatar
Andika Scofield
Explorer | Level 4
4 years ago
Solved

Error (400) when open dropbox (request URL)

Hello,

 

I found a problem when trying to request URL.

I have two apps in dropbox:

  1.  App 1 (status=production), use Permission type = Full Dropbox

  2. App 2 (status=development), use Permission type = Scope App

 

I've implemented short-lived token in App 2 (Scope App). I add all scope in scope requests according to permission in App 2.

DBScopeRequest *scopeRequest = [[DBScopeRequest alloc] initWithScopeType:DBScopeTypeUser
                                                                    scopes:@[@"account_info.read", "files.metadata.write", "files.metadata.read", "files.content.write", "files.content.read", "sharing.write", "sharing.read", "file_requests.write", "file_requests.read", "contacts.write", "contacts.read"]
                                                      includeGrantedScopes:NO];

When use the code above, my app success to show the login page.

But when I use the code above to App 1 (Full Dropbox). I get the error page ("scope": must be at most 0 characters, got 192)

 

Why that's happened? is it because App 1 is already "full dropbox"?
I've tried to delete all scope in scope requests, and can open sign in page. Can you explain?

  • Greg-DB's avatar
    Greg-DB
    4 years ago

    Yes, Dropbox is in process of migrating all apps to use scopes. This is a backwards compatible migration; scoped apps can use all of the same functionality as non-scoped apps. Scopes just offer more granularity in the control over which functionality you enable for the app. You can find more information on the migration in this blog post.

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

    You can only specify 'scopes' when using an app that is registered as a "scoped" app. Your app 1 is not scoped, so you can't specify scopes for it. You should migrate it to be a scoped app via the "Permissions" tab of the app's page on the App Console.

    • Andika Scofield's avatar
      Andika Scofield
      Explorer | Level 4
      Is this an obligation to migrate from "full dropbox" into "scoped app"?
      • Greg-DB's avatar
        Greg-DB
        Icon for Dropbox Staff rankDropbox Staff

        Yes, Dropbox is in process of migrating all apps to use scopes. This is a backwards compatible migration; scoped apps can use all of the same functionality as non-scoped apps. Scopes just offer more granularity in the control over which functionality you enable for the app. You can find more information on the migration in this blog post.