Przejdź do głównej zawartości

Class: AzureOpenAI

Extends

  • OpenAI

Constructors

new AzureOpenAI()

new AzureOpenAI(__namedParameters?): AzureOpenAI

API Client for interfacing with the OpenAI API.

Parameters

__namedParameters?: ClientOptions

Returns

AzureOpenAI

Inherited from

OrigOpenAI.constructor

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:96

Properties

apiKey

apiKey: string

Inherited from

OrigOpenAI.apiKey

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:77


audio

audio: Audio

Inherited from

OrigOpenAI.audio

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:102


baseURL

baseURL: string

Inherited from

OrigOpenAI.baseURL

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:62


batches

batches: Batches

Inherited from

OrigOpenAI.batches

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:107


beta

beta: Beta

Inherited from

OrigOpenAI.beta

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:106


chat

chat: Chat

Inherited from

OrigOpenAI.chat

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:98


completions

completions: Completions

Inherited from

OrigOpenAI.completions

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:97


embeddings

embeddings: Embeddings

Inherited from

OrigOpenAI.embeddings

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:99


files

files: Files

Inherited from

OrigOpenAI.files

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:100


fineTuning

fineTuning: FineTuning

Inherited from

OrigOpenAI.fineTuning

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:105


httpAgent

httpAgent: undefined | Agent

Inherited from

OrigOpenAI.httpAgent

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:65


idempotencyHeader?

protected optional idempotencyHeader: string

Inherited from

OrigOpenAI.idempotencyHeader

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:67


images

images: Images

Inherited from

OrigOpenAI.images

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:101


maxRetries

maxRetries: number

Inherited from

OrigOpenAI.maxRetries

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:63


models

models: Models

Inherited from

OrigOpenAI.models

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:104


moderations

moderations: Moderations

Inherited from

OrigOpenAI.moderations

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:103


organization

organization: null | string

Inherited from

OrigOpenAI.organization

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:78


project

project: null | string

Inherited from

OrigOpenAI.project

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:79


timeout

timeout: number

Inherited from

OrigOpenAI.timeout

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:64


APIConnectionError

static APIConnectionError: typeof APIConnectionError

Inherited from

OrigOpenAI.APIConnectionError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:114


APIConnectionTimeoutError

static APIConnectionTimeoutError: typeof APIConnectionTimeoutError

Inherited from

OrigOpenAI.APIConnectionTimeoutError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:115


APIError

static APIError: typeof APIError

Inherited from

OrigOpenAI.APIError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:113


APIUserAbortError

static APIUserAbortError: typeof APIUserAbortError

Inherited from

OrigOpenAI.APIUserAbortError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:116


AuthenticationError

static AuthenticationError: typeof AuthenticationError

Inherited from

OrigOpenAI.AuthenticationError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:121


BadRequestError

static BadRequestError: typeof BadRequestError

Inherited from

OrigOpenAI.BadRequestError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:120


ConflictError

static ConflictError: typeof ConflictError

Inherited from

OrigOpenAI.ConflictError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:118


InternalServerError

static InternalServerError: typeof InternalServerError

Inherited from

OrigOpenAI.InternalServerError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:122


NotFoundError

static NotFoundError: typeof NotFoundError

Inherited from

OrigOpenAI.NotFoundError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:117


OpenAI

static OpenAI: typeof OpenAI

Inherited from

OrigOpenAI.OpenAI

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:111


OpenAIError

static OpenAIError: typeof OpenAIError

Inherited from

OrigOpenAI.OpenAIError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:112


PermissionDeniedError

static PermissionDeniedError: typeof PermissionDeniedError

Inherited from

OrigOpenAI.PermissionDeniedError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:123


RateLimitError

static RateLimitError: typeof RateLimitError

Inherited from

OrigOpenAI.RateLimitError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:119


UnprocessableEntityError

static UnprocessableEntityError: typeof UnprocessableEntityError

Inherited from

OrigOpenAI.UnprocessableEntityError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:124


fileFromPath()

static fileFromPath: (path, options?) => Promise<File>(path, filename?, options?) => Promise<File>

Parameters

path: string

options?: FileFromPathOptions

Returns

Promise<File>

Parameters

path: string

filename?: string

options?: FileFromPathOptions

Returns

Promise<File>

Inherited from

OrigOpenAI.fileFromPath

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:126


toFile()

static toFile: (value, name?, options?) => Promise<FileLike>

Helper for creating a File to pass to an SDK upload method from a variety of different data formats

Parameters

value: ToFileInput | PromiseLike<ToFileInput>

the raw content of the file. Can be an Uploadable, BlobLikePart, or AsyncIterable of BlobLikeParts

name?: null | string

the name of the file. If omitted, toFile will try to determine a file name from bits if possible

options?: FilePropertyBag

additional properties

Returns

Promise<FileLike>

a File with the given properties

Inherited from

OrigOpenAI.toFile

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:125

Methods

authHeaders()

protected authHeaders(): object

Returns

object

api-key

api-key: string

Overrides

OrigOpenAI.authHeaders

Source

packages/core/src/llm/openai.ts:47


buildRequest()

buildRequest<Req>(options): object

Type parameters

Req

Parameters

options: FinalRequestOptions<Req>

Returns

object

req

req: RequestInit

timeout

timeout: number

url

url: string

Inherited from

OrigOpenAI.buildRequest

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:100


buildURL()

buildURL<Req>(path, query): string

Type parameters

Req

