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

# List Engagements

> Silo deals with their counterparty, owner, evidence count, open commitments and last written update.



## OpenAPI

````yaml https://sonar.turtle.xyz/v1/openapi.json get /organization/{organizationId}/engagements
openapi: 3.1.0
info:
  description: >-
    Sonar's CRM, as a tenant sees it: the events its sensors read, the contacts,
    organizations,

    deals, tasks and documents built from them, and the record of every change.
    Each organization's Sonar is its

    own silo: nothing in it is shared with another. Its agent reads the events
    and proposes or makes the changes;

    the people of the organization read, correct and decide. The organization
    graph is the one exception: a public

    directory of organizations, the same for every organization, that holds
    nothing of any organization's own.


    Every path is under /organization/{organizationId}, the Turtle organization
    whose Sonar you address.

    Authenticate with a Turtle API key, as a bearer token or in X-API-Key. A
    personal key acts as you, in the

    organizations you are a member of; an organization's key reaches that
    organization only.


    ## Versioning and deprecation


    v1 is stable. Within v1, changes are additive only:


    - new operations, and new optional query parameters or request fields;

    - new response fields;

    - new values in a response enum.


    Clients must ignore response fields they do not know and tolerate enum
    values they do not know.


    Anything else is breaking and ships only in a new version (/v2): removing or
    renaming an operation, a

    parameter or a field; making an optional input required; changing a type, a
    format or what a field means;

    accepting fewer values than before; changing what a credential may reach.


    An operation is retired in steps. First it is marked deprecated here and
    every answer it gives carries a

    Deprecation header (RFC 9745, the date it was deprecated), a Sunset header
    (RFC 8594, the date it stops

    answering) and a Link to this policy with rel="deprecation". The sunset is
    at least 90 days after the

    deprecation. Watch for the Deprecation header: it is the notice.
  title: Turtle Sonar API
  version: 1.0.0
servers:
  - url: https://sonar.turtle.xyz/v1
security:
  - bearerAuth: []
  - apiKeyAuth: []
tags:
  - description: The companies you deal with, your own included.
    name: Organizations
  - description: >-
      The public directory of organizations, the same for every workspace, each
      beside your own organization on its domain.
    name: Organization graph
  - description: People, and the roles they hold at organizations.
    name: Contacts
  - description: >-
      Corrections to a role a contact held: a title misread, a date wrong.
      Starting and finishing one are Contacts operations.
    name: Contact roles
  - description: >-
      Deals on your boards, and the subjects from Turtle's catalog they are
      about.
    name: Engagements (deals)
  - description: 'Storylines: the events one topic is made of.'
    name: Threads (storylines)
  - description: Follow-ups with owners and due dates.
    name: Tasks
  - description: >-
      Paperwork held with a counterparty. Sonar records where a document lives,
      not the file.
    name: Documents
  - description: On-chain addresses an organization is known by.
    name: Wallets
  - description: A deal's changes between two reviews.
    name: Reports
  - description: >-
      What the sensors read. Events never change, and writes cite them as
      evidence.
    name: Events
  - description: Named slices of the event log, each read as a poll of its own.
    name: Feeds
  - description: >-
      Where each poller of the event log stands, and how far behind the log it
      is.
    name: Poll marks
  - description: The schedule, from the calendars Sonar reads.
    name: Meetings
  - description: 'The conversation with Sonar''s agent: questions, answers and notes.'
    name: Messages
  - description: 'The change log: every write, the drafts waiting for a person, and undo.'
    name: Change log and drafts
  - description: Boards, their stages, and the card each deal on them carries.
    name: Pipelines (boards)
  - description: The custom fields every other kind of record carries.
    name: Entity cards
  - description: Rules your workspace runs on incoming events.
    name: Rules
  - description: What the agent may do without a person.
    name: Permissions
  - description: >-
      The accounts Sonar reads through: what each may read, its history reads,
      its settings, and disconnecting it. Connecting one is the dashboard's.
    name: Sensing scope
  - description: What your inbound webhooks received.
    name: Webhook deliveries
  - description: What Sonar holds for you, its retention, and deletion.
    name: Data and retention
  - description: >-
      Keys minted for members' own agents, collected by Sonar's agent tier. Only
      the agent tier's own credential may call these.
    name: Agent keys
