POST
/
tongyi
/
gpts
/
chat
curl -X POST https://api.example.com/tongyi/gpts/chat \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "gpt_id": "gpt_123456",
    "messages": [
      {"role": "user", "content": "Hello"}
    ]
  }'
Chat with Tongyi Wanxiang GPTs.

Request Parameters

gpt_id
string
required
GPT ID.
messages
array
required
Array of messages.
curl -X POST https://api.example.com/tongyi/gpts/chat \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "gpt_id": "gpt_123456",
    "messages": [
      {"role": "user", "content": "Hello"}
    ]
  }'