Skip to navigation

Create Plaid Link Token

View as Markdown

Available to: All authenticated users

Environments: Live

Rate Limit: No endpoint-specific limit

Create the token your client uses to initialize Plaid Link. The service associates the token with the authenticated user, so you don’t need to provide userId.

Omit achApplicationId to start a new connection. To repair a connection whose ACH application has the RequiresRelink status, provide that application’s ID. The application must belong to the authenticated user. In relink mode, the token updates the existing Plaid item instead of requesting a new connection.

The platform-specific fields are optional:

  • Set redirectUri for a browser or iOS OAuth return flow. Register the value in NinjaTrader’s Plaid configuration before using it.
  • Set androidPackageName for an Android app-link flow, and omit redirectUri. Register the package name in NinjaTrader’s Plaid configuration before using it.
  • Omit both fields when the client flow doesn’t use them.

The platform fields are mutually exclusive; never send both. NinjaTrader forwards each supplied value to Plaid without first checking whether Plaid accepts or has registered it, so an unregistered or unsupported value produces Plaid’s generic token-request error. Pass the response’s token to the client-side Plaid Link SDK.

Warning: Business failures return HTTP 200 with errorText and no token. Check errorText before initializing Plaid Link.

Common Failure Scenarios

  • The relink application doesn’t exist or doesn’t belong to the authenticated user.
  • Plaid rejects the token request or is temporarily unavailable.
  • The request is sent to the Demo environment.

Error Messages

MessageResponseTrigger
"ACH Application doesn't belong to user."200 (in errorText)achApplicationId belongs to another user.
"ACH application not found."200 (in errorText)achApplicationId doesn’t match an application visible to the authenticated user.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Request

This endpoint expects an object.
userIdlongOptional
androidPackageNamestringOptional<=64 characters
redirectUristringOptional<=8192 characters
achApplicationIdlongOptional

Response

PlaidLinkTokenResponse
errorTextstringOptional<=8192 characters

Non-empty if the request failed

tokenstringOptional<=8192 characters