OpenAI

API configuration: openaiarrow-up-right

Features

We can implement missing features in <48h, just ask for it in the communityarrow-up-right.

Getting started

Need help getting started? Get help in the communityarrow-up-right.

API gotchas

  • OpenAI uses API_KEY auth mode with Authorization: Bearer API_KEY in the request header to access different endpoints.

  • terapi supports automatic retries based on the x-ratelimit-reset-requests header from OpenAI's API. This header indicates when the request limit will reset, allowing terapi to efficiently manage API calls. Unlike x-ratelimit-reset-tokens, which pertains to the total token usage,x-ratelimit-reset-requests specifically addresses the number of API requests.

  • For users associated with multiple organizations or accessing their projects via a legacy user API key, optional headers can be included to specify the organization and project for the API request. Organization IDs can be found on your Organization settingsarrow-up-right page, while project IDs can be found on your General settingsarrow-up-right page.

  • This can be done at the script level:

Add Getting Started links and Gotchas by editing this pagearrow-up-right

Last updated