Skip to content

Function: createOpenAiAccountSeatBuilder() ​

ts
function createOpenAiAccountSeatBuilder(
   id, 
   configDir?, 
   apiKey?
): OpenAiAccountSeatBuilder;

Defined in: openai/src/builders/create-openai-account-seat-builder.ts:18

Creates an immutable OpenAiAccountSeatBuilder for an OpenAI API key seat or Codex CLI seat.

Performs zero filesystem reads or environment variable lookups at builder construction time, deferring credential resolution to OpenAiModelDriver.invokeTurn().

Parameters ​

ParameterTypeDescription
idstringNon-empty unique seat identifier.
configDir?stringOptional Codex CLI configuration directory path.
apiKey?string | EnvRefOptional literal API key or symbolic EnvRef.

Returns ​

OpenAiAccountSeatBuilder

Immutable builder compiling to OpenAiAccountSeatNode.

Throws ​

If id is an empty or whitespace-only string.

Released under the MIT License.