logoUNLI
POST
/messages

Authorization

AuthorizationBearer <token>

Bearer token authentication using API keys

In: header

Header Parameters

anthropic-version?string

Anthropic API version header (e.g. 2023-06-01)

Default"2023-06-01"

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/messages" \  -H "Content-Type: application/json" \  -d '{    "model": "unli-auto",    "max_tokens": 1024,    "messages": [      {        "role": "user",        "content": "Hello, Claude!"      }    ]  }'
{  "id": "msg_01XFDUDYJgAACgrFtApKcNx3",  "type": "message",  "role": "assistant",  "content": [    {      "type": "text",      "text": "Hello! How can I assist you today?"    }  ],  "model": "unli-auto",  "stop_reason": "end_turn",  "stop_sequence": null,  "usage": {    "input_tokens": 10,    "output_tokens": 12  }}