CData BizTalk Adapter for QuickBooks Online 2019 - Online Help
Questions / Feedback?

Creating a Custom OAuth App

CData BizTalk Adapter for QuickBooks Online 2019 - Build 19.0.7354

Intuit uses the OAuth authentication standard. If your developer account has created apps before July 17, 2017, any apps created by that account, including future apps and apps under development now, will use OAuth 1.0a. If your developer account has not created any apps until after July 17, 2017, all apps created by that account will use OAuth 2.0. OAuth requires the authenticating user to interact with QuickBooks Online using the browser. Follow the steps below to obtain the OAuth values.

Authenticate to QuickBooks Online in a Desktop Application

After setting the following connection properties, you are ready to connect:

The adapter is already registered as an OAuth application with QuickBooks Online and has embedded OAuth credentials. If you wish to create your own OAuth app, refer to the Advanced Settings section.

  • OAuthClientId: Leave this blank to use the embedded credentials, otherwise use the consumer key in your app settings.
  • OAuthClientSecret: Leave this blank to use the embedded credentials, otherwise use the consumer secret in your app settings.
  • CallbackURL: Leave this blank to use the embedded credentials, otherwise use the Launch URL in your app settings.
  • OAuthVersion: Set the OAuth version.
  • InitiateOAuth: Set this to GETANDREFRESH. You can use InitiateOAuth to avoid repeating the OAuth exchange and manually setting the OAuthAccessToken and OAuthAccessTokenSecret in case of OAuth 1.0, or OAuthAccessToken in case of OAuth 2.0.
When you connect the adapter opens the OAuth endpoint in your default browser. Log in and grant permissions to the application. The adapter then completes the OAuth process:
  1. Extracts the access token from the callback URL and authenticates requests.
  2. Refreshes the access token when it expires.
  3. Saves OAuth values in OAuthSettingsLocation to be persisted across connections.

Authenticate to QuickBooks Online in a Web Application

If you are connecting via a Web application, you will need to register your own OAuth app with QuickBooks Online. Refer to our Advanced Settings guide for more information.

To obtain the access token, set the following connection properties:

  • CompanyId: The unique identifier of a given company in QuickBooks Online.
  • OAuthClientId: The consumer key in your app settings.
  • OAuthClientSecret: The consumer secret in your app settings.
  • CallbackURL: The Launch URL in your app settings.
  • OAuthVersion: Set the OAuth version.

When connecting via a Web application, or if the adapter is not authorized to open a browser window, you will need to exchange a verifier code for the OAuthAccessToken:

  1. Call GetOAuthAuthorizationURL. The stored procedure returns the URL to the OAuth endpoint.
  2. Log in and authorize the application. You are redirected back to the callback URL.

    The callback URL contains the verifier code in a query string parameter named "code". Extract the verifier code from the callback URL.

  3. Call GetOAuthAccessToken.

Set the following connection properties to connect to data:

  • CompanyId
  • OAuthVersion
  • OAuthClientId
  • OAuthClientSecret
  • OAuthAccessToken

 
 
Copyright (c) 2020 CData Software, Inc. - All rights reserved.
Build 19.0.7354.0