API Quickstart
Get your first API call running in 5 minutes.
Prerequisites
- Thox.ai device powered on and connected to your network
- Device showing green LED (ready state)
- Computer on the same network as the device
Verify Connection
First, verify that your device is accessible on the network:
# Check if device is reachable
curl http://thox.local:8080/health
# Expected response:
{"status": "healthy", "version": "1.2.0"}
If thox.local doesn't resolve, use your device's IP address instead (check your router's DHCP client list).
List Available Models
See what models are available on your device:
curl http://thox.local:8080/v1/models
# Response:
{
"data": [
{
"id": "thox-coder",
"object": "model",
"owned_by": "thoxai"
},
{
"id": "thox-chat",
"object": "model",
"owned_by": "thoxai"
}
]
}Make Your First Request
Using cURL
curl http://thox.local:8080/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "thox-coder",
"messages": [
{"role": "user", "content": "Write a hello world in Python"}
]
}'Using Python
import requests
response = requests.post(
"http://thox.local:8080/v1/chat/completions",
json={
"model": "thox-coder",
"messages": [
{"role": "user", "content": "Write a hello world in Python"}
]
}
)
print(response.json()["choices"][0]["message"]["content"])Using JavaScript/Node.js
const response = await fetch('http://thox.local:8080/v1/chat/completions', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
model: 'thox-coder',
messages: [
{ role: 'user', content: 'Write a hello world in Python' }
]
})
});
const data = await response.json();
console.log(data.choices[0].message.content);Enable Streaming
For real-time token-by-token output, enable streaming:
import requests
response = requests.post(
"http://thox.local:8080/v1/chat/completions",
json={
"model": "thox-coder",
"messages": [
{"role": "user", "content": "Explain async/await"}
],
"stream": True
},
stream=True
)
for line in response.iter_lines():
if line:
print(line.decode())Next Steps
CONFIDENTIAL AND PROPRIETARY INFORMATION
This documentation is provided for informational and operational purposes only. The specifications and technical details herein are subject to change without notice. Thox.ai LLC reserves all rights in the technologies, methods, and implementations described.
Nothing in this documentation shall be construed as granting any license or right to use any patent, trademark, trade secret, or other intellectual property right of Thox.ai LLC, except as expressly provided in a written agreement.
Patent Protection
The MagStack™ magnetic stacking interface technology, including the magnetic alignment system, automatic cluster formation, NFC-based device discovery, and distributed inference me...
Reverse Engineering Prohibited
You may not reverse engineer, disassemble, decompile, decode, or otherwise attempt to derive the source code, algorithms, data structures, or underlying ideas of any Thox.ai hardwa...
Thox.ai™, Thox OS™, MagStack™, and the Thox.ai logo are trademarks or registered trademarks of Thox.ai LLC in the United States and other countries.
NVIDIA, Jetson, TensorRT, and related marks are trademarks of NVIDIA Corporation. Ollama is a trademark of Ollama, Inc. All other trademarks are the property of their respective owners.
© 2026 Thox.ai LLC. All Rights Reserved.