Decisions
Run Jev decisions
Run decisions sent in the Jev request format, answered in the Jev response format.
POST
/
v1
/
systemone
Run Jev decisions
curl --request POST \
--url https://api.sqwish.ai/v1/systemone \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"questions": {},
"state": ""
}
'import requests
url = "https://api.sqwish.ai/v1/systemone"
payload = {
"model": "<string>",
"questions": {},
"state": ""
}
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({model: '<string>', questions: {}, state: ''})
};
fetch('https://api.sqwish.ai/v1/systemone', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"model": "<string>",
"answers": {},
"usage": {
"input_tokens": 123,
"output_tokens": 0,
"tokenizer": {
"name": "<string>",
"revision": "<string>"
},
"images": 123,
"image_tokens": 123
},
"timing_ms": {
"render": 123,
"score": 123,
"load": 123
},
"id": "<string>",
"version": "<string>",
"charge": {
"currency": "USD",
"amount_usd": "<string>",
"reserved_usd": "<string>",
"operation_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}Headers
Reuse the same key and body after a lost response. A successful replay does not execute or charge again. Changed request bodies conflict; expired replay bodies are not executed again under the old key. An organisation with zero data retention keeps no answer, so its key is not honoured: a retry runs again and is charged again.
Required string length:
1 - 255Pattern:
^[!-~]+$Body
application/json
Run Jev decisions
curl --request POST \
--url https://api.sqwish.ai/v1/systemone \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"questions": {},
"state": ""
}
'import requests
url = "https://api.sqwish.ai/v1/systemone"
payload = {
"model": "<string>",
"questions": {},
"state": ""
}
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({model: '<string>', questions: {}, state: ''})
};
fetch('https://api.sqwish.ai/v1/systemone', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"model": "<string>",
"answers": {},
"usage": {
"input_tokens": 123,
"output_tokens": 0,
"tokenizer": {
"name": "<string>",
"revision": "<string>"
},
"images": 123,
"image_tokens": 123
},
"timing_ms": {
"render": 123,
"score": 123,
"load": 123
},
"id": "<string>",
"version": "<string>",
"charge": {
"currency": "USD",
"amount_usd": "<string>",
"reserved_usd": "<string>",
"operation_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}