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

# List AI Sales Agent activities

> List all activities for an AI Sales Agent



## OpenAPI

````yaml https://api.instantly.ai/openapi/api_v2.json get /api/v2/ai-agents/{id}/activities
openapi: 3.1.0
info:
  title: API Explorer
  description: >-
    The entire API V2 documentation is interactive and can be tested here. To
    the right side of every endpoint you will see a box with an example request.
    You can click on the "Try it" button to send a request to the server right
    from the docs. You will need to provide an API key by clicking the
    `ApiKeyAuth_token` blue text.
  version: 2.0.0
servers:
  - url: https://api.instantly.ai
    description: Instantly API Server
security:
  - ApiKeyAuth: []
tags:
  - name: Analytics
    description: Endpoints related to analytics
    x-group: Analytics
  - name: OAuth
    description: >-
      OAuth authentication endpoints for connecting Google and Microsoft email
      accounts
    x-group: OAuth
  - name: Account
    description: An email account that can be used to send campaigns
    x-group: Account
  - name: Campaign
    description: A campaign that can be sent to a list of recipients
    x-group: Campaign
  - name: Email
    description: >-
      A campaign email, a reply, a manually sent email, or any other email
      that's visible in the Unibox
    x-group: Email
  - name: EmailVerification
    description: A single email verification
    x-group: Email Verification
  - name: LeadList
    description: A list used to store leads
    x-group: Lead List
  - name: InboxPlacementTest
    description: An inbox placement test
    x-group: Inbox Placement Test
  - name: InboxPlacementAnalytics
    description: Analytics data for individual emails in inbox placement tests
    x-group: Inbox Placement Analytics
  - name: InboxPlacementBlacklistAndSpamAssassinReport
    description: Report data for an inbox placement test
    x-group: Inbox Placement Blacklist And SpamAssassin Report
  - name: AIAgent
    description: An AI agent
    x-group: AI Agent
  - name: AIInboxManager
    description: An AI Inbox Manager agent
    x-group: AI Inbox Manager
  - name: AIDeliverabilityAgent
    description: An AI Deliverability Agent
    x-group: AI Deliverability Agent
  - name: AILeadFinderAgent
    description: An AI Lead Finder Agent
    x-group: AI Lead Finder Agent
  - name: APIKey
    description: API Key
    x-group: API Key
  - name: AccountCampaignMapping
    description: Account Campaign Mapping
    x-group: Account Campaign Mapping
  - name: Lead
    description: A lead entity representing an individual lead
    x-group: Lead
  - name: BackgroundJob
    description: A background job that can be used to perform long-running tasks
    x-group: Background Job
  - name: CustomTag
    description: >-
      A custom tag for organizing and categorizing accounts and campaigns. You
      can use them as filters in apis that list accounts and campaigns.
    x-group: Custom Tag
  - name: CustomTagMapping
    description: >-
      This entity represents a tag being assigned to a specific campaign or
      email account. When an email account is assigned a tag, a new custom tag
      mapping entry is created, which connects the tag (`tag_id` field) with the
      email account (`resource_id` field). You can use it to see which tag si
      connected to which resource.
    x-group: Custom Tag Mapping
  - name: BlockListEntry
    description: A blocked email or domain
    x-group: Block List Entry
  - name: LeadLabel
    description: A custom label for categorizing and managing leads
    x-group: Lead Label
  - name: Workspace
    description: A workspace entity representing a workspace
    x-group: Workspace
  - name: SuperSearchEnrichment
    description: >-
      An enrichment can take different forms, such as email enrichment or
      LinkedIn enrichment. Leads may be imported from SuperSearch using the
      dedicated endpoint, or enriched directly within a list or campaign by
      attaching an enrichment to it.
    x-group: SuperSearch Enrichment
  - name: WorkspaceGroupMember
    description: >-
      A member of a workspace group. You can use the endpoints within this
      entity to manage the members of a workspace group.
    x-group: Workspace Group Member
  - name: WorkspaceMember
    description: A member of a workspace with associated user details
    x-group: Workspace Member
  - name: CampaignSubsequence
    description: A subsequence entity representing a follow-up sequence
    x-group: Campaign Subsequence
  - name: AuditLog
    description: Audit log records for tracking system activities
    x-group: Audit Log
  - name: AISalesAgent
    description: >-
      An AI Sales Development Representative that autonomously manages outreach
      campaigns
    x-group: AI Sales Agent
  - name: AISalesAgentActivity
    description: An activity performed by an AI Sales Agent
    x-group: AI Sales Agent
  - name: Webhook
    description: A webhook subscription for receiving event notifications
    x-group: Webhook
  - name: WebhookEvent
    description: A webhook event that was sent or attempted to be sent
    x-group: Webhook Event
  - name: DFYEmailAccountOrder
    description: A Done-For-You email account order
    x-group: DFY Email Account Order
  - name: DomainForwarding
    description: Web forwarding configuration for a domain ordered through Instantly
    x-group: Domain Forwarding
  - name: CustomPromptTemplate
    description: Custom prompt templates for creating custom prompts
    x-group: Custom Prompt Template
  - name: SalesFlow
    description: >-
      Manages how sales users view and interact with campaign and lead lists
      within the sales flow.
    x-group: Sales Flow
  - name: EmailTemplate
    description: A campaign email template
    x-group: Email Template
  - name: WorkspaceBilling
    description: Workspace Billing
    x-group: Workspace Billing
  - name: CRMActions
    description: CRM related actions
    x-group: CRM Actions
