OpenAI Compatibility

The Geppetto API provides compatibility for the OpenAI API standard, allowing easier integrations into existing applications.

The base URL for the OpenAI Compatible Endpoint is: https://api.geppetto.app/v1

Currently the API supports the following OpenAI API endpoints:

  • POST /chat/completions
  • POST /audio/speech

Python SDK

You can use the OpenAI Python SDK to interact with the Geppetto API. Load the OpenAI client like the following and you can use the endpoints as you would with the OpenAI API.

import os
import openai
 
client = openai.OpenAI(
    api_key=os.environ.get("GEPPETTO_API_KEY"),
    base_url="https://api.geppetto.app/v1",
)

Node.js SDK

You can use the OpenAI Node.js SDK to interact with the Geppetto API. Load the OpenAI client like the following and you can use the endpoints as you would with the OpenAI API.

const openai = require('openai');
 
const client = new openai.OpenAI({
    apiKey: process.env.GEPPETTO_API_KEY,
    base_url: "https://api.geppetto.app/v1",
});

Please report any incompatible behavior with the OpenAI API standard to [email protected]