π Supported AI Service Providers
β¨ The XAI platform is compatible with virtually all major AI providers and model ecosystems, supporting unified integration and flexible switching.
π§ How It Works
One entrypoint handles auth, routing, and normalization before reaching model providers.
Single entrypoint
Use one XAI API key and a unified base_url.
Smart routing
Policies, model mapping, rate limits, and observability live in the router.
Provider fan-out
Requests go to OpenAI, Claude, Gemini, and more, then normalize on the way back.
π» SDK Code Examples
OpenAI SDK Example
import os
from openai import OpenAI
XAI_API_KEY = os.getenv("XAI_API_KEY")
client = OpenAI(
api_key=XAI_API_KEY,
base_url="",
)
completion = client.chat.completions.create(
model="gpt-5",
messages=[
{"role": "system", "content": "You are AI"},
{"role": "user", "content": "What is the meaning of life, the universe, and everything?"},
],
)
print(completion.choices[0].message)
Anthropic SDK Example
import os
from anthropic import Anthropic
XAI_API_KEY = os.getenv("XAI_API_KEY")
client = Anthropic(
api_key=XAI_API_KEY,
base_url="",
)
message = client.messages.create(
model="claude-sonnet-4-6",
max_tokens=128,
system="You are AI.",
messages=[
{
"role": "user",
"content": "What is the meaning of life, the universe, and everything?",
},
],
)
print(message.content)
π§ͺ cURL Examples
OpenAI /responses
curl /responses \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $XAI_API_KEY" \
-d '{
"model": "gpt-5.4",
"input": "Explain what the Responses API does in one sentence."
}'
OpenAI /chat/completions
curl /chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $XAI_API_KEY" \
-d '{
"model": "gpt-5.2",
"messages": [
{
"role": "developer",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "Hello!"
}
]
}'
Anthropic /messages
curl /v1/messages \
-H 'Content-Type: application/json' \
-H 'anthropic-version: 2023-06-01' \
-H "X-Api-Key: $XAI_API_KEY" \
-d '{
"max_tokens": 1024,
"messages": [
{
"content": "Hello, world",
"role": "user"
}
],
"model": "claude-sonnet-4-6"
}'
Total Levels
-
Total Keys
-
Active Keys
-
Sleeping Keys
-
Add New Provider
Provider List
Loading...
System Configuration Management
Model Pricing (Owner Overrides)
Provide only the deltas from system defaults. Applied immediately; requests prefer Owner overrides and fall back to defaults.
Override examples:
β’ Override an existing model: {"ChatPricing":{"gpt-5":{"InputText":4.5,"OutputText":12.5,"Rates":1}}}
β’ Add a custom model: {"ChatPricing":{"my-model":{"InputText":1,"OutputText":2,"Rates":1}}}
β’ Free model (Rates=0): {"ChatPricing":{"free-model":{"InputText":0,"OutputText":0,"Rates":0}}}
Product Catalog Scope
Multi-tenant payment gateways can use the shared catalog or a tenant-dedicated catalog. Choose Shared Catalog to edit global products, or choose a dedicated tenant to edit its cloned product definitions.
Subscription Plans
Push sellable subscription plans to the frontend. `active: false` means the plan is hidden from the storefront and no longer purchasable.
PAYG Card Products
Standalone PAYG products for all users. Each SKU can set a fixed sale price, granted credits, and an optional validity window without changing subscription policy.
Extra Usage Products
Subscriber-only extra usage products. Each purchase adds credits to the pay-as-you-go balance without changing the subscription, and extra usage should usually expire after 31 days.
Service Products
Use this for manually delivered service products such as OpenClaw remote installation. Paid orders become service orders instead of account credits.
Service Orders
Group Buy Launch
After the group is formed, confirm resources are configured, then launch the group.
Refund Operations
Root admins can look up an order and trigger an original WeChat refund. This panel does not enforce the local refund-window rule, but the final result still depends on WeChat Pay gateway rules. The preview assumes a 5% fee by default; unlaunched group buys refund in full with no fee. Leaving the amount blank lets the backend calculate the refundable maximum; a manual amount means actual WeChat refund, and the backend remains the source of truth.
Revenue Analytics
Range Revenue Summary
Range: This month
Today's Net Revenue
Β₯0.00
Gross Payments
Β₯0.00
Refunds
Β₯0.00
Net Revenue
Β₯0.00
Paid Orders
0
Average Order Value
Β₯0.00
Revenue Trend
Product Type Distribution
Payment Method Distribution
Today's Orders
| Paid At | User | Tenant | Order No. | Product | Amount | Method | Status |
|---|
Payment Ranking
| Rank | User | Tenant | Gross Paid | Refund | Net Paid | Orders | AOV |
|---|
Daily Revenue Detail
| Date | Gross | Refunds | Net | Paid Orders | Refunded Orders |
|---|
Product Revenue Distribution
| Type | Product | Gross | Refunds | Net | Paid Orders | Refunded Orders |
|---|
Create New Broadcast
Recent Broadcasts
Operation Logs
| Time | Action | Target | Details | IP |
|---|
Loading logs...
No operation logs found