Skip to main content

Authentication

The Terros API uses API keys for authentication. This guide will walk you through the process of obtaining your API credentials and making your first request to the Terros API.

Obtaining Credentials

To obtain your API key, navigate to the API Keys page in your company settings. You must have permission to create API keys or be a compnay admin. Our support team will guide you through the process and address any specific requirements you may have.

Authenticating Requests

You must include your API key in the header of every request to authenticate.

Authorization: ApiKey <YOUR_API_KEY>

All API requests should be made to the base URL:

https://api.terros.com

Authorization Errors

If you receive a 403 Forbidden response, it means that your API key is invalid or has been revoked. Please contact our support team for assistance. For example:

{
"message": "Forbidden"
}

Making your first API request

Let's make a simple request to the Terros API to retrieve your user profile information. You can use the following cURL command to make the request:

export TERROS_API_KEY="<YOUR_API_KEY>"
curl -X POST "https://api.terros.com/user/get" -H "Content-Type: application/json" -H "Authorization: ApiKey $TERROS_API_KEY" -d '{}'

Security Considerations

  • Always use HTTPS for API requests to ensure your credentials are encrypted. The Terros API does not accept connections over HTTP.
  • Do not share your API key with anyone. Keep it secure and do not expose it in public repositories or client-side code.
  • If you suspect that your API key has been compromised, revoke the key on the API Keys page or contact our support team immediately.