Submit an agent desktop action
curl --request POST \
--url https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"generation": 2,
"action": {
"x": 123,
"y": 123,
"button": 4,
"pressed": true,
"keysym": 2,
"text": "<string>",
"delta_x": 0,
"delta_y": 0
}
}
'import requests
url = "https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions"
payload = {
"generation": 2,
"action": {
"x": 123,
"y": 123,
"button": 4,
"pressed": True,
"keysym": 2,
"text": "<string>",
"delta_x": 0,
"delta_y": 0
}
}
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({
generation: 2,
action: {
x: 123,
y: 123,
button: 4,
pressed: true,
keysym: 2,
text: '<string>',
delta_x: 0,
delta_y: 0
}
})
};
fetch('https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions"
payload := strings.NewReader("{\n \"generation\": 2,\n \"action\": {\n \"x\": 123,\n \"y\": 123,\n \"button\": 4,\n \"pressed\": true,\n \"keysym\": 2,\n \"text\": \"<string>\",\n \"delta_x\": 0,\n \"delta_y\": 0\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))
}{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"generation": 123,
"seq": 123,
"submitted_at": "2023-11-07T05:31:56Z"
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Desktops
Submit an agent desktop action
Fences the action at the supplied generation and returns a pending action that must be confirmed after a fresh observation.
POST
/
orgs
/
{orgID}
/
projects
/
{projectID}
/
machines
/
{machineID}
/
desktop-sessions
/
{desktopSessionID}
/
agent
/
actions
Submit an agent desktop action
curl --request POST \
--url https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"generation": 2,
"action": {
"x": 123,
"y": 123,
"button": 4,
"pressed": true,
"keysym": 2,
"text": "<string>",
"delta_x": 0,
"delta_y": 0
}
}
'import requests
url = "https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions"
payload = {
"generation": 2,
"action": {
"x": 123,
"y": 123,
"button": 4,
"pressed": True,
"keysym": 2,
"text": "<string>",
"delta_x": 0,
"delta_y": 0
}
}
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({
generation: 2,
action: {
x: 123,
y: 123,
button: 4,
pressed: true,
keysym: 2,
text: '<string>',
delta_x: 0,
delta_y: 0
}
})
};
fetch('https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.staging.bma.beeos.ai/api/v1/orgs/{orgID}/projects/{projectID}/machines/{machineID}/desktop-sessions/{desktopSessionID}/agent/actions"
payload := strings.NewReader("{\n \"generation\": 2,\n \"action\": {\n \"x\": 123,\n \"y\": 123,\n \"button\": 4,\n \"pressed\": true,\n \"keysym\": 2,\n \"text\": \"<string>\",\n \"delta_x\": 0,\n \"delta_y\": 0\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))
}{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"generation": 123,
"seq": 123,
"submitted_at": "2023-11-07T05:31:56Z"
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>",
"current_digest": "<string>",
"issues": [
{
"path": "<string>",
"message": "<string>",
"line": 2,
"column": 2
}
]
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Authorizations
bearerAuthbrowserSessionCookie & csrfHeader
An opaque BMA personal or organization bearer token.
Path Parameters
Organization ID (org_...).
Pattern:
^org_[a-z2-7]{26}$Project ID (proj_...).
Pattern:
^proj_[a-z2-7]{26}$Machine ID (mch_...).
Pattern:
^mch_[a-z2-7]{26}$Desktop session ID (dsn_...).
Pattern:
^dsn_[a-z2-7]{26}$Body
application/json