Typescript sdkCredentials
Keychain
Copy page
Keychain is the default method for storing credentials for every project. It is a locally stored credential store for OAuth tokens from OAuth2.1/PKCE flows and Bearer authentication, configured through Visual Builder and referenced in the TypeScript SDK.
Warning
Keychain lacks automatic token refresh, production suitability, and metadata header support, making Nango the recommended solution for production-ready credential management. See setup instructions for Nango here.
Referencing credentials in SDK
Here is an example of how to reference a credential in the TypeScript SDK for both Bearer Authentication and OAuth2.1/PKCE.
Credential Configuration
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Unique identifier for the credential |
type | CredentialStoreType | Yes | Type of credential store (memory, nango, or keychain) |
credentialStoreId | string | Yes | Identifier for the specific credential store instance |
retrievalParams | object | Yes | Parameters for retrieving the credential from the store. |