Docs Guides
Guide

Python Basic Chat

You can call the API via HTTP in any language, the official Python bindings, the official Node.js library, or community-maintained libraries.

You can call the API via HTTP in any language, the official Python bindings, the official Node.js library, or community-maintained libraries.

To install the official Python bindings:

pip install openai
json
key='sk-xxxx' from openai import OpenAI client = OpenAI( base_url="https://api.digislash.com/v1", api_key=key ) response = client.chat.completions.create( model="gpt-4o", messages=[ {"role": "user", "content": "Hello?"}, ], timeout=100, ) print(response)
json