Parameters

path: string

query: undefined | null | Req

Returns

string

Inherited from

OrigOpenAI.buildURL

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:125


defaultHeaders()

protected defaultHeaders(opts): Headers

Parameters

opts: FinalRequestOptions<unknown>

Returns

Headers

Inherited from

OrigOpenAI.defaultHeaders

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:109


defaultIdempotencyKey()

protected defaultIdempotencyKey(): string

Returns

string

Inherited from

OrigOpenAI.defaultIdempotencyKey

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:91


defaultQuery()

protected defaultQuery(): undefined | DefaultQuery

Returns

undefined | DefaultQuery

Inherited from

OrigOpenAI.defaultQuery

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/index.d.mts:108


delete()

delete<Req, Rsp>(path, opts?): APIPromise<Rsp>

Type parameters

Req

Rsp

Parameters

path: string

opts?: PromiseOrValue<RequestOptions<Req>>

Returns

APIPromise<Rsp>

Inherited from

OrigOpenAI.delete

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:96


fetchWithTimeout()

fetchWithTimeout(url, init, ms, controller): Promise<Response>

Parameters

url: RequestInfo

init: undefined | RequestInit

ms: number

controller: AbortController

Returns

Promise<Response>

Inherited from

OrigOpenAI.fetchWithTimeout

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:127


get()

get<Req, Rsp>(path, opts?): APIPromise<Rsp>

Type parameters

Req

Rsp

Parameters

path: string

opts?: PromiseOrValue<RequestOptions<Req>>

Returns

APIPromise<Rsp>

Inherited from

OrigOpenAI.get

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:92


getAPIList()

getAPIList<Item, PageClass>(path, Page, opts?): PagePromise<PageClass, Item>

Type parameters

Item

PageClass extends AbstractPage<Item> = AbstractPage<Item>

Parameters

path: string

Page

opts?: RequestOptions<any>

Returns

PagePromise<PageClass, Item>

Inherited from

OrigOpenAI.getAPIList

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:98


getRequestClient()

protected getRequestClient(): RequestClient

Returns

RequestClient

Inherited from

OrigOpenAI.getRequestClient

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:128


makeStatusError()

protected makeStatusError(status, error, message, headers): APIError

Parameters

status: undefined | number

error: undefined | Object

message: undefined | string

headers: undefined | Headers

Returns

APIError

Inherited from

OrigOpenAI.makeStatusError

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:121


parseHeaders()

protected parseHeaders(headers): Record<string, string>

Parameters

headers: undefined | null | HeadersInit

Returns

Record<string, string>

Inherited from

OrigOpenAI.parseHeaders

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:120


patch()

patch<Req, Rsp>(path, opts?): APIPromise<Rsp>

Type parameters

Req

Rsp

Parameters

path: string

opts?: PromiseOrValue<RequestOptions<Req>>

Returns

APIPromise<Rsp>

Inherited from

OrigOpenAI.patch

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:94


post()

post<Req, Rsp>(path, opts?): APIPromise<Rsp>

Type parameters

Req

Rsp

Parameters

path: string

opts?: PromiseOrValue<RequestOptions<Req>>

Returns

APIPromise<Rsp>

Inherited from

OrigOpenAI.post

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:93


prepareOptions()

protected prepareOptions(options): Promise<void>

Used as a callback for mutating the given FinalRequestOptions object.

Parameters

options: FinalRequestOptions<unknown>

Returns

Promise<void>

Inherited from

OrigOpenAI.prepareOptions

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:109


prepareRequest()

protected prepareRequest(request, __namedParameters): Promise<void>

Used as a callback for mutating the given RequestInit object.

This is useful for cases where you want to add certain headers based off of the request properties, e.g. method or url.

Parameters

request: RequestInit

__namedParameters

__namedParameters.options: FinalRequestOptions<unknown>

__namedParameters.url: string

Returns

Promise<void>

Inherited from

OrigOpenAI.prepareRequest

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:116


put()

put<Req, Rsp>(path, opts?): APIPromise<Rsp>

Type parameters

Req

Rsp

Parameters

path: string

opts?: PromiseOrValue<RequestOptions<Req>>

Returns

APIPromise<Rsp>

Inherited from

OrigOpenAI.put

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:95


request()

request<Req, Rsp>(options, remainingRetries?): APIPromise<Rsp>

Type parameters

Req

Rsp

Parameters

options: PromiseOrValue<FinalRequestOptions<Req>>

remainingRetries?: null | number

Returns

APIPromise<Rsp>

Inherited from

OrigOpenAI.request

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:122


requestAPIList()

requestAPIList<Item, PageClass>(Page, options): PagePromise<PageClass, Item>

Type parameters

Item = unknown

PageClass extends AbstractPage<Item> = AbstractPage<Item>

Parameters

Page

options: FinalRequestOptions<unknown>

Returns

PagePromise<PageClass, Item>

Inherited from

OrigOpenAI.requestAPIList

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:124


stringifyQuery()

protected stringifyQuery(query): string

Parameters

query: Record<string, unknown>

Returns

string

Inherited from

OrigOpenAI.stringifyQuery

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:126


validateHeaders()

protected validateHeaders(headers, customHeaders): void

Override this to add your own headers validation:

Parameters

headers: Headers

customHeaders: Headers

Returns

void

Inherited from

OrigOpenAI.validateHeaders

Source

node_modules/.pnpm/openai@4.43.0/node_modules/openai/core.d.ts:90