Skip to main content
GET
/
projects
/
{project_id}
/
agents
/
{agent_id}
/
actions
List Agent Actions
curl --request GET \
  --url https://api.example.com/projects/{project_id}/agents/{agent_id}/actions
import requests

url = "https://api.example.com/projects/{project_id}/agents/{agent_id}/actions"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://api.example.com/projects/{project_id}/agents/{agent_id}/actions', 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.example.com/projects/{project_id}/agents/{agent_id}/actions",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$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.example.com/projects/{project_id}/agents/{agent_id}/actions"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.example.com/projects/{project_id}/agents/{agent_id}/actions")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/projects/{project_id}/agents/{agent_id}/actions")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
[
  {
    "timestamp": "2023-11-07T05:31:56Z",
    "event": {
      "organization_id": "<string>",
      "resource_id": "<string>",
      "resource_name": "<string>",
      "provider": "<string>",
      "resource_type": "<string>",
      "event_type": "<string>",
      "id": "<string>",
      "actor_type": "<string>",
      "actor_id": "<string>",
      "error": "<string>",
      "timestamp": "2023-11-07T05:31:56Z",
      "expires_at": "2023-11-07T05:31:56Z"
    },
    "log": {
      "agent_resource_id": "<string>",
      "message": "<string>",
      "id": "<string>",
      "instance_id": "<string>",
      "metadata": {},
      "timestamp": "2023-11-07T05:31:56Z",
      "expires_at": "2023-11-07T05:31:56Z"
    }
  }
]
{
  "detail": [
    {
      "loc": [
        "<string>"
      ],
      "msg": "<string>",
      "type": "<string>",
      "input": "<unknown>",
      "ctx": {}
    }
  ]
}

Path Parameters

agent_id
string
required
project_id
string
required

Query Parameters

since
string<date-time> | null

Start of time window (ISO 8601). Defaults to 1 hour ago.

until
string<date-time> | null

End of time window (ISO 8601). Defaults to now.

limit
integer
default:50

Maximum entries to return.

Required range: 1 <= x <= 500

Response

Successful Response

source
enum<string>
required
Available options:
event,
log
timestamp
string<date-time>
required
event
LifecycleEvent · object | null

A recorded lifecycle state transition for a resource.

Attributes: id: SurrealDB record ID (populated by database). organization_id: Tenant that owns the resource. resource_id: SurrealDB resource ID. resource_name: Human-readable resource name. provider: Provider that manages the resource. resource_type: Resource type name. event_type: Lifecycle event that caused the transition (e.g. apply, success, failure). from_state: State before transition, None for initial creation. to_state: State after transition. actor_type: Who caused this event ("user", "agent", "system"), None for legacy events. actor_id: Identifier for the actor (user ID or agent resource ID), None for legacy events. error: Error message when transitioning to FAILED state. timestamp: When the transition occurred. expires_at: When this event should be garbage collected.

log
AgentLog · object | null

A recorded action or decision by an AI agent.

Agent logs live inside each organization's SurrealDB namespace — the namespace is the organization boundary, so no per-record organization_id field is carried on the row.

Attributes: id: SurrealDB record ID (populated by database). agent_resource_id: SurrealDB ID of the agent resource. instance_id: Agent instance that produced this log entry. log_type: Category of this log entry. message: Human-readable description of what happened. metadata: Flexible payload (tool name, arguments, error details, etc.). timestamp: When this action occurred. expires_at: When this log entry should be garbage collected.