API

Getting Started

5min

This guide will provide you with the basic steps to start using the ThroughLine API and incorporating helpline data into your website or application.

Register your account

To use the API you first need to sign up for a ThroughLine Developer Account. This account is used to manage your applications and retrieve the API keys needed to access the API.

Don't have an Account? Sign up here.

Once you have registered and your account has been enabled by one of our team, you'll have access to the ThroughLine developer dashboard.

Please make sure you have read and understood the Sandbox Terms & Conditions (Terms) and our usage policies before you start using the API.

Create an Application

The Developer Dashboard is your management portal for your developer account. To make authorized requests to the API you will need to create an application to manage your application secrets.

The steps to create an application are as follows:

  1. Log in to the Developer Dashboard.
  2. Navigate to Applications.
  3. Click Create Application.
  4. Provide a name and select either Sandbox or Production as the tier of application. See the Sandbox vs Production article for more details on the differences.
  5. Save the changes.

Once you have an application you will be able to view your application credentials which are used to authenticate with the API.

Keep your secrets safe! Please safeguard your application secret. Do not share your Client Secret value with anyone, and do not pass it in the URL when making API calls, include it in URL query-string parameters, or post it in support forums, chat, etc. The secret is required to authenticate to the API and generate the tokens required to make valid calls to the API. See our API Security article for best practices in keeping your calls to the API secure.

ThroughLine reserves the right to revoke any application credentials at any time and issue a new one if they have been leaked or misused.

Call the API

The ThroughLine API is secured using OAuth 2.0. Making calls to the API requires a preliminary authorization step to obtain a valid access token. Access tokens are required for all requests, and can be included by adding Authorization: Bearer #{access_token} as a header. Once you have an access token, try it out using our API Reference documentation.

To make a call to the /helplines endpoint with a bearer token using a third-party tool like Postman, follow these steps:

  1. Create a new GET request in Postman.
  2. Set the Authorization to Bearer Token and enter the access token you've obtained.
  3. Add a parameter for the country_code. This should be the ISO 3166 Alpha-2 code for the country e.g. US.
  4. Run the request to see the response.
Postman Authentication Example
Figure 1: Postman Bearer Token Authorization


See the Authorization article for more on how to obtain an access token for your application and securely access the API.

Getting Help

If you need integration or technical support, please reach out to our Engineering team at [email protected].