paths:
  /api/v2/ai-agents/{id}/activities:
    get:
      tags:
        - AISalesAgentActivity
      summary: List AI Sales Agent activities
      description: List all activities for an AI Sales Agent
      operationId: listAISalesAgentActivity
      parameters:
        - schema:
            type: integer
            minimum: 1
            maximum: 100
            example: 10
          example: 10
          in: query
          name: limit
          required: false
          description: The number of items to return
        - schema:
            type: string
            example: 01956fbd-0eb1-72db-a565-82977a586084
          example: 01956fbd-0eb1-72db-a565-82977a586084
          in: query
          name: starting_after
          required: false
          description: >-
            The ID of the last item in the previous page - used for pagination.
            You can use the value of the `next_starting_after` field from the
            previous response.
        - schema:
            type: array
            items:
              type: string
              enum:
                - pending
                - approved
                - rejected
                - in_progress
                - completed
                - failed
              x-enumDescriptions:
                pending: Activity is pending approval
                approved: Activity has been approved
                rejected: Activity has been rejected
                in_progress: Activity is currently in progress
                completed: Activity has been completed successfully
                failed: Activity has failed
              examples:
                - pending
              example: pending
            example:
              - pending
              - in_progress
          example:
            - pending
            - in_progress
          in: query
          name: action_status
          required: false
          description: Filter by activity status (array of statuses)
        - schema:
            type: array
            items:
              type: string
              enum:
                - create_campaign
                - edit_campaign
                - stop_campaign
                - pause_campaign
                - enrich_leads
                - push_lead
                - recommend_lead
                - warning
                - initial_setup_scrape
                - initial_setup_campaigns
                - initial_setup_enrich
                - reply_received
                - opportunity_received
                - imported_leads
              x-enumDescriptions:
                create_campaign: Create a new campaign
                edit_campaign: Edit an existing campaign
                stop_campaign: Stop a running campaign
                pause_campaign: Pause a running campaign
                enrich_leads: Enrich leads with additional information
                push_lead: Add a new lead to a campaign
                recommend_lead: >-
                  Recommend a previewed lead for the user to approve before
                  enrichment
                initial_setup_scrape: 'Initial setup: scrape website to understand business'
                initial_setup_campaigns: 'Initial setup: prepare initial campaigns'
                initial_setup_enrich: 'Initial setup: enrich initial leads'
                reply_received: Prospect replied to an email
                opportunity_received: Prospect became a new opportunity
                imported_leads: Leads manually imported via CSV upload
                warning: Warning requiring user acknowledgement
              examples:
                - create_campaign
              example: create_campaign
            example:
              - initial_setup_scrape
              - initial_setup_campaigns
          example:
            - initial_setup_scrape
            - initial_setup_campaigns
          in: query
          name: action_type
          required: false
          description: Filter by action type (array of types)
        - schema:
            type: boolean
            example: true
          example: true
          in: query
          name: exclude_live_feed_hidden
          required: false
          description: >-
            Exclude activities the AI Sales Agent live feed hides (warnings and
            delivered lead recommendations) so pagination stays accurate.
            Defaults to false.
        - schema:
            type: string
          in: path
          name: id
          required: true
      responses:
        '200':
          description: The list of AI Sales Agent Activity
          content:
            application/json:
              schema:
                type: object
                properties:
                  items:
                    type: array
                    description: The list of AI Sales Agent Activity
                    items:
                      $ref: '#/components/schemas/AISalesAgentActivity'
                  next_starting_after:
                    type: string
                    examples:
                      - 01a0206f-ed78-77a3-9ea9-0cb1ee7f9d60
                      - '2026-08-20T18:30:01.336Z'
                    description: >-
                      The filter for getting the next items after this one, this
                      could either be a UUID, a timestamp, on an email depending
                      on the specific API
                    example: 01a0206f-ed78-77a3-9ea9-0cb1ee7f9d60
                additionalProperties: false
                required:
                  - items
        '401':
          description: >-
            This request is unauthorized (either the Authorization header is
            missing or invalid, or the API key has been revoked)
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    enum:
                      - 401
                    examples:
                      - 401
                    example: 401
                  error:
                    type: string
                    enum:
                      - Unauthorized
                    examples:
                      - Unauthorized
                    example: Unauthorized
                  message:
                    type: string
                    examples:
                      - Missing Authorization header
                    example: Missing Authorization header
                required:
                  - statusCode
                  - error
                  - message
        '402':
          description: >-
            This request cannot be fulfilled because the workspace does not have
            an active paid plan
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    enum:
                      - 402
                    examples:
                      - 402
                    example: 402
                  error:
                    type: string
                    enum:
                      - Payment Required
                    examples:
                      - Payment Required
                    example: Payment Required
                  message:
                    type: string
                    examples:
                      - Workspace does not have an active paid plan
                    example: Workspace does not have an active paid plan
                required:
                  - statusCode
                  - error
                  - message
        '404':
          description: The requested resource was not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    enum:
                      - 404
                    examples:
                      - 404
                    example: 404
                  error:
                    type: string
                    enum:
                      - Not Found
                    examples:
                      - Not Found
                    example: Not Found
                  message:
                    type: string
                    examples:
                      - Resource not found
                    example: Resource not found
                required:
                  - statusCode
                  - error
                  - message
        '429':
          description: >-
            You have exceeded the rate limit. Please check the rate limit docs
            for more information.
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    enum:
                      - 429
                    examples:
                      - 429
                    example: 429
                  error:
                    type: string
                    enum:
                      - Too Many Requests
                    examples:
                      - Too Many Requests
                    example: Too Many Requests
                  message:
                    type: string
                    examples:
                      - Rate limit exceeded
                    example: Rate limit exceeded
                required:
                  - statusCode
                  - error
                  - message
