Authorization: Bearer ********************{
"model": "glm-4.6",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": [
{
"type": "text",
"text": "你是谁"
}
]
}
]
}curl --location --request POST '/v1/messages' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "glm-4.6",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": [
{
"type": "text",
"text": "你是谁"
}
]
}
]
}'{
"id": "chatcmpl-c5afd89f",
"type": "message",
"role": "assistant",
"model": "glm-4.6",
"content": [
{
"type": "text",
"text": " 1"
}
],
"stop_reason": "end_turn",
"usage": {
"input_tokens": 1,
"cache_creation_input_tokens": 0,
"cache_read_input_tokens": 0,
"output_tokens": 0
}
}