OpenAI
This is OpenAI Platform API federation. Codex’s own federation signs in a ChatGPT user and doesn’t authorize API calls. Read How provider setup works first.
You need an OpenAI role that can manage workload identity providers and service account mappings.
Values
Section titled “Values”| Field | Value |
|---|---|
| Issuer | https://identity.avant.codes |
| Audience | https://api.openai.com/v1 |
| Subject | The exact subject from the Avant form |
1. Start the workspace
Section titled “1. Start the workspace”In Avant, open New workspace and choose Direct → OpenAI. Copy the subject.
2. Create the identity provider
Section titled “2. Create the identity provider”In OpenAI, open Organization settings → Security → Workload identity provider and create an OIDC provider. An X.509 provider needs a client certificate, which Avant doesn’t use.
| Field | Value |
|---|---|
| OIDC issuer URL | https://identity.avant.codes |
| Custom OIDC discovery URL | Off |
| Uploaded JWKS | Off |
If the issuer is already registered, reuse that provider.
3. Map the subject to a service account
Section titled “3. Map the subject to a service account”On the provider, add one service account mapping:
| Field | Value |
|---|---|
| Key | sub |
| Value | The exact subject |
| Project | The OpenAI project that should own the usage |
| Service account | A new or existing service account in that project |
| Permissions | api.model.request, or leave blank |
- Leaving permissions blank means the token acts as the service account. A permissions list that doesn’t include
api.model.requestfails Verify. - OpenAI issues a token only when exactly one enabled mapping matches. A second matching mapping for the same subject breaks the exchange.
4. Copy the ids back
Section titled “4. Copy the ids back”| Avant field | Where |
|---|---|
| Identity provider ID | The provider list, looks like idp_… |
| Service account ID | The mapping details |
Create the workspace and run Verify.
avant workspace create --name gpt --provider openai \ --identity-provider-id idp_... --service-account-id <id>avant workspace verify gptModels
Section titled “Models”The workspace serves Chat Completions (/v1/chat/completions) and Responses (/v1/responses). OpenAI SDKs need https://proxy.avant.codes/v1 as the base URL.
| Model | API | Harnesses |
|---|---|---|
gpt-5.6-terra | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-5.6-luna | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6-astra | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6-sol | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6.1-sol (default) | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6.1-terra | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6.2-astra | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6.2-sol | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |
gpt-6-luna | Chat Completions, Responses | Codex, OpenCode, Pi, Oh My Pi |