paths:
  /organization/{organizationId}/engagements:
    get:
      tags:
        - Engagements (deals)
      summary: List Engagements
      description: >-
        Silo deals with their counterparty, owner, evidence count, open
        commitments and last written update.
      operationId: sonarListEngagements
      parameters:
        - description: Only deals on these boards; repeat to OR.
          in: query
          name: pipelineId
          schema:
            description: Only deals on these boards; repeat to OR.
            items:
              $ref: '#/components/schemas/UuidUUID'
            maxItems: 100
            type:
              - array
              - 'null'
        - description: >-
            Only boards of these types (e.g. customer | partner); repeat to OR.
            Omit for all boards.
          in: query
          name: pipelineType
          schema:
            description: >-
              Only boards of these types (e.g. customer | partner); repeat to
              OR. Omit for all boards.
            items:
              type: string
            maxItems: 100
            type:
              - array
              - 'null'
        - description: >-
            Only deals with these organizations as their counterparty; repeat to
            OR. A deal naming none never matches.
          in: query
          name: counterpartyId
          schema:
            description: >-
              Only deals with these organizations as their counterparty; repeat
              to OR. A deal naming none never matches.
            items:
              $ref: '#/components/schemas/UuidUUID'
            maxItems: 100
            type:
              - array
              - 'null'
        - description: >-
            Only deals that share an event with these threads: one a thread
            holds now that the deal holds too. Repeat to OR.
          in: query
          name: threadId
          schema:
            description: >-
              Only deals that share an event with these threads: one a thread
              holds now that the deal holds too. Repeat to OR.
            items:
              $ref: '#/components/schemas/UuidUUID'
            maxItems: 100
            type:
              - array
              - 'null'
        - description: >-
            Only deals these people own or cover — the owner, or on the coverage
            list where the board has one; repeat to OR.
          in: query
          name: ownerId
          schema:
            description: >-
              Only deals these people own or cover — the owner, or on the
              coverage list where the board has one; repeat to OR.
            items:
              $ref: '#/components/schemas/UuidUUID'
            maxItems: 100
            type:
              - array
              - 'null'
        - description: Exact stages; repeat to OR. Omit for all stages.
          in: query
          name: stage
          schema:
            description: Exact stages; repeat to OR. Omit for all stages.
            items:
              type: string
            maxItems: 100
            type:
              - array
              - 'null'
        - description: >-
            Only deals whose stage is of these kinds on its board (lead |
            discovery | closing | launch | closed | lost); repeat to OR. The
            open book is
            stageKind=lead&stageKind=discovery&stageKind=closing&stageKind=launch.
            A deal on a stage its board does not declare matches no kind.
          in: query
          name: stageKind
          schema:
            description: >-
              Only deals whose stage is of these kinds on its board (lead |
              discovery | closing | launch | closed | lost); repeat to OR. The
              open book is
              stageKind=lead&stageKind=discovery&stageKind=closing&stageKind=launch.
              A deal on a stage its board does not declare matches no kind.
            items:
              type: string
            maxItems: 6
            type:
              - array
              - 'null'
        - description: >-
            Only deals whose card holds every word, in any order, case-blind, %
            and _ matched as written: the title, stage, counterparty and owner.
          in: query
          name: search
          schema:
            description: >-
              Only deals whose card holds every word, in any order, case-blind,
              % and _ matched as written: the title, stage, counterparty and
              owner.
            maxLength: 200
            type: string
        - description: >-
            Only the deals the reader owns or covers — the owner, or on the
            coverage list where the board has one — as the signed-in person's
            contact, resolved server-side. Combined with ownerId, the reader
            must be among them. Empty when the reader has no contact in this
            silo.
          in: query
          name: mine
          schema:
            description: >-
              Only the deals the reader owns or covers — the owner, or on the
              coverage list where the board has one — as the signed-in person's
              contact, resolved server-side. Combined with ownerId, the reader
              must be among them. Empty when the reader has no contact in this
              silo.
            type: boolean
        - description: Only deals whose card moved after this instant (RFC3339).
          in: query
          name: updatedAfter
          schema:
            description: Only deals whose card moved after this instant (RFC3339).
            format: date-time
            type:
              - 'null'
              - string
        - description: >-
            created (default) = newest first; recent = last activity first;
            stale = longest untouched first; revenue = largest expected revenue
            first as the board reads it (written, else its formula over the
            card), deals with no figure last; each board counts in its own
            revenueUnit, so filter by pipelineId to compare like with like.
          in: query
          name: sort
          schema:
            description: >-
              created (default) = newest first; recent = last activity first;
              stale = longest untouched first; revenue = largest expected
              revenue first as the board reads it (written, else its formula
              over the card), deals with no figure last; each board counts in
              its own revenueUnit, so filter by pipelineId to compare like with
              like.
            enum:
              - created
              - recent
              - stale
              - revenue
            type: string
        - description: >-
            Also attach the agent's open proposals on each deal, as a sparse
            present / future beside it. Off by default: the row is always what
            is true now.
          in: query
          name: drafts
          schema:
            description: >-
              Also attach the agent's open proposals on each deal, as a sparse
              present / future beside it. Off by default: the row is always what
              is true now.
            type: boolean
        - description: >-
            full (default) = every card value; card = only what a pipeline card
            draws: the title, the fields marked onCard and the money fields. GET
            /engagements/{id} has the rest. rundown = every card value, and
            beside each deal its latest report, the task it has owed longest and
            our people on it.
          in: query
          name: view
          schema:
            description: >-
              full (default) = every card value; card = only what a pipeline
              card draws: the title, the fields marked onCard and the money
              fields. GET /engagements/{id} has the rest. rundown = every card
              value, and beside each deal its latest report, the task it has
              owed longest and our people on it.
            enum:
              - full
              - card
              - rundown
            type: string
        - description: Also answer how many deals match the filter in all, over every page.
          in: query
          name: count
          schema:
            description: >-
              Also answer how many deals match the filter in all, over every
              page.
            type: boolean
        - description: Page size; default 25.
          in: query
          name: limit
          schema:
            description: Page size; default 25.
            maximum: 100
            minimum: 1
            type: integer
        - description: >-
            Opaque cursor from the previous page's nextCursor; omit for the
            first page.
          in: query
          name: cursor
          schema:
            description: >-
              Opaque cursor from the previous page's nextCursor; omit for the
              first page.
            type: string
        - in: path
          name: organizationId
          required: true
          schema:
            $ref: '#/components/schemas/UuidUUID'
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SonarListEngagementsOutput'
          description: OK
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RestErrResponse'
          description: Bad Request
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RestErrResponse'
          description: Internal Server Error
