curl --request POST \
--url https://api.dualmindlab.tech/api/arena/chat \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prompt": "Explain TCP vs UDP with a pizza analogy"
}
'import requests
url = "https://api.dualmindlab.tech/api/arena/chat"
payload = { "prompt": "Explain TCP vs UDP with a pizza analogy" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({prompt: 'Explain TCP vs UDP with a pizza analogy'})
};
fetch('https://api.dualmindlab.tech/api/arena/chat', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({prompt: 'Explain TCP vs UDP with a pizza analogy'})
};
fetch('https://api.dualmindlab.tech/api/arena/chat', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.dualmindlab.tech/api/arena/chat"
payload := strings.NewReader("{\n \"prompt\": \"Explain TCP vs UDP with a pizza analogy\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}using RestSharp;
var options = new RestClientOptions("https://api.dualmindlab.tech/api/arena/chat");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("{\n \"prompt\": \"Explain TCP vs UDP with a pizza analogy\"\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.post("https://api.dualmindlab.tech/api/arena/chat")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"prompt\": \"Explain TCP vs UDP with a pizza analogy\"\n}")
.asString();{
"object": "ai.response",
"output": {
"type": "message",
"content": [
{
"type": "output_text",
"text": "Packets are pizzas..."
}
]
},
"success": true,
"message": "Packets are pizzas...",
"model": {
"name": "llama-3.3-70b-versatile",
"displayName": "Llama 3.3 70B Versatile",
"provider": "groq"
},
"prompt": "Explain TCP vs UDP with a pizza analogy",
"selectionMode": "automatic",
"responseTimeMs": 2140,
"usage": {
"promptTokens": 18,
"completionTokens": 212,
"totalTokens": 230
},
"timestamp": "2026-10-17T12:00:00Z"
}{
"object": "ai.error",
"code": "INVALID_REQUEST",
"message": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}{
"object": "ai.error",
"code": "INVALID_REQUEST",
"message": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}Chat with one model
Direct Chat: send a prompt to one model (or auto for a random one) and get the full reply.
curl --request POST \
--url https://api.dualmindlab.tech/api/arena/chat \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prompt": "Explain TCP vs UDP with a pizza analogy"
}
'import requests
url = "https://api.dualmindlab.tech/api/arena/chat"
payload = { "prompt": "Explain TCP vs UDP with a pizza analogy" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({prompt: 'Explain TCP vs UDP with a pizza analogy'})
};
fetch('https://api.dualmindlab.tech/api/arena/chat', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({prompt: 'Explain TCP vs UDP with a pizza analogy'})
};
fetch('https://api.dualmindlab.tech/api/arena/chat', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.dualmindlab.tech/api/arena/chat"
payload := strings.NewReader("{\n \"prompt\": \"Explain TCP vs UDP with a pizza analogy\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}using RestSharp;
var options = new RestClientOptions("https://api.dualmindlab.tech/api/arena/chat");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("{\n \"prompt\": \"Explain TCP vs UDP with a pizza analogy\"\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.post("https://api.dualmindlab.tech/api/arena/chat")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"prompt\": \"Explain TCP vs UDP with a pizza analogy\"\n}")
.asString();{
"object": "ai.response",
"output": {
"type": "message",
"content": [
{
"type": "output_text",
"text": "Packets are pizzas..."
}
]
},
"success": true,
"message": "Packets are pizzas...",
"model": {
"name": "llama-3.3-70b-versatile",
"displayName": "Llama 3.3 70B Versatile",
"provider": "groq"
},
"prompt": "Explain TCP vs UDP with a pizza analogy",
"selectionMode": "automatic",
"responseTimeMs": 2140,
"usage": {
"promptTokens": 18,
"completionTokens": 212,
"totalTokens": 230
},
"timestamp": "2026-10-17T12:00:00Z"
}{
"object": "ai.error",
"code": "INVALID_REQUEST",
"message": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}{
"object": "ai.error",
"code": "INVALID_REQUEST",
"message": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}model to a modelName or modelId from List models, or auto to get a random Groq or Google AI Studio model. Want text as it’s generated? Use Stream a chat reply.Authorizations
The access token from your DualMind Arena session (a Supabase JWT). See Authentication.
Body
The user prompt. Must not be empty.
"Explain TCP vs UDP with a pizza analogy"
Model to use: a modelName (or modelId) from GET /api/models, or auto to let the Arena pick a random model.
"auto"
Optional system prompt.
Maximum tokens to generate.
x >= 1Sampling temperature.
0 <= x <= 2Save the prompt and reply to this thread. You must own the thread.
Response
The model's reply.
"ai.response"The model's reply as plain text (Markdown).
The same reply in a structured content envelope.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
automatic/manual for single chat; random/topper/manual for battles.
automatic, manual, random, topper Wall-clock time of the request in milliseconds. In a battle both models run in parallel, so this is the time until both finished.
Show child attributes
Show child attributes