Authenticating

Keys and secrets

Once you log into the Dashboard, you will see an API Keys section in the left menu.
On that page, you will be able to view your unique Client ID for that Team. You will need this ID to use the Deck API. Along with the Client ID, you will also see secret keys that are unique to each 'Team - Environment' combination. At first, you will only see the Sandbox secret; you can request the Production secret by navigating to Settings in the left menu, then Billing in the submenu, before upgrading your plan.

Each secret is tied to a specific environment and must be used accordingly:

  • Use the sandbox secret with the Sandbox environment
  • Use the production secret with the Live environment

Once you have your keys from the Dashboard, you can choose which API server you wish to use:

Sandbox vs Live Diagram

By switching from one to the other using the button in the top right corner of every Job, the x-deck-client-id and x-deck-secret headers, as well as the subdomain, will automatically change in the API Usage code to reflect the environment you're intending to use.

If you're not using the Dashboard to make your calls, please remember to change them yourself.

Each environment also has its own subdomain:

EnvironmentURL
Sandboxhttps://sandbox.deck.co/api/v1
Livehttps://live.deck.co/api/v1

The Widget can communicate with both servers and will connect to the one corresponding to the secret you've used to generate a Link token.

⚠️ Important! ⚠️ Be sure to always use the secret corresponding to the API server you want to use. Using a production secret in a request to the Sandbox API, or using a sandbox secret in a request to the Live API, will result in a 401 Unauthorized response.