Anthropic Messages
FUNCD exposes the native Anthropic /v1/messages text API using the same platform key, model permissions, and balance.
bash
curl 'https://api.funcd.org/v1/messages' \
-H "x-api-key: $FUNCD_API_KEY" \
-H 'anthropic-version: 2023-06-01' \
-H 'Content-Type: application/json' \
-d '{
"model": "tokener-claude-opus-5",
"max_tokens": 128,
"messages": [{"role": "user", "content": "Hello"}]
}'Python SDK
python
import os
from anthropic import Anthropic
client = Anthropic(
api_key=os.environ["FUNCD_API_KEY"],
base_url="https://api.funcd.org",
)
message = client.messages.create(
model="tokener-claude-opus-5",
max_tokens=128,
messages=[{"role": "user", "content": "Hello"}],
)
print(message.content[0].text)Streaming
Add "stream": true to the JSON body. Streaming and non-streaming calls use the same model access, spending limit, and balance checks.
Model IDs
Use a model ID from the FUNCD catalog, such as tokener-claude-opus-5. Do not substitute an Anthropic account model ID.