API reference

Messages

Send Anthropic-compatible Messages requests.

Create a message

Send a request to POST https://api.get-apikey.com/v1/messages using x-api-key or Bearer authentication:

curl "https://api.get-apikey.com/v1/messages" \
  -H "x-api-key: $GETRUN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"YOUR_MODEL","max_tokens":1024,"messages":[{"role":"user","content":"Hello"}]}'

Count tokens

Send the same request body to POST https://api.get-apikey.com/v1/messages/count_tokens.

On this page