components:
  schemas:
    UuidUUID:
      examples:
        - 248df4b7-aa70-47b8-a036-33ac447e668d
      format: uuid
      type: string
    SonarListEngagementsOutput:
      properties:
        engagements:
          items:
            $ref: '#/components/schemas/SonarEngagementListItem'
          type:
            - array
            - 'null'
        nextCursor:
          type: string
        total:
          type:
            - 'null'
            - integer
      type: object
    RestErrResponse:
      properties:
        code:
          description: Application-specific error code.
          type: integer
        context:
          additionalProperties: {}
          description: Application context.
          type: object
        error:
          description: Error message.
          type: string
        status:
          description: Status text.
          type: string
      type: object
    SonarEngagementListItem:
      properties:
        counterparty:
          $ref: '#/components/schemas/SonarRefView'
        counterpartyId:
          $ref: '#/components/schemas/UuidUUID'
        createdAt:
          format: date-time
          type: string
        derived:
          items:
            type: string
          type: array
        drafts:
          $ref: '#/components/schemas/SonarEntityDraftsView'
        expectedRevenue:
          type: string
        fields:
          $ref: '#/components/schemas/UtilsJSONB'
        id:
          $ref: '#/components/schemas/UuidUUID'
        lastActivityAt:
          description: Derived — when the deal last moved.
          format: date-time
          type:
            - 'null'
            - string
        lastUpdate:
          $ref: '#/components/schemas/SonarEngagementUpdateView'
          description: Derived — the newest prose line in the deal's mutation log.
        latestReport:
          $ref: '#/components/schemas/SonarEngagementReportRef'
          description: >-
            Only with view=rundown: its counterparty's newest report, open or
            decided.
        nextTask:
          $ref: '#/components/schemas/SonarTaskView'
          description: >-
            Only with view=rundown: the open task the deal has owed longest;
            tasks.open says how many.
        owner:
          $ref: '#/components/schemas/SonarContactRefView'
        ownerId:
          $ref: '#/components/schemas/UuidUUID'
        pipeline:
          $ref: '#/components/schemas/SonarPipelineRef'
        pipelineId:
          $ref: '#/components/schemas/UuidUUID'
        stage:
          type: string
        stageSince:
          description: >-
            Derived — when the deal last entered its current stage; its creation
            if it never moved.
          format: date-time
          type: string
        tasks:
          $ref: '#/components/schemas/SonarTaskLoad'
          description: Derived — open-task counts, the reader's own among them.
        team:
          description: >-
            Only with view=rundown: the contacts the card's ours fields hold (a
            deal's Coverage), owner left out.
          items:
            $ref: '#/components/schemas/SonarContactRefView'
          type: array
        title:
          type: string
        updatedAt:
          format: date-time
          type: string
      type: object
    SonarRefView:
      properties:
        id:
          $ref: '#/components/schemas/UuidUUID'
        name:
          type: string
      type: object
    SonarEntityDraftsView:
      properties:
        disposition:
          type: string
        future:
          $ref: '#/components/schemas/UtilsJSONB'
        present:
          $ref: '#/components/schemas/UtilsJSONB'
        proposals:
          items:
            $ref: '#/components/schemas/SonarMutationView'
          type:
            - array
            - 'null'
        refs:
          additionalProperties:
            $ref: '#/components/schemas/SonarEntityRefView'
          type: object
      type: object
    UtilsJSONB:
      additionalProperties: {}
      type: object
    SonarEngagementUpdateView:
      properties:
        createdAt:
          format: date-time
          type: string
        entityId:
          $ref: '#/components/schemas/UuidUUID'
        entityType:
          type: string
        id:
          $ref: '#/components/schemas/UuidUUID'
        op:
          type: string
        rationale:
          type: string
        source:
          type: string
      type: object
    SonarEngagementReportRef:
      properties:
        fields:
          $ref: '#/components/schemas/UtilsJSONB'
        id:
          $ref: '#/components/schemas/UuidUUID'
        open:
          description: Still waiting on a person.
          type: boolean
        periodEnd:
          format: date-time
          type: string
        periodStart:
          format: date-time
          type: string
      type: object
    SonarTaskView:
      properties:
        createdAt:
          format: date-time
          type: string
        description:
          type: string
        engagement:
          $ref: '#/components/schemas/SonarEngagementNameRef'
        engagementId:
          $ref: '#/components/schemas/UuidUUID'
        fields:
          $ref: '#/components/schemas/UtilsJSONB'
        id:
          $ref: '#/components/schemas/UuidUUID'
        owner:
          $ref: '#/components/schemas/SonarContactNameRef'
        ownerId:
          $ref: '#/components/schemas/UuidUUID'
        plan:
          $ref: '#/components/schemas/SafetextProse'
          description: >-
            How the task would get done, in free text: the steps, and any
            content they use. Absent when there is none.
        status:
          $ref: '#/components/schemas/SonarTaskStatus'
        statusSince:
          description: >-
            Derived — when the task last became this status; its creation if it
            never changed.
          format: date-time
          type: string
      type: object
    SonarContactRefView:
      properties:
        addresses:
          $ref: '#/components/schemas/SonarContactAddresses'
        id:
          $ref: '#/components/schemas/UuidUUID'
        name:
          type: string
      type: object
    SonarPipelineRef:
      properties:
        color:
          type: string
        type:
          type: string
      type: object
    SonarTaskLoad:
      properties:
        open:
          type: integer
        yours:
          type: integer
      type: object
    SonarMutationView:
      properties:
        allowance:
          type: string
        allowedBy:
          $ref: '#/components/schemas/UuidUUID'
        allower:
          $ref: '#/components/schemas/SonarNameRef'
        amended:
          items:
            type: string
          type: array
        causedBy:
          $ref: '#/components/schemas/UuidUUID'
        changedAt:
          format: date-time
          type: string
        changes:
          $ref: '#/components/schemas/UtilsJSONB'
        createdAt:
          format: date-time
          type: string
        decidedAt:
          format: date-time
          type:
            - 'null'
            - string
        decidedBy:
          $ref: '#/components/schemas/UuidUUID'
        decider:
          $ref: '#/components/schemas/SonarNameRef'
        entity:
          $ref: '#/components/schemas/SonarNameRef'
        entityId:
          $ref: '#/components/schemas/UuidUUID'
        entityType:
          type: string
        evidence:
          $ref: '#/components/schemas/SonarEvidence'
        heldByAgent:
          type: boolean
        id:
          $ref: '#/components/schemas/UuidUUID'
        mine:
          description: >-
            Derived, beside owner: the signed-in person's contact is the owner.
            Absent when there is no owner, or the reader has no contact in this
            silo.
          type:
            - 'null'
            - boolean
        op:
          type: string
        owner:
          $ref: '#/components/schemas/SonarRefView'
          description: >-
            Derived, on GET /mutations/drafts: the one of ours this draft waits
            on, from the senders of the events it cites, else the member behind
            a message it cites, else the key member of the threads holding those
            events. A person's own draft (source human) waits on its author. For
            a person who is no member of the organization only that: they read
            none of what the rest is worked out from. Absent when none of these
            names one of ours. It routes, and limits nobody: anyone may decide
            the draft.
        proposal:
          $ref: '#/components/schemas/UtilsJSONB'
        rationale:
          type: string
        reason:
          type: string
        refs:
          additionalProperties:
            $ref: '#/components/schemas/SonarEntityRefView'
          type: object
        related:
          $ref: '#/components/schemas/SonarNameRef'
        relatedId:
          $ref: '#/components/schemas/UuidUUID'
        revertedBy:
          $ref: '#/components/schemas/UuidUUID'
        reverts:
          $ref: '#/components/schemas/UuidUUID'
        rule:
          $ref: '#/components/schemas/SonarNameRef'
        ruleId:
          $ref: '#/components/schemas/UuidUUID'
        source:
          type: string
        status:
          type: string
        supersededBy:
          $ref: '#/components/schemas/UuidUUID'
        user:
          $ref: '#/components/schemas/SonarNameRef'
        userId:
          $ref: '#/components/schemas/UuidUUID'
      type: object
    SonarEntityRefView:
      properties:
        kind:
          type: string
        name:
          type: string
      type: object
    SonarEngagementNameRef:
      properties:
        name:
          type: string
        stage:
          type: string
      type: object
    SonarContactNameRef:
      properties:
        addresses:
          $ref: '#/components/schemas/SonarContactAddresses'
        name:
          type: string
      type: object
    SafetextProse:
      maxLength: 20000
      pattern: ^(?:[^<\p{C}]|[\t\n\r‍]|<+(?:[^<A-Za-z/!?\p{C}]|[\t\n\r‍]|$))*$
      type: string
    SonarTaskStatus:
      enum:
        - todo
        - wip
        - blocked
        - done
        - cancelled
      type: string
    SonarContactAddresses:
      items:
        $ref: '#/components/schemas/SonarContactAddress'
      type:
        - array
        - 'null'
    SonarNameRef:
      properties:
        name:
          type: string
      type: object
    SonarEvidence:
      items:
        $ref: '#/components/schemas/SonarEventRef'
      type:
        - array
        - 'null'
    SonarContactAddress:
      properties:
        kind:
          type: string
        value:
          type: string
      type: object
    SonarEventRef:
      properties:
        eventId:
          $ref: '#/components/schemas/UuidUUID'
        messageId:
          $ref: '#/components/schemas/UuidUUID'
        quotes:
          items:
            type: string
          type: array
        sealed:
          type: string
        stance:
          type: string
      type: object
  securitySchemes:
    bearerAuth:
      description: A Turtle API key (sk_...) as a bearer token.
      scheme: bearer
      type: http
    apiKeyAuth:
      description: A Turtle API key (sk_...).
      in: header
      name: X-API-Key
      type: apiKey

````

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