API Keys
To make API requests to Vetrol, you need your Account SID and Auth Token. These credentials identify your account and authenticate your requests.
Find your credentials
- Log in to the Vetrol Console
- Navigate to Settings → API Keys
- Copy your Account SID and Auth Token
Protect your Auth Token
Your Auth Token is like a password. Never share it, commit it to version control, or expose it in client-side code.
Set up environment variables
Store your credentials as environment variables to keep them out of your code:
.env
VETROL_ACCOUNT_SID=ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
VETROL_AUTH_TOKEN=your_auth_token_here
Load them in your project:
- Node.js
- Python
- Ruby
require('dotenv').config();
const accountSid = process.env.VETROL_ACCOUNT_SID;
const authToken = process.env.VETROL_AUTH_TOKEN;
import os
from dotenv import load_dotenv
load_dotenv()
account_sid = os.environ['VETROL_ACCOUNT_SID']
auth_token = os.environ['VETROL_AUTH_TOKEN']
require 'dotenv/load'
account_sid = ENV['VETROL_ACCOUNT_SID']
auth_token = ENV['VETROL_AUTH_TOKEN']
Rotating your Auth Token
If your Auth Token is compromised, rotate it immediately from the Console under Settings → API Keys → Rotate Token. Your old token will be invalidated immediately.
Next steps
- Quickstart — Make your first API call
- Authentication — Learn about authentication methods