1. Credentials
  2. Generic OAuth

Credentials

Generic OAuth

Explains how to create a Generic OAuth credential for authenticating with any OAuth-compatible API. Used in the Apicall task for client credentials OAuth flows.

Overview

The Generic OAuth credential can be used to authenticate with any API that supports OAuth client credentials. When created, the platform will immediately attempt to obtain an access token from the specified token URL. This credential can be used in the API Call task.

Fields

Field Required Description
Credential Name Yes A name to identify this credential.
Token URL Yes The URL where the access token can be obtained.
Client ID Yes The OAuth client ID.
Client Secret Yes The OAuth client secret.
Scope No The OAuth scope to request.
Grant Type Yes The OAuth grant type (e.g., client_credentials).
Client Authentication Method Yes Determines how the client ID and secret are sent — either in the request body or as a Basic Auth header.
Org Credentials No One or more orgcredentialuuid values (comma-separated) of existing credentials to attach to the token request. See Additional Credentials below.

Creating the Credential

  1. Navigate to the Credentials section of the manage platform.
  2. Click the
    + Create new item
    button.
  3. Select Generic OAuth from the credential type dropdown.
  4. Enter a Credential Name.
  5. Enter the Token URL.
  6. Enter the Client ID and Client Secret.
  7. Optionally, enter the Scope.
  8. Select the Grant Type.
  9. Select the Client Authentication Method.
  10. Click the
    Create
    button.

The platform will attempt to obtain an access token. If successful, the credential will be created and the token will be stored securely.

Additional Credentials

Some OAuth providers have custom requirements on their token endpoint — for example, requiring a custom x-api-key header alongside the standard OAuth parameters. The Org Credentials field handles these cases.

To use this:

  1. First, create the credential that satisfies the provider's extra requirement (e.g., a Custom Header credential with the required header key and value).
  2. Copy the orgcredentialuuid of that credential (see Getting an orgcredentialuuid).
  3. Paste it into the Org Credentials field when creating the Generic OAuth credential.

If multiple additional credentials are needed, provide them as comma-separated orgcredentialuuid values.

Access Tokens

The platform takes care of getting and refreshing the access token:

  • An access token is reused until it has less than 60 seconds left, based on the expires_in the token URL returns. After that, a new token is requested.
  • If the token URL does not return expires_in, the token is not reused, and a new token is requested every time the credential is used.
  • Saving or deleting the credential discards its current token, so changes such as a new client secret or scope take effect immediately.
  • In the API Call task, if a request using this credential gets a 401 Unauthorized response, a new token is requested and the request is retried once. See Retrying after a 401.
TIP

Attach this credential with org_credentials instead of putting a token in the Authorization header yourself. A token set in the headers is not refreshed by the platform, and requests start failing once it expires.