Skip to main content

Quickstart

Make your first API call in under a minute.

Prerequisites

  • An API key (sk_live_* or sk_test_*). See Auth Gateway to create one programmatically, or request one from your account admin.

Step 1: List Threads

curl -X POST https://api.yocaso.dev/llm.v1.services.gateway.v1.LLMGatewayService/ListThreads \
-H "X-API-Key: sk_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{}'

Response:

{
"threads": []
}

Step 2: Create a Thread

curl -X POST https://api.yocaso.dev/llm.v1.services.gateway.v1.LLMGatewayService/CreateThread \
-H "X-API-Key: sk_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"name": "My First Thread",
"conversation_key": "my-first-conversation"
}'

Step 3: Send a Message

curl -X POST https://api.yocaso.dev/llm.v1.services.gateway.v1.LLMGatewayService/SendMessage \
-H "X-API-Key: sk_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"conversation_key": "my-first-conversation",
"user_message": {
"role": "user",
"content": "What can you help me with?"
}
}'

Step 4: Check Conversation State

curl -X POST https://api.yocaso.dev/llm.v1.services.gateway.v1.LLMGatewayService/GetConversationState \
-H "X-API-Key: sk_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"conversation_key": "my-first-conversation"
}'

What's Next?