openai

package
v0.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 14, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package openai provides a provider implementation for OpenAI's API.

This is a convenience wrapper around openai_compatible that configures the correct base URL for OpenAI.

Basic usage:

provider, _ := openai.New("sk-your-key")
proxy := llmproxy.NewProxy(provider)

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(apiKey string) (*openai_compatible.Provider, error)

New creates a new OpenAI provider with the given API key. The provider is configured to use OpenAI's API endpoint (https://api.openai.com).

Example:

provider, _ := openai.New("sk-your-openai-api-key")

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL