Register a runner
curl --request POST \
--url https://api.agentsfleet.net/v1/admin/runners \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"assigned_policy": {
"durable_tasks_enabled": true,
"extra_binds": [
{
"note": "<string>",
"path": "<string>"
}
],
"registry_allowlist": [
"<string>"
],
"worker_count": 1,
"decision_model_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"host_id": "<string>",
"labels": [
"<string>"
]
}
'import requests
url = "https://api.agentsfleet.net/v1/admin/runners"
payload = {
"assigned_policy": {
"durable_tasks_enabled": True,
"extra_binds": [
{
"note": "<string>",
"path": "<string>"
}
],
"registry_allowlist": ["<string>"],
"worker_count": 1,
"decision_model_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"host_id": "<string>",
"labels": ["<string>"]
}
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({
assigned_policy: {
durable_tasks_enabled: true,
extra_binds: [{note: '<string>', path: '<string>'}],
registry_allowlist: ['<string>'],
worker_count: 1,
decision_model_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'
},
host_id: '<string>',
labels: ['<string>']
})
};
fetch('https://api.agentsfleet.net/v1/admin/runners', 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.agentsfleet.net/v1/admin/runners",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'assigned_policy' => [
'durable_tasks_enabled' => true,
'extra_binds' => [
[
'note' => '<string>',
'path' => '<string>'
]
],
'registry_allowlist' => [
'<string>'
],
'worker_count' => 1,
'decision_model_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'host_id' => '<string>',
'labels' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.agentsfleet.net/v1/admin/runners"
payload := strings.NewReader("{\n \"assigned_policy\": {\n \"durable_tasks_enabled\": true,\n \"extra_binds\": [\n {\n \"note\": \"<string>\",\n \"path\": \"<string>\"\n }\n ],\n \"registry_allowlist\": [\n \"<string>\"\n ],\n \"worker_count\": 1,\n \"decision_model_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"host_id\": \"<string>\",\n \"labels\": [\n \"<string>\"\n ]\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))
}HttpResponse<String> response = Unirest.post("https://api.agentsfleet.net/v1/admin/runners")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"assigned_policy\": {\n \"durable_tasks_enabled\": true,\n \"extra_binds\": [\n {\n \"note\": \"<string>\",\n \"path\": \"<string>\"\n }\n ],\n \"registry_allowlist\": [\n \"<string>\"\n ],\n \"worker_count\": 1,\n \"decision_model_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"host_id\": \"<string>\",\n \"labels\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.agentsfleet.net/v1/admin/runners")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"assigned_policy\": {\n \"durable_tasks_enabled\": true,\n \"extra_binds\": [\n {\n \"note\": \"<string>\",\n \"path\": \"<string>\"\n }\n ],\n \"registry_allowlist\": [\n \"<string>\"\n ],\n \"worker_count\": 1,\n \"decision_model_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"host_id\": \"<string>\",\n \"labels\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"assigned_policy": {
"durable_tasks_enabled": true,
"extra_binds": [
{
"mode": "read_only",
"note": "<string>",
"path": "<string>"
}
],
"network_policy": "allow_all",
"registry_allowlist": [
"<string>"
],
"sandbox_tier": "landlock_full",
"worker_count": 1,
"decision_model_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"runner_id": "<string>",
"runner_token": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}Runner administration
Register a runner
Registers a runner and assigns its policy. Requires runner:enroll on a bearer credential. Save the returned agt_r token securely; it appears once. The runner must apply the assigned policy.
POST
/
v1
/
admin
/
runners
Register a runner
curl --request POST \
--url https://api.agentsfleet.net/v1/admin/runners \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"assigned_policy": {
"durable_tasks_enabled": true,
"extra_binds": [
{
"note": "<string>",
"path": "<string>"
}
],
"registry_allowlist": [
"<string>"
],
"worker_count": 1,
"decision_model_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"host_id": "<string>",
"labels": [
"<string>"
]
}
'import requests
url = "https://api.agentsfleet.net/v1/admin/runners"
payload = {
"assigned_policy": {
"durable_tasks_enabled": True,
"extra_binds": [
{
"note": "<string>",
"path": "<string>"
}
],
"registry_allowlist": ["<string>"],
"worker_count": 1,
"decision_model_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"host_id": "<string>",
"labels": ["<string>"]
}
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({
assigned_policy: {
durable_tasks_enabled: true,
extra_binds: [{note: '<string>', path: '<string>'}],
registry_allowlist: ['<string>'],
worker_count: 1,
decision_model_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'
},
host_id: '<string>',
labels: ['<string>']
})
};
fetch('https://api.agentsfleet.net/v1/admin/runners', 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.agentsfleet.net/v1/admin/runners",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'assigned_policy' => [
'durable_tasks_enabled' => true,
'extra_binds' => [
[
'note' => '<string>',
'path' => '<string>'
]
],
'registry_allowlist' => [
'<string>'
],
'worker_count' => 1,
'decision_model_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'host_id' => '<string>',
'labels' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.agentsfleet.net/v1/admin/runners"
payload := strings.NewReader("{\n \"assigned_policy\": {\n \"durable_tasks_enabled\": true,\n \"extra_binds\": [\n {\n \"note\": \"<string>\",\n \"path\": \"<string>\"\n }\n ],\n \"registry_allowlist\": [\n \"<string>\"\n ],\n \"worker_count\": 1,\n \"decision_model_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"host_id\": \"<string>\",\n \"labels\": [\n \"<string>\"\n ]\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))
}HttpResponse<String> response = Unirest.post("https://api.agentsfleet.net/v1/admin/runners")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"assigned_policy\": {\n \"durable_tasks_enabled\": true,\n \"extra_binds\": [\n {\n \"note\": \"<string>\",\n \"path\": \"<string>\"\n }\n ],\n \"registry_allowlist\": [\n \"<string>\"\n ],\n \"worker_count\": 1,\n \"decision_model_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"host_id\": \"<string>\",\n \"labels\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.agentsfleet.net/v1/admin/runners")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"assigned_policy\": {\n \"durable_tasks_enabled\": true,\n \"extra_binds\": [\n {\n \"note\": \"<string>\",\n \"path\": \"<string>\"\n }\n ],\n \"registry_allowlist\": [\n \"<string>\"\n ],\n \"worker_count\": 1,\n \"decision_model_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"host_id\": \"<string>\",\n \"labels\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"assigned_policy": {
"durable_tasks_enabled": true,
"extra_binds": [
{
"mode": "read_only",
"note": "<string>",
"path": "<string>"
}
],
"network_policy": "allow_all",
"registry_allowlist": [
"<string>"
],
"sandbox_tier": "landlock_full",
"worker_count": 1,
"decision_model_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"runner_id": "<string>",
"runner_token": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}{
"detail": "<string>",
"docs_uri": "<string>",
"error_code": "<string>",
"request_id": "<string>",
"title": "<string>",
"action_id": "<string>",
"current_state": "<string>",
"etag": "<string>",
"gate_id": "<string>",
"outcome": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_by": "<string>",
"user_message": "<string>"
}Authorizations
Body
application/json
POST /v1/admin/runners request. Authorized by an existing operator credential,
not an enrollment token. The operator ASSIGNS the policy; the host never
declares one.
Response
Runner registered; the bearer token is returned exactly once
Registered runner and its access token. Save the token securely; it is returned once and only its hash is stored.