Deploy a model
curl --request POST \
--url https://api.aireserve.com/v1/training/deployments \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"modelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"costAcknowledged": true
}
'import requests
url = "https://api.aireserve.com/v1/training/deployments"
payload = {
"modelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"costAcknowledged": True
}
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({
modelId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
name: '<string>',
costAcknowledged: true
})
};
fetch('https://api.aireserve.com/v1/training/deployments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"modelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"kind": "serverless",
"backend": "<string>",
"state": "pending",
"servingModel": "<string>",
"hourlyRateUsd": "<string>",
"error": "<string>",
"createdAt": "<string>"
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}Fine-tuning
Deploy a model
Serves a model serverless (adapters, per token) or dedicated (per hour, the first hour is checked against the wallet). Poll until ready, then send servingModel. Requires compute manage access.
POST
/
v1
/
training
/
deployments
Deploy a model
curl --request POST \
--url https://api.aireserve.com/v1/training/deployments \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"modelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"costAcknowledged": true
}
'import requests
url = "https://api.aireserve.com/v1/training/deployments"
payload = {
"modelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"costAcknowledged": True
}
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({
modelId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
name: '<string>',
costAcknowledged: true
})
};
fetch('https://api.aireserve.com/v1/training/deployments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"modelId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"kind": "serverless",
"backend": "<string>",
"state": "pending",
"servingModel": "<string>",
"hourlyRateUsd": "<string>",
"error": "<string>",
"createdAt": "<string>"
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": null,
"code": "<string>",
"details": {}
}
}Authorizations
bearerAuthapiKeyAuth
Your AI Reserve API key (aireserve_api_…) from the API Keys page in the portal (https://portal.aireserve.com/keys).
Body
application/json
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Required string length:
1 - 120Available options:
serverless, dedicated Available options:
true Response
Accepted.
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Available options:
serverless, dedicated Available options:
pending, provisioning, ready, failed, deleting, deleted The model id to send once ready.