Provision a sandbox runtime
curl --request POST \
--url https://api.akhara.dev/api/agents/{id}/provision \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.akhara.dev/api/agents/{id}/provision"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.akhara.dev/api/agents/{id}/provision', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.akhara.dev/api/agents/{id}/provision",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.akhara.dev/api/agents/{id}/provision"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.akhara.dev/api/agents/{id}/provision")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.akhara.dev/api/agents/{id}/provision")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"source": "builtin",
"status": "<string>",
"baseUrl": "<string>",
"apiKeyMasked": "ak_live_••••4f2a",
"categories": [
"<string>"
],
"tools": [
"<string>"
],
"policyIds": [
"<string>"
],
"runtime": {
"status": "<string>",
"boundary": "android-emulator",
"env": {
"GATEWAY": "https://api.akhara.dev"
},
"provisionedAt": 123
},
"createdAt": 123,
"updatedAt": 123
}Agents
Provision a runtime
Runs the five-step boundary setup (image → sandbox → seed → agent → ready) and injects a GATEWAY env var pointing back at the PDP.
POST
/
api
/
agents
/
{id}
/
provision
Provision a sandbox runtime
curl --request POST \
--url https://api.akhara.dev/api/agents/{id}/provision \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.akhara.dev/api/agents/{id}/provision"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.akhara.dev/api/agents/{id}/provision', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.akhara.dev/api/agents/{id}/provision",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.akhara.dev/api/agents/{id}/provision"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.akhara.dev/api/agents/{id}/provision")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.akhara.dev/api/agents/{id}/provision")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"source": "builtin",
"status": "<string>",
"baseUrl": "<string>",
"apiKeyMasked": "ak_live_••••4f2a",
"categories": [
"<string>"
],
"tools": [
"<string>"
],
"policyIds": [
"<string>"
],
"runtime": {
"status": "<string>",
"boundary": "android-emulator",
"env": {
"GATEWAY": "https://api.akhara.dev"
},
"provisionedAt": 123
},
"createdAt": 123,
"updatedAt": 123
}Runs the five-step boundary setup (
image → sandbox → seed → agent → ready) and
injects a GATEWAY env var pointing back at the PDP so enforcement stays in-path
inside the sandbox. See Environments.Authorizations
Workspace API key (ak_live_…).
Path Parameters
Response
200 - application/json
The agent with a populated runtime block.

