Skip to main content

openai.openai._constructor_

Home > @runlightyear/openai > OpenAI > (constructor)

OpenAI.(constructor)

Constructs a new instance of the OpenAI class

Signature:
constructor(props: OpenAIProps);

Parameters

ParameterTypeDescription
propsOpenAIProps

Example

defineAction({
name: "openAIExample",
title: "OpenAI Example"
apps: ["openai"],
run: async ({ auths }) => {
const openai = new OpenAI({ auth: auths.openai });
}
}