Last updated

Authentication

Trustap authenticates your API requests using an API key and a unique Client ID associated only with your account.

Trustap uses two environments for our API.

Production environment
https://dev.trustap.com/api/v1/
Test environment
https://dev.stage.trustap.com/api/v1/

Step 1: Contact Trustap

Use our contact form get in touch.

To help us understand your use case, tell us about who you are.

* What does your company do?
* What problem can Trustap solve for you?

Step 2: Receive Authentication credentials

Our support team will contact you with your credentials. These include the following.

  1. Your unique security API key <API_KEY>.
  2. Your Client ID <CLIENT_ID> and Client secret <CLIENT_SECRET>.
  3. Your webhook username <WEBHOOK_USER> and webhook password <WEBHOOK_PASS>.

Step 3: Use Authentication credentials

To make a call to the Trustap API, use this example replacing <API_KEY> with your unique API key provided to you by the Trustap team.

curl --location 'https://dev.stage.trustap.com/api/v1/guest_users' \
--header 'Content-Type: application/json' \
--user '<API_KEY>:' \
--data-raw '{"email":"sue.glass@mail.com","first_name":"Sue","last_name":"Glass","country_code":"ca","tos_acceptance":{"unix_timestamp":1736441841,"ip":"127.0.0.1"}}'

Note that API keys are provided as the "username" portion of a basic auth authentication; the password field is blank.

Webhook credentials

During your registration, the Trustap team will ask you for the following details.

  • URL of webhook endpoint <WEBHOOK_ENDPOINT>. This is the endpoint on which Trustap backend will send webhook events.
  • URL of login callback <REDIRECT_URI>. The callback URL you will use to retrieve user’s Trustap ID and email address as part of OAuth flow.
  • URL of payment callback <CALLBACK_PAYMENT>. The URL on which user will be redirected to from Trustap payment page.