components:
  schemas:
    AISalesAgentActivity:
      title: AI Sales Agent Activity
      description: An activity performed by an AI Sales Agent
      x-tags:
        - Schemas
        - AISalesAgentActivity
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the activity
          readOnly: true
          format: uuid
          example: 01a0206f-abf8-7e36-bcc9-d99585dce0a4
        ai_sdr_id:
          type: string
          description: ID of the AI Sales Agent that performed this activity
          readOnly: true
          format: uuid
          example: 01a0206f-abf8-7e36-bcc9-d997e8386767
        workspace_id:
          type: string
          description: Workspace ID that owns this activity
          readOnly: true
          format: uuid
          example: 01a0206f-abf8-7e36-bcc9-d9996cdd9ec4
        action_type:
          type: string
          description: Type of action performed
          readOnly: true
          enum:
            - create_campaign
            - edit_campaign
            - stop_campaign
            - pause_campaign
            - enrich_leads
            - push_lead
            - recommend_lead
            - warning
            - initial_setup_scrape
            - initial_setup_campaigns
            - initial_setup_enrich
            - email_sent
            - lead_meeting_booked
            - lead_closed
            - email_opened
            - reply_received
            - opportunity_received
            - campaign_completed
            - imported_leads
          x-enumDescriptions:
            create_campaign: Create Campaign
            edit_campaign: Edit Campaign
            stop_campaign: Stop Campaign
            pause_campaign: Pause Campaign
            enrich_leads: Enrich Leads
            push_lead: Push Lead
            recommend_lead: Recommend Lead
            warning: Warning
            initial_setup_scrape: Initial Setup Scrape
            initial_setup_campaigns: Initial Setup Campaigns
            initial_setup_enrich: Initial Setup Enrich
            email_sent: Email Sent
            lead_meeting_booked: Lead Meeting Booked
            lead_closed: Lead Closed
            email_opened: Email Opened
            reply_received: Reply Received
            opportunity_received: Opportunity Received
            campaign_completed: Campaign Completed
            imported_leads: Imported Leads
          example: create_campaign
        action_status:
          type: string
          description: Status of the activity
          enum:
            - pending
            - approved
            - rejected
            - in_progress
            - completed
            - failed
          x-enumDescriptions:
            pending: Pending
            approved: Approved
            rejected: Rejected
            in_progress: In Progress
            completed: Completed
            failed: Failed
          example: pending
        action_payload:
          type: object
          description: Payload data for the activity action
          readOnly: true
          additionalProperties: true
        action_output:
          type: object
          description: >-
            Output data for frontend display (e.g., lead_email, campaign_name,
            etc.)
          readOnly: true
          additionalProperties: true
        email_id:
          type:
            - 'null'
            - string
          readOnly: true
          format: uuid
          example: 01a0206f-abf8-7e36-bcc9-d99a91a5dec5
        approved_by:
          type:
            - 'null'
            - string
          description: User ID who approved this activity
          readOnly: true
          format: uuid
          example: 01a0206f-abf8-7e36-bcc9-d99c48c6f905
        approved_at:
          type:
            - 'null'
            - string
          description: Timestamp when the activity was approved
          readOnly: true
          format: date-time
          example: '2026-08-20T18:29:44.568Z'
        rejected_by:
          type:
            - 'null'
            - string
          description: User ID who rejected this activity
          readOnly: true
          format: uuid
          example: 01a0206f-abf8-7e36-bcc9-d99ed0949877
        rejected_at:
          type:
            - 'null'
            - string
          description: Timestamp when the activity was rejected
          readOnly: true
          format: date-time
          example: '2026-08-20T18:29:44.568Z'
        rejection_reason:
          type:
            - 'null'
            - string
          description: Reason for rejecting the activity
          readOnly: true
          example: Not aligned with current strategy
        ai_reasoning:
          type:
            - 'null'
            - string
          description: AI reasoning for this activity
          readOnly: true
          example: This lead matches the ICP criteria and has shown interest
        ai_confidence:
          type:
            - 'null'
            - number
          description: AI confidence score for this activity (0-1)
          readOnly: true
          example: 0.85
        result:
          type: object
          description: Result data from executing the activity
          readOnly: true
          additionalProperties: true
        error_message:
          type:
            - 'null'
            - string
          description: Error message if the activity failed
          readOnly: true
          example: 'Failed to create campaign: Invalid email list'
        error_code:
          type: string
          description: Stable error category if the activity failed
          readOnly: true
          enum:
            - insufficient_credits
            - insufficient_upload_limit
            - no_leads_with_email
            - scrape_site_not_supported
            - campaign_operation_failed
            - lead_move_failed
            - enrichment_failed
            - configuration_error
            - master_list_missing
            - temporary_failure
            - prospecting_incomplete
            - internal_error
          example: insufficient_credits
        timestamp_created:
          type: string
          description: Timestamp when the activity was created
          readOnly: true
          format: date-time
          example: '2026-08-20T18:29:44.568Z'
        timestamp_updated:
          type: string
          description: Timestamp when the activity was last updated
          readOnly: true
          format: date-time
          example: '2026-08-20T18:29:44.568Z'
        timestamp_executed:
          type:
            - 'null'
            - string
          description: Timestamp when the activity was executed
          readOnly: true
          format: date-time
          example: '2026-08-20T18:29:44.568Z'
        timestamp_completed:
          type:
            - 'null'
            - string
          description: Timestamp when the activity was completed
          readOnly: true
          format: date-time
          example: '2026-08-20T18:29:44.568Z'
      required:
        - id
        - ai_sdr_id
        - workspace_id
        - action_type
        - action_status
        - timestamp_created
        - timestamp_updated
      additionalProperties: false
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer

````