curl --request PUT \
--url https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"outpost_pool_id": "<string>",
"platform": "<string>"
}
'import requests
url = "https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform"
payload = {
"outpost_pool_id": "<string>",
"platform": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({outpost_pool_id: '<string>', platform: '<string>'})
};
fetch('https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform', 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.devin.ai/v3beta1/organizations/{org_id}/default-platform",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'outpost_pool_id' => '<string>',
'platform' => '<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.devin.ai/v3beta1/organizations/{org_id}/default-platform"
payload := strings.NewReader("{\n \"outpost_pool_id\": \"<string>\",\n \"platform\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"outpost_pool_id\": \"<string>\",\n \"platform\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"outpost_pool_id\": \"<string>\",\n \"platform\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"outpost_pool_id": "<string>",
"outpost_pool_name": "<string>",
"platform": "<string>"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}Set Organization Default Platform (Devin API)
Set or clear the organization’s default Devin session placement to a hosted platform or an outpost pool via the v3 organization API
curl --request PUT \
--url https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"outpost_pool_id": "<string>",
"platform": "<string>"
}
'import requests
url = "https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform"
payload = {
"outpost_pool_id": "<string>",
"platform": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({outpost_pool_id: '<string>', platform: '<string>'})
};
fetch('https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform', 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.devin.ai/v3beta1/organizations/{org_id}/default-platform",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'outpost_pool_id' => '<string>',
'platform' => '<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.devin.ai/v3beta1/organizations/{org_id}/default-platform"
payload := strings.NewReader("{\n \"outpost_pool_id\": \"<string>\",\n \"platform\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"outpost_pool_id\": \"<string>\",\n \"platform\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.devin.ai/v3beta1/organizations/{org_id}/default-platform")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"outpost_pool_id\": \"<string>\",\n \"platform\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"outpost_pool_id": "<string>",
"outpost_pool_name": "<string>",
"platform": "<string>"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}{
"status": 123,
"title": "<string>",
"detail": "<string>",
"error_code": "<string>",
"errors": [
{}
],
"instance": "<string>",
"type": "about:blank"
}platform use the creator’s personal default first, then this one.
Permissions
Requires a service user or personal access token with theManageOrgSettings permission at the organization level.
Request fields
Send at most one of:platform: a hosted platform label configured for the organization (for examplelinux,windows, ormacos) or the name of a shared outpost pool, case-insensitive. Platforms take priority when a name matches both.outpost_pool_id: the ID of a shared outpost pool available to the organization.
{}), or both fields as null, to clear the default. The request body is required.
Only shared outpost pools qualify. Personal outposts can’t be the organization default because only their owner can launch sessions on them.
Outposts-only organizations
When the enterprise is in outposts-only mode, only outpost pools are accepted. Hosted platform labels return400.
Errors
400whenplatformmatches no configured platform or shared outpost pool, matches several outpost pools, or names a hosted platform in an outposts-only organization; or whenoutpost_pool_idisn’t a shared pool available to the organization. The error body lists the available platforms and outpost pools.403when the caller lacksManageOrgSettings.422when bothplatformandoutpost_pool_idare set.
Example
curl -X PUT "https://api.devin.ai/v3beta1/organizations/$ORG_ID/default-platform" \
-H "Authorization: Bearer $DEVIN_API_KEY" \
-H "Content-Type: application/json" \
-d '{"platform": "gpu-pool"}'
Authorizations
Service User credential (prefix: cog_)
Path Parameters
Organization ID (prefix: org-)
"org-abc123def456"
Body
Set the organization's default placement for new sessions.
Send at most one of platform and outpost_pool_id; send both as
null (for example {}) to clear the default.
ID of a shared outpost pool available to the organization.
128A hosted platform label configured for the organization (e.g. 'linux', 'windows', 'macos') or the name of a shared outpost pool, case-insensitive; platforms take priority when a name matches both. Unrecognized values are rejected with a 400 that lists the available platforms and outpost pools.
128Response
Successful Response
The organization's default placement for new sessions.
Outpost pool new sessions run on by default. Null when the default is a hosted platform or unset.
Name of the default outpost pool. Null when the default is not an outpost pool, or the pool is no longer available to the organization.
Hosted platform label (e.g. 'linux', 'windows') new sessions run on by default. Null when the default is an outpost pool or unset.

