cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Back again with another edition of 'How we use Dropbox', so find out how Emma uses to-do lists to get it all done 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: 

app secret and and app key no longer working?

app secret and and app key no longer working?

Apostolos A.
New member | Level 1

Hello, 

while playing with the following initialization function:

 [[DBSession alloc]

                                initWithAppKey: [Constants dropboxAppKey]

                                appSecret: [Constants dropboxAppSecret]

                                root:kDBRootAppFolder]; 

 

for once I supplied the correct appSecret with an invalid appKey to see how it will behave. It gave a 400 error but then when I restored the correct appKey, it no longer worked.

I am sure the problem is not on my side, because I reverted to older code which was working and still could not get past the authentication.

Do you have any security measures that disable the auth on wrong combinations?

Do I have to ask for new credentials ?

9 Replies 9

Re: app secret and and app key no longer working?

Greg-DB
Dropboxer

If you reverted back to the correct values, there wouldn't be any reason to still receive an error.

Can you share the full error/output that you're currently getting?

I also recommend logging out the values of Constants dropboxAppKey and Constants dropboxAppSecret to make sure they're what you expect. (Don't post your app secret though.)

Re: app secret and and app key no longer working?

Apostolos A.
New member | Level 1

The error I get is this:

[WARNING] DropboxSDK: error making request to /1/account/info - (400) invalid_request

 

i double checked the values against my app page and even reverted to older versions of my code where the app was definitely working.

Re: app secret and and app key no longer working?

Greg-DB
Dropboxer

Can you share the code you're using to check the values? Also, when/where are you checking them? Maybe they're getting altered somewhere along the way. If you can share the output that may be helpful.

Also, please share the rest of the code for the actual API call you're making.

Re: app secret and and app key no longer working?

Apostolos A.
New member | Level 1

when I say double-check I myself am comparing to the ones that are on the "My apps" page. And they are correct, there is no chance that i give the wrong credentials. I am sure because i get the same error even when replacing the constant variables with literal strings.

the actual method i am calling is the following:

[self.restClient loadAccountInfo]

where restClient is an object called like this:

    self.restClient = [[DBRestClient alloc] initWithSession:[DBSession sharedSession]];

    self.restClient.delegate = self;

 

Re: app secret and and app key no longer working?

Greg-DB
Dropboxer

That code looks fine, and I haven't been able to reproduce this unfortunately. That being the case, can you share a small sample project that reproduces this so we can look into it? 

You can send it via an API ticket if you'd prefer to share it privately:

https://www.dropbox.com/developers/contact

Thanks in advance! 

Re: app secret and and app key no longer working?

Apostolos A.
New member | Level 1

OK, but how do I upload the project?

Also, if I can reproduce the error by a REST request, I guess I can send you the REST query.

 

Re: app secret and and app key no longer working?

Greg-DB
Dropboxer

Feel free to use a shared link to share the project.

If you can reproduce the error with a manual request, e.g., using curl or something, that would be fine too.

Re: app secret and and app key no longer working?

Apostolos A.
New member | Level 1

Ok done. The app secret is included in the API ticket, but there is no other way for you to test it. 

Re: app secret and and app key no longer working?

Greg-DB
Dropboxer

Thanks! We'll look into it and follow up with you in your ticket.

Poll
We love to learn from the educators who use Dropbox. Whether you teach kids, teens, adults or a combination of all three, we want to know what apps and integrations you use with Dropbox to help with teaching. Which of the ones below is your favorite, or most used tool?
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropboxer
  • User avatar
    Apostolos A. New member | Level 1
What do Dropbox user levels mean?
Need more support?