Authorization

Harness
Prerequisites
To connect Nexla to Harness, you need a Harness API key and token. Harness supports two types of API tokens: Personal Access Tokens (PATs), which are associated with individual user accounts, and Service Account Tokens (SATs), which are associated with service accounts and are recommended for automated integrations such as Nexla.
Harness uses the x-api-key header to authenticate all API requests. The token you create must have appropriate permissions to access the Harness resources you intend to use with Nexla.
Option A: Create a Personal Access Token (PAT)
Personal Access Tokens are scoped to your individual Harness user account and inherit your account's permissions. Use a PAT for development or testing purposes, or when the integration requires access to resources visible to your user account.
-
Sign in to your Harness account at app.harness.io.
-
Select My Profile from the left-hand navigation menu.
-
Under the My API Keys section, click + API Key.
-
Enter a descriptive Name for the API key (for example,
Nexla Integration). The Description and Tags fields are optional. -
Click Save to create the API key.
-
Within the newly created API key tile, click + Token.
-
Enter a Name for the token, set an optional Expiration Date aligned with your organization's security policies, and then click Generate Token.
-
Copy the generated token value immediately and store it securely.
Harness does not store the token value after it is displayed. Copy the token before closing the dialog — if the token is lost, you must revoke it and generate a new one.
Option B: Create a Service Account Token (SAT)
Service Account Tokens are recommended for production integrations. They are not tied to an individual user account, which means the integration continues to function even when team members leave or change roles. Creating a service account token requires Account Admin permissions or a role that includes View, Create/Edit, Manage, and Delete permissions for service accounts.
-
Sign in to your Harness account at app.harness.io.
-
Navigate to Account Settings in the left-hand navigation menu.
-
Under the Access Control section, select Service Accounts.
-
Select the service account for which you want to create an API key, or click + New Service Account to create a dedicated service account for the Nexla integration.
-
Within the service account detail page, under API Keys, click + API Key.
-
Enter a descriptive Name for the API key and click Save.
-
Within the newly created API key tile, click + Token.
-
Enter a Name for the token, set an optional Expiration Date, and click Generate Token.
-
Copy the generated token value immediately and store it securely.
The service account token inherits the permissions of the service account it belongs to. Ensure the service account has been assigned roles that grant access to the Harness resources (pipelines, deployments, feature flags, etc.) that Nexla will read from or write to. For complete information about configuring service account permissions, see the Harness Service Accounts documentation.
Locate Your Harness Account Identifier
Some Harness API calls require your Account Identifier as a query parameter. To find it:
-
Sign in to Harness and navigate to Account Settings.
-
Under Account Overview, your Account Id is displayed. Copy this value for use when constructing API endpoint URLs.
Create a Harness Credential
- To create a new Harness credential, after selecting the data source/destination type, click the Add Credential tile to open the Add New Credential overlay.
Credential Name & Description
-
Enter a name for the credential in the Credential Name field and a short, meaningful description in the Credential Description field.
Resource descriptions are recommended but are not required. They should be used to provide information about the resource purpose, data freshness, etc. that can help the owner and other users efficiently understand and utilize the resource.
API Key
-
Enter your Harness API token (PAT or SAT) in the API Key field. This token authenticates all Nexla requests to the Harness REST API. Nexla will include this token in the
x-api-keyheader with each API call.Keep your API token secure. Treat it as you would a password — do not share it or commit it to source control. You can revoke and regenerate tokens at any time from your Harness profile or the service account settings page.
Save the Credential
-
Once all of the relevant steps in the above sections have been completed, click the Save button at the bottom of the overlay to save the configured credential.
-
The newly added credential will now appear in a tile on the Authenticate screen during data source/destination creation and can be selected for use with a new data source or destination.