PromptAvenue supports OpenAI-compatible Chat Completions. Use https://api.promptavenue.com/v1 as base_url in Python or baseURL in Node.js. Set PROMPTAVENUE_API_KEY in your terminal before running an example. See the Quickstart for SDK installation and API key setup.
curl
curl --silent --show-error --fail-with-body \
'https://api.promptavenue.com/v1/chat/completions' \
-H "Authorization: Bearer ${PROMPTAVENUE_API_KEY:?Set your PromptAvenue API key first}" \
-H 'Content-Type: application/json' \
--data-raw '{
"model": "deepseek-v4.1-flash-uncensored",
"messages": [
{"role": "user", "content": "What does HTTP 429 mean? Answer in one sentence."}
]
}'
Python (OpenAI SDK)
import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.promptavenue.com/v1",
api_key=os.environ["PROMPTAVENUE_API_KEY"],
)
completion = client.chat.completions.create(
model="deepseek-v4.1-flash-uncensored",
messages=[
{"role": "user", "content": "What does HTTP 429 mean? Answer in one sentence."}
],
)
print(completion.choices[0].message.content)
JavaScript (OpenAI SDK for Node.js)
import OpenAI from "openai";
const apiKey = process.env.PROMPTAVENUE_API_KEY;
if (!apiKey) throw new Error("Set PROMPTAVENUE_API_KEY first.");
const client = new OpenAI({
baseURL: "https://api.promptavenue.com/v1",
apiKey,
});
const completion = await client.chat.completions.create({
model: "deepseek-v4.1-flash-uncensored",
messages: [{ role: "user", content: "What does HTTP 429 mean? Answer in one sentence." }],
});
console.log(completion.choices[0].message.content);