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

# Search timeline

> Everything that happened to one person, newest first, one act one row: their messages on every channel (ours as sends with their outcomes, theirs as replies), the ledger's facts (invites, accepts, visits, likes, stage moves, tags, tables, workflow steps), the thread pills, the tasks and the live plan, merged from the inbox and the playtables ledger through one cursor. Scope by person_sid (the whole person) or conversation_sid (a thread; linked, it is its person's timeline). Read the row in the slot kind names; a child row (an open, a click, a bounce, an accept, the invite's note) names its parent in refers_to, so fold it rather than counting it twice. No total and no counts: page with the cursor while has_more. For a thread's signals (opened, clicked, no reply, and for how long) ask get_conversation with include signals instead. 503 playtables_unavailable when playtables does not answer the ledger read: never an empty page, try again later.

Contract:
- MCP tool `search_timeline`, registry package `mcp.unibox/timeline`, mount `unibox.inbox`.
- Operation `search`, response envelope `search`.
- Flags: read only.



## OpenAPI

````yaml /api-reference/unibox/openapi.yaml post /api/timeline/search
openapi: 3.0.3
info:
  title: 'GetSales public contract: gs.service.unibox'
  description: >-
    The team inbox and the AI SDR: every LinkedIn and email thread in one place
    (conversations, messages, the timeline events), the manual tasks a thread
    spawns, the sender profiles the team speaks through with their LinkedIn
    account and mailboxes, and the one agent per team with its scenarios, plans
    and runs.


    GENERATED. This document is projected from the Zod MCP tool registry in
    `product/mcp/gs.mcp` (one tool per public endpoint, 1:1). Do not edit it by
    hand; edit the tool definition and regenerate with `pnpm openapi:public`.


    Surface: the public `/api` contract of `gs.service.unibox`, 125 operations.
    This is the only OpenAPI document the platform publishes. Internal
    (`/internal`) and health endpoints are deliberately absent: they are not
    part of any contract, they can change without notice, and the service source
    is their only description.


    Conventions:

    - Auth is a bearer JWT, optionally narrowed by the `Team-SID` header.

    - Every success body is an MCP envelope: `success: true` plus one typed
    `operation` shape (`search`, `get`, `create`, `update`, `delete`, `metrics`,
    `group_by`, `action`), and a `meta` block with `trace_id` for support.

    - Every failure is the same `McpError` envelope with a code from a fixed
    16-code taxonomy, so a client maps errors once.

    - Lists page with `page_size` (0 to 500, default 50) plus an opaque forward
    `cursor`; `page_size: 0` returns counts only.

    - On `GET` and `DELETE`, object-valued query parameters (`filter`, `sort`)
    travel as JSON text and array-valued ones repeat as `name[]=value`.

    - The MCP-only `_meta` field (usage analytics) never reaches the backend and
    is not part of this contract.
  version: '1.0'
  contact:
    name: GetSales
    url: https://getsales.io
    email: support@getsales.io
  license:
    name: Proprietary
    url: https://getsales.io/terms
servers:
  - url: https://beta.getsales.io/unibox/v1
    description: >-
      Production (the gateway path on the beta ring; the origin is provisioned
      per DEPLOY_MAP.md)
security:
  - BearerJwt: []
    TeamSid: []
tags:
  - name: agent_answers
    description: >-
      Registry package `mcp.unibox/agent_answers`, served on MCP mount
      `unibox.knowledge`.
  - name: agent_conversation_uploads
    description: >-
      Registry package `mcp.unibox/agent_conversation_uploads`, served on MCP
      mount `unibox.agent-memory`.
  - name: agent_examples
    description: >-
      Registry package `mcp.unibox/agent_examples`, served on MCP mount
      `unibox.agent-memory`.
  - name: agent_hints
    description: >-
      Registry package `mcp.unibox/agent_hints`, served on MCP mount
      `unibox.agent-memory`.
  - name: agent_plans
    description: >-
      Registry package `mcp.unibox/agent_plans`, served on MCP mount
      `unibox.agent`.
  - name: agent_runs
    description: >-
      Registry package `mcp.unibox/agent_runs`, served on MCP mount
      `unibox.agent-memory`.
  - name: agent_scenarios
    description: >-
      Registry package `mcp.unibox/agent_scenarios`, served on MCP mount
      `unibox.agent`.
  - name: agent_source_parses
    description: >-
      Registry package `mcp.unibox/agent_source_parses`, served on MCP mount
      `unibox.knowledge`.
  - name: agent_sources
    description: >-
      Registry package `mcp.unibox/agent_sources`, served on MCP mount
      `unibox.knowledge`.
  - name: agent_tests
    description: >-
      Registry package `mcp.unibox/agent_tests`, served on MCP mount
      `unibox.agent-memory`.
  - name: agents
    description: >-
      Registry package `mcp.unibox/agents`, served on MCP mount
      `unibox.website`.
  - name: conversation_events
    description: >-
      Registry package `mcp.unibox/conversation_events`, served on MCP mount
      `unibox.inbox`.
  - name: conversations
    description: >-
      Registry package `mcp.unibox/conversations`, served on MCP mount
      `unibox.inbox`.
  - name: messages
    description: >-
      Registry package `mcp.unibox/messages`, served on MCP mount
      `unibox.inbox`.
  - name: sender_profiles
    description: >-
      Registry package `mcp.unibox/sender_profiles`, served on MCP mount
      `unibox.sender-profiles`.
  - name: tasks
    description: Registry package `mcp.unibox/tasks`, served on MCP mount `unibox.inbox`.
  - name: timeline
    description: >-
      Registry package `mcp.unibox/timeline`, served on MCP mount
      `unibox.inbox`.
paths:
  /api/timeline/search:
    post:
      tags:
        - timeline
      summary: Search timeline
      description: >-
        Everything that happened to one person, newest first, one act one row:
        their messages on every channel (ours as sends with their outcomes,
        theirs as replies), the ledger's facts (invites, accepts, visits, likes,
        stage moves, tags, tables, workflow steps), the thread pills, the tasks
        and the live plan, merged from the inbox and the playtables ledger
        through one cursor. Scope by person_sid (the whole person) or
        conversation_sid (a thread; linked, it is its person's timeline). Read
        the row in the slot kind names; a child row (an open, a click, a bounce,
        an accept, the invite's note) names its parent in refers_to, so fold it
        rather than counting it twice. No total and no counts: page with the
        cursor while has_more. For a thread's signals (opened, clicked, no
        reply, and for how long) ask get_conversation with include signals
        instead. 503 playtables_unavailable when playtables does not answer the
        ledger read: never an empty page, try again later.


        Contract:

        - MCP tool `search_timeline`, registry package `mcp.unibox/timeline`,
        mount `unibox.inbox`.

        - Operation `search`, response envelope `search`.

        - Flags: read only.
      operationId: search_timeline
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SearchTimelineRequest'
      responses:
        '200':
          description: '`search` success envelope.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchTimelineResponse'
        4XX:
          $ref: '#/components/responses/McpClientError'
        5XX:
          $ref: '#/components/responses/McpServerError'
components:
  schemas:
    SearchTimelineRequest:
      type: object
      description: Request body of `search_timeline`.
      properties:
        filter:
          type: object
          properties:
            person_sid:
              type: string
              minLength: 18
              maxLength: 18
              pattern: ^cr_pp_
              description: >-
                The person's whole timeline: every conversation of theirs on
                every channel and every ledger fact of the row.
            conversation_sid:
              type: string
              minLength: 18
              maxLength: 18
              pattern: ^ub_cv_
              description: >-
                A thread. Linked to a person, it reads as that person's timeline
                (every conversation, the ledger); unlinked, as its own rows.
          description: >-
            Exactly one of person_sid and conversation_sid; both or neither is a
            422.
        page_size:
          type: integer
          minimum: 1
          maximum: 200
          description: >-
            1..200, default 50: the merged page. Each source contributes up to
            that many rows, and a page may run shorter when a source holds rows
            back behind the watermark; has_more is the only end signal.
        cursor:
          type: string
          nullable: true
          maxLength: 4096
          description: >-
            The composite cursor from the previous page's pagination.next_cursor
            (opaque: every source's position). Omit it for the newest page.
      required:
        - filter
    SearchTimelineResponse:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - true
        operation:
          type: string
          enum:
            - search
        items:
          type: array
          items:
            type: object
            properties:
              item:
                type: object
                properties:
                  key:
                    type: string
                    maxLength: 64
                    description: >-
                      Stable per row: message:ub_ms_..., fact:cr_ac_...,
                      event:ub_ev_..., task:ub_tk_..., plan:ub_pl_....
                  kind:
                    type: string
                    enum:
                      - message
                      - fact
                      - event
                      - task
                      - plan
                    description: >-
                      The store the row came from; read the slot it names
                      (message, activity, event, task or plan) and nothing else.
                  at:
                    type: string
                    description: >-
                      ISO 8601 UTC, the sort instant: a message's created_at, a
                      fact's occurred_at, a pill's, a task's or a plan's
                      created_at. Pages are ordered by it, newest first.
                  conversation_sid:
                    type: string
                    nullable: true
                    minLength: 18
                    maxLength: 18
                    pattern: ^ub_cv_
                    description: >-
                      The rail: the thread the row belongs to. Null = the
                      neutral rail, a fact of no conversation (a stage move, a
                      tag, a table).
                  channel:
                    type: string
                    nullable: true
                    enum:
                      - linkedin
                      - email
                    description: >-
                      linkedin | email, or null on a pill, a task, the plan and
                      a CRM fact.
                  account_sid:
                    type: string
                    nullable: true
                    description: >-
                      The sender profile's channel account behind the row (the
                      conversation's anchor of that channel; a fact's
                      linkedin_account_sid / mailbox_sid), gtm's sid. Null when
                      no account speaks for the row.
                  refers_to:
                    type: object
                    nullable: true
                    properties:
                      kind:
                        type: string
                        enum:
                          - message
                          - invite
                        description: >-
                          message: an open, a click or a bounce naming their
                          email (ln_ms_... / em_ms_...); invite: an accept, a
                          withdrawal or the invite's note naming their invite
                          (ln_cr_...).
                      gtm_sid:
                        type: string
                        maxLength: 64
                        description: >-
                          The parent's gtm sid. The parent is a message row
                          (provider_message_sid) or the invite the ledger
                          recorded; fold the child into it when it is in the
                          window.
                    required:
                      - kind
                      - gtm_sid
                    description: >-
                      A child row's parent: set on an open, a click, a bounce,
                      an accept, a withdrawal and the invite's note; null on
                      every other row.
                  context:
                    type: object
                    nullable: true
                    properties:
                      workflow_sid:
                        type: string
                        nullable: true
                        description: wf_wf_... or null.
                      workflow_step_id:
                        type: integer
                        nullable: true
                      workflow_record_sid:
                        type: string
                        nullable: true
                        description: wf_rc_... or null.
                    required:
                      - workflow_sid
                      - workflow_step_id
                      - workflow_record_sid
                    description: >-
                      The workflow context the ledger's sent fact lends a
                      message row that carries no automation_ref of its own;
                      null otherwise.
                  message:
                    type: object
                    nullable: true
                    properties:
                      sid:
                        type: string
                    required:
                      - sid
                    description: >-
                      kind message: the MessageDomain (// see ./messages.md),
                      drafts included, a canceled draft never.
                  activity:
                    type: object
                    nullable: true
                    properties:
                      sid:
                        type: string
                    required:
                      - sid
                    description: >-
                      kind fact: the playtables ActivityDomain verbatim (type,
                      category, payload, workflow_*, occurred_at, created_by;
                      playtables // see activities.md).
                  event:
                    type: object
                    nullable: true
                    properties:
                      sid:
                        type: string
                    required:
                      - sid
                    description: >-
                      kind event: the ConversationEventDomain pill (// see
                      ./conversation_events.md). workflow_action and engagement
                      pills never appear here: the ledger's fact draws the act.
                  task:
                    type: object
                    nullable: true
                    properties:
                      sid:
                        type: string
                    required:
                      - sid
                    description: 'kind task: the TaskDomain (// see ./tasks.md).'
                  plan:
                    type: object
                    nullable: true
                    properties:
                      sid:
                        type: string
                    required:
                      - sid
                    description: >-
                      kind plan: the live AgentPlanDomain, proposed or active
                      (// see ./agent_plans.md).
                required:
                  - key
                  - kind
                  - at
                  - conversation_sid
                  - channel
                  - account_sid
                  - refers_to
                  - context
              included:
                type: object
                additionalProperties: {}
            required:
              - item
              - included
        pagination:
          type: object
          properties:
            next_cursor:
              type: string
              nullable: true
            has_more:
              type: boolean
            total_count:
              type: integer
              nullable: true
          required:
            - next_cursor
            - has_more
            - total_count
        applied_filters:
          type: object
          additionalProperties: {}
        includes:
          type: array
          items:
            type: string
        meta:
          type: object
          properties:
            trace_id:
              type: string
              description: UUID v7; same 128-bit value as the X-Trace-Id header.
            span_id:
              type: string
              pattern: ^[0-9a-f]{16}$
              description: 16 hex chars, root span of this request.
            timestamp:
              type: string
              description: ISO 8601 UTC (Y-m-dTH:i:sZ), response time.
            duration_ms:
              type: integer
              minimum: 0
              description: Server-side wall clock.
            team_sid:
              type: string
              nullable: true
              description: >-
                The team this call ran in (the token team, or the team_sid
                override). Null when unauthenticated; absent from pre-2026-08-20
                backends.
            actor_type:
              type: string
              nullable: true
              description: >-
                user | agent | api_key | system. Null when unauthenticated;
                absent from pre-2026-08-20 backends.
          required:
            - trace_id
            - span_id
            - timestamp
            - duration_ms
        counts:
          type: object
          additionalProperties: {}
      required:
        - success
        - operation
        - items
        - pagination
        - applied_filters
        - includes
        - meta
    McpError:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - false
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - validation_failed
                - nothing_to_update
                - not_found
                - relation_not_found
                - invalid_transition
                - limit_exceeded
                - payment_required
                - duplicate_rejected
                - conflict
                - delete_blocked
                - unauthorized
                - forbidden
                - rate_limited
                - internal_error
                - service_unavailable
                - not_implemented
            message:
              type: string
            recoverable:
              type: boolean
            suggestion:
              type: string
            field_errors:
              type: object
              additionalProperties:
                type: array
                items:
                  type: object
                  properties:
                    rule:
                      type: string
                    message:
                      type: string
                  required:
                    - rule
                    - message
            blockers:
              type: array
              items:
                type: object
                properties:
                  type:
                    type: string
                    description: >-
                      Machine-readable blocker type (active_flow, pending_tasks,
                      …).
                  severity:
                    type: string
                    enum:
                      - hard
                      - soft
                    description: >-
                      hard = external action required; soft = acknowledge is
                      enough.
                  description:
                    type: string
                  entity_sid:
                    type: string
                    nullable: true
                  count:
                    type: integer
                  resolution:
                    type: string
                    description: 'Hard: tool name to call. Soft: code for acknowledge[].'
                  resolution_hint:
                    type: string
                required:
                  - type
                  - severity
                  - description
                  - entity_sid
                  - resolution
                  - resolution_hint
            context:
              type: object
              additionalProperties: {}
          required:
            - code
            - message
            - recoverable
        meta:
          type: object
          properties:
            trace_id:
              type: string
              description: UUID v7; same 128-bit value as the X-Trace-Id header.
            span_id:
              type: string
              pattern: ^[0-9a-f]{16}$
              description: 16 hex chars, root span of this request.
            timestamp:
              type: string
              description: ISO 8601 UTC (Y-m-dTH:i:sZ), response time.
            duration_ms:
              type: integer
              minimum: 0
              description: Server-side wall clock.
            team_sid:
              type: string
              nullable: true
              description: >-
                The team this call ran in (the token team, or the team_sid
                override). Null when unauthenticated; absent from pre-2026-08-20
                backends.
            actor_type:
              type: string
              nullable: true
              description: >-
                user | agent | api_key | system. Null when unauthenticated;
                absent from pre-2026-08-20 backends.
          required:
            - trace_id
            - span_id
            - timestamp
            - duration_ms
      required:
        - success
        - error
  responses:
    McpClientError:
      description: >-
        MCP error envelope. `error.code` is one of validation_failed,
        nothing_to_update, not_found, relation_not_found, invalid_transition,
        limit_exceeded, payment_required, duplicate_rejected, conflict,
        delete_blocked, unauthorized, forbidden, rate_limited, not_implemented.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/McpError'
    McpServerError:
      description: >-
        MCP error envelope with `error.code` internal_error or
        service_unavailable.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/McpError'
  securitySchemes:
    BearerJwt:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Access token issued by gs.service.id. Its `access_identity` claim
        carries `team_sid`, `actor_sid` and `actor_type`, and that team scope is
        authoritative.
    TeamSid:
      type: apiKey
      in: header
      name: Team-SID
      description: >-
        Team scope for tokens that do not carry one. Ignored when the token
        already names a team.

````

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