Skip to navigation

Quickstart

Get Whitelabel API access, send the right headers and make your first call on staging.
View as Markdown

This page takes you from a Transak API key to your first successful Whitelabel API call. It then lists the calls you make to place your first order.

Before you start

You need:

  • A partner account on the Transak Partner Dashboard. See How To Create a Partner Dashboard Account.
  • Your API Key, from the Developers tab of the dashboard. Use the staging API key on staging and the production API key on production.
  • A backend server. Whitelabel API calls must come from your backend, never from a browser or mobile app.

Step 1: Get access

1

Ask Transak to enable the Whitelabel API for your API key

Your API key must be enabled for the Whitelabel API before the calls work. See What does it take to get access to the Whitelabel API? for the commercial terms, and Need help in Integration for how to reach the team.

2

Send your backend IP addresses for allowlisting

Transak only accepts Whitelabel API calls from allowlisted IP addresses. Share your backend’s static egress IP addresses for both staging and production. See Mandatory Security Changes.

Step 2: Pick the base URL

EnvironmentBase URL
Staginghttps://api-gateway-stg.transak.com
Productionhttps://api-gateway.transak.com

Build and test on staging first. Staging KYC checks are dummy checks and always approve the user. See How to Test Using Sandbox Credentials for test users and payment details.

Step 3: Send the required headers

Send these headers on every call:

HeaderValue
x-api-keyYour partner API key.
x-user-ipThe IP address of the end user you are calling for. See User IP Header in APIs.

Calls made for a logged-in user also need one of these two ways to authenticate the user. Use one or the other, never both:

MethodHeadersToken
Transak AuthauthorizationThe user’s accessToken from Verify User OTP, sent on its own with no Bearer prefix. It is valid for 30 days. Renew it with Refresh User Access Token before it expires.
Partner Auth (Auth Reliance)x-access-token and x-user-identifierYour Partner Access Token, valid for 7 days. See How to Create a Partner Access Token. x-user-identifier is the email address of the user you authenticated. See Auth Reliance.

Lookup calls, such as Get Quote for a user who isn’t logged in, need only x-api-key and x-user-ip. Each endpoint page in the API reference lists the headers it takes.

Step 4: Make your first call

Get a price quote on staging for 50 GBP of USDC on Ethereum, paid by bank transfer. Get Quote also takes your API key as the apiKey query parameter.

Get Quote
curl -G https://api-gateway-stg.transak.com/api/v2/lookup/quotes \
-H 'x-api-key: YOUR_API_KEY' \
-H 'x-user-ip: USER_IP_ADDRESS' \
-d apiKey=YOUR_API_KEY \
-d fiatCurrency=GBP \
-d cryptoCurrency=USDC \
-d isBuyOrSell=BUY \
-d network=ethereum \
-d paymentMethod=gbp_bank_transfer \
-d fiatAmount=50

A successful call returns 200 with a quote:

Response
{
"data": {
"feeBreakdown": [
{ "name": "Transak fee", "value": 1, "id": "transak_fee" },
{ "name": "Network/Exchange fee", "value": 0, "id": "network_fee" }
],
"termsIds": [],
"quoteId": "ea57d316-098a-4ead-8300-266a6d5bed5e",
"conversionPrice": 1.1272686386059025,
"slippage": 0.53,
"fiatCurrency": "GBP",
"cryptoCurrency": "USDC",
"paymentMethod": "gbp_bank_transfer",
"fiatAmount": 50,
"cryptoAmount": 55.24,
"isBuyOrSell": "BUY",
"network": "ethereum",
"networkId": "",
"feeDecimal": 0.02,
"totalFee": 1,
"nonce": 1747890325
}
}

If the call fails, check the errorCode in the response against Error Codes. The API allows 40 requests per IP address every 10 seconds. See What are the rate limits on the Whitelabel APIs?

Step 5: Place your first order

These are the calls for a first bank transfer order. The Whitelabel API overview has the full flow for each payment method.

1

Look up what the user can buy

Get Countries, Get Fiat Currencies and Get Crypto Currencies return the supported countries, payment methods, cryptocurrencies and networks.

2

Get a quote

Call Get Quote and keep the quoteId. For US, EEA and UK users, show the disclaimers in termsIds. See How to Display Disclaimers in Your API Integration.

3

Log the user in

With Transak Auth, call Send User OTP and Verify User OTP to get the user’s accessToken. With Partner Auth (Auth Reliance), call Onboard User for a new user.

4

Complete KYC

Call Get KYC Requirement with the quoteId, then submit what it asks for, starting with Patch User Details.

5

Create the order

Check for an existing order with Get Active Orders, then call Create Order with the quoteId and the user’s wallet address.

6

Track the order

Call Get Order By ID, or receive order webhooks. See How to Track Order Status.

Before you go live