Skip to main content

Prerequisites

1. Set your API key

Store your API key as an environment variable. Never hardcode it in source code.

2. Make your first request

3. Read the response

A successful response includes:
  • output_text — The model’s text response
  • usage — Token counts and cost
  • routing — Which routing category was used

4. Check your usage

View your usage and balance in the Developer Dashboard.

Next Steps