For OpenAI, you need to set the following environment variables:

OPENAI_API_KEY=your_api_key
OPENAI_API_BASE=your_api_base

You can added your custom prompt_extension in the translator.php config files, for more accurate translations.

For more information, see OpenAI Setup