Skip to main content

POST /v1/chat/completions

Create a chat completion with an ARKOS agent using the OpenAI-compatible API format.

Request Body

{
  "model": "arkos-default",
  "messages": [
    {
      "role": "system",
      "content": "You are a helpful assistant with persistent memory."
    },
    {
      "role": "user",
      "content": "Hello! Can you help me understand ARKOS?"
    }
  ],
  "temperature": 0.7,
  "max_tokens": 1000
}

Response

{
  "id": "chatcmpl-123",
  "object": "chat.completion",
  "created": 1677652288,
  "model": "arkos-default",
  "choices": [{
    "index": 0,
    "message": {
      "role": "assistant",
      "content": "Hello! I'd be happy to help you understand ARKOS..."
    },
    "finish_reason": "stop"
  }],
  "usage": {
    "prompt_tokens": 42,
    "completion_tokens": 128,
    "total_tokens": 170
  }
}

Parameters

ParameterTypeRequiredDescription
modelstringYesModel identifier (currently supports “arkos-default”)
messagesarrayYesArray of message objects with role and content
temperaturefloatNoSampling temperature (0.0 to 2.0)
max_tokensintegerNoMaximum tokens to generate

Features In Development

  • Coming soon! Streaming responses
  • Coming soon! Tool/function calling
  • Coming soon! Memory context injection
  • Coming soon! Multi-agent conversations