Programmatic access to AI model evaluation services
Generate an API key from your TrustModel dashboard under Settings > API Keys.
Include your API key in the X-API-Key header:
X-API-Key: tm-{env}-{key_id}_{secret}
Run an evaluation on a model:
curl -X POST /sdk/v1/evaluate/ \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model_identifier": "gpt-4o",
"vendor_identifier": "openai"
}'
Get available model_identifier and vendor_identifier values from /sdk/v1/models/. Get configuration options (application types, categories, vendors) from /sdk/v1/config/.
Health check - validate your API key
Get configuration options (application types, categories, vendors, defaults)
List available AI models for evaluation
Check your credit balance
List your saved evaluation templates
Create a new model evaluation
List your evaluations
Get evaluation details and scores
Check evaluation status
Get evaluation scores and HTML report
Test connection to a custom API endpoint
Create a batch evaluation job
List your batch jobs
Get batch job details
api_key_inactive - API key is disabled or expiredapi_key_credits_exhausted - API key credit limit reachedsubscription_credits_exhausted - Subscription quota exceededinsufficient_credits - Not enough credits for this operation