Skip to main content
The Archetype AI Python client uses environment variables for authentication and API configuration.

Required Variables

ATAI_API_KEY

Your unique API key for authenticating with the Archetype platform.
To obtain an API key, contact [email protected].

ATAI_API_ENDPOINT

The API endpoint URL for the Archetype platform, including the API version path.
The version path is required — an endpoint without it (e.g. https://api.u1.archetypeai.app) fails with 404 errors, which the Python client surfaces as an empty ApiError: {}. The version depends on the service: most APIs (query, files, batch) use /v0.5, while the Fine-Tuning Service uses /v0.6.

Setting Environment Variables

Add the following to your shell configuration file (~/.bashrc, ~/.zshrc, or similar):
Then reload your shell:

Verifying Configuration

To verify your environment variables are set correctly:
Both should display the values you configured.