> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abundly.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Read the activity log

> Trigger runs with their per-stage credit cost. Pass `entryId` for a single entry with its full `steps[]` trace — the most detailed audit surface in the API. Passing `page` or `pageSize` returns a paginated response that echoes both; without either you get the most recent entries capped by `limit`.



## OpenAPI

````yaml /api-reference/workspace-api.json get /workspaceapi/agents/{agentId}/activity-log
openapi: 3.1.0
info:
  title: Abundly Workspace API
  description: >-
    Workspace-level and per-agent data and administration. GET endpoints need a
    workspace API key (wk_) with the Workspace read API scope; POST, PUT, PATCH
    and DELETE endpoints need the Workspace write API scope, except sending and
    revoking invitations (POST and DELETE /workspaceapi/invites), which need the
    Invite members scope instead. The write endpoints mirror the Workspace
    Manager capability. Most are batch operations: ids travel in the JSON body,
    each id gets its own result, and per-id failures still return HTTP 200. The
    team endpoints (create, rename, members) act on a single team or membership
    and answer with standard status codes instead.


    Restricted and personal agents (`isPrivate`) are listed by
    /workspaceapi/agents but return 403 on every per-agent GET except
    promotion-requests, so enumerate from
    /workspaceapi/agents?includeOverview=true rather than iterating agent ids.
    Write endpoints can target restricted and personal agents.
  version: 1.0.0
servers:
  - url: https://service.abundly.ai
    description: Shared platform
  - url: https://{tenant}.service.abundly.ai
    description: Dedicated deployment
    variables:
      tenant:
        default: your-tenant
security:
  - workspaceApiKey: []
