Text chat¶
Send text chat with a model ID returned by GET /models.
curl -X POST "$GENESIS_BASE_URL/chat/completions" \
-H "Authorization: Bearer $GENESIS_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"model": "<CHAT_MODEL_ID>",
"messages": [{"role": "user", "content": "Summarize this document."}]
}'
Read generated text from choices[0].message.content. A successful HTTP response does not by itself confirm that the result meets your application requirements; validate the returned content before using it downstream.
Last updated on