GetOAuthAccessToken
Retrieves the OAuth access token required for authenticating API requests to HubSpot.
Input
| Name | Type | Description |
| AuthMode | String | The type of authentication you are attempting. Use App for a Windows application, or Web for Web-based applications.
The allowed values are APP, WEB. The default value is APP. |
| RequiredScopes | String | List of required scopes your app needs access to. These must match the scopes marked as required in your HubSpot app settings. |
| OptionalScopes | String | Additional scopes your app will request but does not depend on. These are ignored if the HubSpot account does not support them. |
| CallbackUrl | String | The URL the user will be redirected to after authorizing your application. |
| Verifier | String | A verifier returned by the service that must be input to return the access token. Needed only when using the Web auth mode. Obtained by navigating to the URL returned in GetOAuthAuthorizationUrl. |
| State | String | This field indicates any state that may be useful to your application upon receipt of the response. Your application receives the same value it sent, as this parameter makes a round-trip to Dynamics authorization server and back. Uses include redirecting the user to the correct resource in your site, using nonces, and mitigating cross-site request forgery. |
Result Set Columns
| Name | Type | Description |
| OAuthAccessToken | String | The OAuth Access Token. |
| OAuthRefreshToken | String | A token that may be used to obtain a new access token. |
| ExpiresIn | String | The remaining lifetime for the access token. |