paths:
  /workspaceapi/agents/{agentId}/activity-log:
    get:
      summary: Read the activity log
      description: >-
        Trigger runs with their per-stage credit cost. Pass `entryId` for a
        single entry with its full `steps[]` trace — the most detailed audit
        surface in the API. Passing `page` or `pageSize` returns a paginated
        response that echoes both; without either you get the most recent
        entries capped by `limit`.
      operationId: agents-agentId-activity-log
      parameters:
        - name: agentId
          in: path
          required: true
          description: The agent id.
          schema:
            type: string
        - name: limit
          in: query
          required: false
          description: Max entries (default 100).
          schema:
            type: integer
            minimum: 1
            maximum: 500
        - name: page
          in: query
          required: false
          description: If set, return paginated results.
          schema:
            type: integer
            minimum: 1
        - name: pageSize
          in: query
          required: false
          description: Page size when page is set (default 50).
          schema:
            type: integer
            minimum: 1
            maximum: 200
        - name: entryId
          in: query
          required: false
          description: If set, return a single activity log entry by id.
          schema:
            type: string
        - name: newerThan
          in: query
          required: false
          description: >-
            ISO date string. If set, returns only entries newer than this
            timestamp.
          schema:
            type: string
      responses:
        '200':
          description: Success. Empty result sets are also 200.
          content:
            application/json:
              schema:
                description: Which shape comes back depends on the parameters used.
                anyOf:
                  - description: >-
                      Returned when `entryId` is given: a single entry with its
                      `steps[]` trace.
                    type: object
                    properties:
                      id:
                        type: string
                      agentId:
                        type: string
                      customerId:
                        type: string
                      timestamp:
                        description: ISO 8601 timestamp.
                        type: string
                      eventType:
                        description: >-
                          What woke the agent, e.g. a scheduled trigger, email
                          or webhook.
                        type: string
                      event:
                        description: >-
                          The trigger payload. Bodies and attachments are
                          stripped in lists.
                      isScriptRun:
                        type: boolean
                      credits:
                        description: >-
                          Total credits for the run; each phase below also
                          carries its own.
                        type: number
                      errorMessage:
                        description: Set when the run threw rather than completing a phase.
                        type: string
                      scriptExecution:
                        type: object
                        properties: {}
                        additionalProperties: {}
                      preFilter:
                        type: object
                        properties: {}
                        additionalProperties: {}
                      attackDetection:
                        description: >-
                          `skipped: true` means the phase never ran, which is
                          not the same as passing.
                        type: object
                        properties: {}
                        additionalProperties: {}
                      plan:
                        type: object
                        properties: {}
                        additionalProperties: {}
                      securityCheck:
                        type: object
                        properties: {}
                        additionalProperties: {}
                      execution:
                        type: object
                        properties: {}
                        additionalProperties: {}
                      voiceCallUsage:
                        type: object
                        properties: {}
                        additionalProperties: {}
                      steps:
                        description: Only hydrated for a single-entry read via `entryId`.
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                            type:
                              description: '"tool_call", "thinking" or "text".'
                              type: string
                            phase:
                              description: '"script", "plan", "security" or "execution".'
                              type: string
                            toolName:
                              type: string
                            input: {}
                            text:
                              type: string
                            response:
                              type: string
                            status:
                              type: string
                            isError:
                              type: boolean
                            timestamp:
                              description: ISO 8601 timestamp.
                              type: string
                            finishedAt:
                              description: ISO 8601 timestamp.
                              type: string
                            durationMs:
                              type: number
                            credits:
                              type: number
                            omittedChars:
                              description: >-
                                Payload fields left out because the whole entry
                                is too large to return, with their full size in
                                characters.
                              type: object
                              properties:
                                input:
                                  type: number
                                response:
                                  type: number
                                text:
                                  type: number
                              additionalProperties: false
                          required:
                            - id
                            - type
                            - phase
                            - timestamp
                          additionalProperties: {}
                    required:
                      - id
                      - agentId
                      - customerId
                      - timestamp
                      - eventType
                    additionalProperties: {}
                  - description: Returned when `page` or `pageSize` is given.
                    type: object
                    properties:
                      entries:
                        type: array
                        items:
                          description: One trigger run.
                          type: object
                          properties:
                            id:
                              type: string
                            agentId:
                              type: string
                            customerId:
                              type: string
                            timestamp:
                              description: ISO 8601 timestamp.
                              type: string
                            eventType:
                              description: >-
                                What woke the agent, e.g. a scheduled trigger,
                                email or webhook.
                              type: string
                            event:
                              description: >-
                                The trigger payload. Bodies and attachments are
                                stripped in lists.
                            isScriptRun:
                              type: boolean
                            credits:
                              description: >-
                                Total credits for the run; each phase below also
                                carries its own.
                              type: number
                            errorMessage:
                              description: >-
                                Set when the run threw rather than completing a
                                phase.
                              type: string
                            scriptExecution:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            preFilter:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            attackDetection:
                              description: >-
                                `skipped: true` means the phase never ran, which
                                is not the same as passing.
                              type: object
                              properties: {}
                              additionalProperties: {}
                            plan:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            securityCheck:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            execution:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            voiceCallUsage:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            steps:
                              description: >-
                                Only hydrated for a single-entry read via
                                `entryId`.
                              type: array
                              items:
                                type: object
                                properties:
                                  id:
                                    type: string
                                  type:
                                    description: '"tool_call", "thinking" or "text".'
                                    type: string
                                  phase:
                                    description: >-
                                      "script", "plan", "security" or
                                      "execution".
                                    type: string
                                  toolName:
                                    type: string
                                  input: {}
                                  text:
                                    type: string
                                  response:
                                    type: string
                                  status:
                                    type: string
                                  isError:
                                    type: boolean
                                  timestamp:
                                    description: ISO 8601 timestamp.
                                    type: string
                                  finishedAt:
                                    description: ISO 8601 timestamp.
                                    type: string
                                  durationMs:
                                    type: number
                                  credits:
                                    type: number
                                  omittedChars:
                                    description: >-
                                      Payload fields left out because the whole
                                      entry is too large to return, with their
                                      full size in characters.
                                    type: object
                                    properties:
                                      input:
                                        type: number
                                      response:
                                        type: number
                                      text:
                                        type: number
                                    additionalProperties: false
                                required:
                                  - id
                                  - type
                                  - phase
                                  - timestamp
                                additionalProperties: {}
                          required:
                            - id
                            - agentId
                            - customerId
                            - timestamp
                            - eventType
                          additionalProperties: {}
                      totalCount:
                        type: number
                      page:
                        type: number
                      pageSize:
                        type: number
                    required:
                      - entries
                      - totalCount
                      - page
                      - pageSize
                    additionalProperties: false
                  - description: 'The default: most recent entries, up to `limit`.'
                    type: object
                    properties:
                      entries:
                        type: array
                        items:
                          description: One trigger run.
                          type: object
                          properties:
                            id:
                              type: string
                            agentId:
                              type: string
                            customerId:
                              type: string
                            timestamp:
                              description: ISO 8601 timestamp.
                              type: string
                            eventType:
                              description: >-
                                What woke the agent, e.g. a scheduled trigger,
                                email or webhook.
                              type: string
                            event:
                              description: >-
                                The trigger payload. Bodies and attachments are
                                stripped in lists.
                            isScriptRun:
                              type: boolean
                            credits:
                              description: >-
                                Total credits for the run; each phase below also
                                carries its own.
                              type: number
                            errorMessage:
                              description: >-
                                Set when the run threw rather than completing a
                                phase.
                              type: string
                            scriptExecution:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            preFilter:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            attackDetection:
                              description: >-
                                `skipped: true` means the phase never ran, which
                                is not the same as passing.
                              type: object
                              properties: {}
                              additionalProperties: {}
                            plan:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            securityCheck:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            execution:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            voiceCallUsage:
                              type: object
                              properties: {}
                              additionalProperties: {}
                            steps:
                              description: >-
                                Only hydrated for a single-entry read via
                                `entryId`.
                              type: array
                              items:
                                type: object
                                properties:
                                  id:
                                    type: string
                                  type:
                                    description: '"tool_call", "thinking" or "text".'
                                    type: string
                                  phase:
                                    description: >-
                                      "script", "plan", "security" or
                                      "execution".
                                    type: string
                                  toolName:
                                    type: string
                                  input: {}
                                  text:
                                    type: string
                                  response:
                                    type: string
                                  status:
                                    type: string
                                  isError:
                                    type: boolean
                                  timestamp:
                                    description: ISO 8601 timestamp.
                                    type: string
                                  finishedAt:
                                    description: ISO 8601 timestamp.
                                    type: string
                                  durationMs:
                                    type: number
                                  credits:
                                    type: number
                                  omittedChars:
                                    description: >-
                                      Payload fields left out because the whole
                                      entry is too large to return, with their
                                      full size in characters.
                                    type: object
                                    properties:
                                      input:
                                        type: number
                                      response:
                                        type: number
                                      text:
                                        type: number
                                    additionalProperties: false
                                required:
                                  - id
                                  - type
                                  - phase
                                  - timestamp
                                additionalProperties: {}
                          required:
                            - id
                            - agentId
                            - customerId
                            - timestamp
                            - eventType
                          additionalProperties: {}
                    required:
                      - entries
                    additionalProperties: false
        '400':
          $ref: '#/components/responses/Error'
        '401':
          $ref: '#/components/responses/Error'
        '403':
          $ref: '#/components/responses/Error'
        '404':
          $ref: '#/components/responses/Error'
components:
  responses:
    Error:
      description: >-
        Error. Every failure on this API returns JSON with a single `error`
        field.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                description: >-
                  Human-readable message. Every error on this API uses this
                  shape.
                type: string
            required:
              - error
            additionalProperties: false
  securitySchemes:
    workspaceApiKey:
      type: http
      scheme: bearer
      description: >-
        Workspace API key (wk_). GET endpoints require the Workspace read API
        scope, POST, PUT, PATCH and DELETE endpoints the Workspace write API
        scope, and sending or revoking invitations (POST and DELETE
        /workspaceapi/invites) the Invite members scope. A key stops working
        when it expires or is disabled.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.