Update details for a specific AI agent
Modifies an AI agent’s information, such as status or metadata.
PUT
/
accounts
/
agent
/
{agentId}
Update details for a specific AI agent
curl --request PUT \
--url https://server.ownid.com/{appId}/accounts/agent/{agentId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "suspended",
"agentType": "custom-ai",
"metadata": {
"notes": "Updated due to new security policy."
}
}
'import requests
url = "https://server.ownid.com/{appId}/accounts/agent/{agentId}"
payload = {
"status": "suspended",
"agentType": "custom-ai",
"metadata": { "notes": "Updated due to new security policy." }
}
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({
status: 'suspended',
agentType: 'custom-ai',
metadata: {notes: 'Updated due to new security policy.'}
})
};
fetch('https://server.ownid.com/{appId}/accounts/agent/{agentId}', 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://server.ownid.com/{appId}/accounts/agent/{agentId}",
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([
'status' => 'suspended',
'agentType' => 'custom-ai',
'metadata' => [
'notes' => 'Updated due to new security policy.'
]
]),
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://server.ownid.com/{appId}/accounts/agent/{agentId}"
payload := strings.NewReader("{\n \"status\": \"suspended\",\n \"agentType\": \"custom-ai\",\n \"metadata\": {\n \"notes\": \"Updated due to new security policy.\"\n }\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://server.ownid.com/{appId}/accounts/agent/{agentId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"status\": \"suspended\",\n \"agentType\": \"custom-ai\",\n \"metadata\": {\n \"notes\": \"Updated due to new security policy.\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://server.ownid.com/{appId}/accounts/agent/{agentId}")
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 \"status\": \"suspended\",\n \"agentType\": \"custom-ai\",\n \"metadata\": {\n \"notes\": \"Updated due to new security policy.\"\n }\n}"
response = http.request(request)
puts response.read_body{
"agentId": "agent_12345",
"agentType": "custom-ai",
"status": "suspended",
"metadata": {
"notes": "Updated due to new security policy."
},
"updatedAt": "2025-02-15T12:00:00.000Z"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Bearer Token for admin authorization
Path Parameters
Unique identifier for the AI agent
Body
application/json
Response
Successful update of agent data
The unique identifier for the AI agent
Example:
"agent_12345"
The type of agent
Example:
"custom-ai"
Current status of the AI agent
Example:
"suspended"
Updated metadata about the agent
Example:
{
"notes": "Updated due to new security policy."
}
Date and time the agent was last updated
Example:
"2025-02-15T12:00:00.000Z"
Was this page helpful?
⌘I
Update details for a specific AI agent
curl --request PUT \
--url https://server.ownid.com/{appId}/accounts/agent/{agentId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "suspended",
"agentType": "custom-ai",
"metadata": {
"notes": "Updated due to new security policy."
}
}
'import requests
url = "https://server.ownid.com/{appId}/accounts/agent/{agentId}"
payload = {
"status": "suspended",
"agentType": "custom-ai",
"metadata": { "notes": "Updated due to new security policy." }
}
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({
status: 'suspended',
agentType: 'custom-ai',
metadata: {notes: 'Updated due to new security policy.'}
})
};
fetch('https://server.ownid.com/{appId}/accounts/agent/{agentId}', 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://server.ownid.com/{appId}/accounts/agent/{agentId}",
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([
'status' => 'suspended',
'agentType' => 'custom-ai',
'metadata' => [
'notes' => 'Updated due to new security policy.'
]
]),
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://server.ownid.com/{appId}/accounts/agent/{agentId}"
payload := strings.NewReader("{\n \"status\": \"suspended\",\n \"agentType\": \"custom-ai\",\n \"metadata\": {\n \"notes\": \"Updated due to new security policy.\"\n }\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://server.ownid.com/{appId}/accounts/agent/{agentId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"status\": \"suspended\",\n \"agentType\": \"custom-ai\",\n \"metadata\": {\n \"notes\": \"Updated due to new security policy.\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://server.ownid.com/{appId}/accounts/agent/{agentId}")
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 \"status\": \"suspended\",\n \"agentType\": \"custom-ai\",\n \"metadata\": {\n \"notes\": \"Updated due to new security policy.\"\n }\n}"
response = http.request(request)
puts response.read_body{
"agentId": "agent_12345",
"agentType": "custom-ai",
"status": "suspended",
"metadata": {
"notes": "Updated due to new security policy."
},
"updatedAt": "2025-02-15T12:00:00.000Z"
}