-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Decoder failed to handle oauth_token with data as returned by provider. A different decoder may be needed. Provider returned: oauth_problem=permission_unknown #8
Comments
Hey @rubinovitz, sorry I didn't get back to you on this earlier - did you ever sort this out? I remember regularly having issues with Quickbooks and permissions. Once in a while it would just shut down on me. I'll have a look at my own code and see if I can reproduce this. |
Haven't found a fix so far. On Wed, Jul 23, 2014 at 7:33 AM, Simon [email protected] wrote:
Jennifer Rubinovitz |
Okay, I've been able to create that same error message, and I will freely admit that how I deal with this step myself feels like a hack. So, I get this error message when I do this:
What's happening in my case is that the service I set up to create the request, is no longer the same service one. Have a look there? The way that I have it working is:
It might make sense to separate out the get_service procedure and the get_authorize_url procedure, just to make that distinction clearer. In Django I'm doing this between views using a global object. It's not ideal. |
Functionality should be separate for the two, but get_authorize_url sets up a service if there isn't one already Brought up because of issue #8
I'm getting a new error now that I'm using a global object. Maybe I'm doing the process wrong.
Then I get the following error: KeyError: 'Decoder failed to handle oauth_token with data as returned by provider. A different decoder may be needed. Provider returned: oauth_problem=parameter_rejected&oauth_parameters_rejected=oauth_token' |
It looks like you're setting up a new service on the second to last line. If you already have your oauth token, I think you shouldn't need to do that again. Can you try just calling |
I set up the new service because when I skip the .set_up_service() step I
On Tue, Jul 29, 2014 at 4:49 AM, Simon [email protected] wrote:
Jennifer Rubinovitz |
That's weird. get_authorize_url() sets a service token on the qbObject if one doesn't already exist. I can't see what would unset that service and turn it into a NoneType. Is there a way for you to check that the two qb objects are the same - it might be a scope issue, where you have a local qb object that has been changed within one method, but that change hasn't been reflected to the global qb object so available to the method on the other side of the authorized URL? |
Okay it was an issue with my grantUrl in my javascript once I made the QB object global. Sorry about that. Now I'm just getting a 401 error whenever I make a query. |
I am having the same issue here. I think it would very helpful if somebody could update the readme.md with a working example. |
Hey @KobaKhit, the readme works fine for a Django application. What's the specific issue you're having a difficulty with - are you getting a 401 Unauthorized as well? What is your set up? @rubinovitz Are you getting a 401 Unauthorized from Quickbooks? Could you show me some code? |
Hello @simonv3, I am using a simple python script and Python 2.7.8 to query the quickbooks online.
Basically, once I access the authorization url the resulting url contains a token, a verifier, and a realm id. At this point I just copy paste because I simply want to make the api work. I was trying to follow your work flow, but could not figure out what |
Okay, so there does indeed seem to be something wrong. Are you raising the If that's what you're getting, then I think you've done oAuth right, and you got the right access tokens, etc. I think the problem is with how the sessions is managed. At the moment I don't have a lot of time to track this down much further, especially if it's a problem with Quickbooks, though I would love it if anyone could look into this more. I'll happily accept pull requests and test them. Note, you should still be able to query QBs, you'll just have to do it without the helper functions until someone figures that out: For example, this worked for me:
|
Yes, that exception gets raised. I'll look into session management, I On Wed, Aug 13, 2014 at 11:53 AM, Simon [email protected] wrote:
Jennifer Rubinovitz |
So I had that issue as well. I don't know if you guys still have those problems but here's my solution. So in general, we wouldn't need to use |
I'm redirecting to the url given by .get_authorization_url() and getting an oauth_token and oauth_verifier back, but when I try to send the oauth_verifier through .get_access_tokens() I get the following rauth error:
Does anyone know what's up?
The text was updated successfully, but these errors were encountered: