Skip to content
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

Reconnect API not supported, renewing tokens is not possible #11

Open
jneves opened this issue Sep 12, 2014 · 0 comments
Open

Reconnect API not supported, renewing tokens is not possible #11

jneves opened this issue Sep 12, 2014 · 0 comments

Comments

@jneves
Copy link

jneves commented Sep 12, 2014

Hi, just a quick note that the reconnect API at https://developer.intuit.com/docs/0025_quickbooksapi/0053_auth_auth/oauth_management_api is not supported on the library. Each access token has a lifetime of 180 days and within 30 days before expiration you need to access this API with the old access token to renew it.

I'll probably be implementing this. Quick example of access to the API (copy & pasted from a project):

client = QuickBooks(consumer_key=settings.QB_OAUTH_ID,consumer_secret=settings.QB_OAUTH_SECRET,callback_url=settings.QB_OAUTH_URL,access_token=account.access_token,access_token_secret=account.access_token_secret,company_id=account.realm_id)
session = client.create_session()
r = session.get('https://appcenter.intuit.com/api/v1/connection/reconnect')

Currently I need to record when the access token is created, so that I now if it's in the 30-day renew window and to parse the XML response from this API in order to extract the new access token and secret.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant