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

# Retrieve processing traces

> Reads the steps of the processings behind one message (Processing Traces), merged across
providers and sorted by start, each step annotated with the plugin that reported it. POST
because the body lists the processings; the call has no side effect besides the cache.



## OpenAPI

````yaml /api/services-api.yaml post /v1/tenants/{tenantID}/sessions/{sessionID}/processing-traces/retrieval
openapi: 3.0.3
info:
  description: >-
    Talqui is an omnichannel customer service platform that unifies
    conversations from WhatsApp, Instagram, Telegram, and many other channels
    into a single attendant panel, alongside a broader ecosystem of plugins and
    integrations. This API gives developers programmatic access to Talqui's
    services layer, exposing the operations needed to read and manage tenants,
    conversations, plugins, and related resources that power that platform.


    Authentication is available on behalf of an Operator (the default for this
    API), a Plugin Connection, or a Plugin — see the [Talqui authentication
    guide](https://docs.talqui.chat/guides/introduction/authentication/) for how
    each token is obtained and when to use it.


    Need help or have questions not covered here? Reach out to
    support@talqui.com.
  license:
    name: ISC
    url: https://opensource.org/license/isc-license-txt
  title: Talqui - Services API
  version: 0.69.1
servers:
  - description: Production
    url: https://services-api.talqui.chat
security: []
tags:
  - name: Tenants
  - name: Settings
  - name: Analytics/Reports
  - name: Analytics
  - name: Campaigns
  - name: Campaigns/Models
  - name: Contacts
  - name: Contacts/Imports
  - name: Handoff links
  - name: Inboxes
  - name: Messages
  - name: Notifications
  - name: Sessions
  - name: Operators/Shortcuts
  - name: Operators
  - name: Plugins
  - name: Setup
  - name: Uploads
paths:
  /v1/tenants/{tenantID}/sessions/{sessionID}/processing-traces/retrieval:
    post:
      tags:
        - Sessions
      summary: Retrieve processing traces
      description: >-
        Reads the steps of the processings behind one message (Processing
        Traces), merged across

        providers and sorted by start, each step annotated with the plugin that
        reported it. POST

        because the body lists the processings; the call has no side effect
        besides the cache.
      operationId: RetrieveProcessingTracesController
      parameters:
        - in: path
          name: tenantID
          required: true
          schema:
            description: The tenant the session belongs to.
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
            type: string
        - in: path
          name: sessionID
          required: true
          schema:
            description: The conversation whose processing is read.
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
            type: string
      requestBody:
        content:
          application/json:
            schema:
              properties:
                traces:
                  description: >-
                    The processings behind one message, as listed by the
                    discovery endpoint.
                  items:
                    properties:
                      source:
                        description: URN of the plugin that reported the processing.
                        maxLength: 256
                        minLength: 1
                        type: string
                      traceRef:
                        description: Opaque reference of the processing inside that plugin.
                        maxLength: 128
                        minLength: 1
                        type: string
                    required:
                      - source
                      - traceRef
                    type: object
                  maxItems: 10
                  minItems: 1
                  type: array
              required:
                - traces
              type: object
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                additionalProperties: false
                properties:
                  details:
                    items:
                      allOf:
                        - oneOf:
                            - additionalProperties: false
                              properties:
                                kind:
                                  enum:
                                    - text
                                  type: string
                                label:
                                  maxLength: 80
                                  minLength: 1
                                  type: string
                                truncated:
                                  type: boolean
                                value:
                                  type: string
                              required:
                                - label
                                - kind
                                - value
                              type: object
                            - additionalProperties: false
                              properties:
                                kind:
                                  enum:
                                    - json
                                  type: string
                                label:
                                  maxLength: 80
                                  minLength: 1
                                  type: string
                                truncated:
                                  type: boolean
                                value: {}
                              required:
                                - label
                                - kind
                                - value
                              type: object
                            - additionalProperties: false
                              properties:
                                kind:
                                  enum:
                                    - list
                                  type: string
                                label:
                                  maxLength: 80
                                  minLength: 1
                                  type: string
                                truncated:
                                  type: boolean
                                value:
                                  items:
                                    anyOf:
                                      - type: string
                                      - additionalProperties: false
                                        properties:
                                          href:
                                            maxLength: 2048
                                            type: string
                                          label:
                                            maxLength: 120
                                            minLength: 1
                                            type: string
                                        required:
                                          - label
                                          - href
                                        type: object
                                  maxItems: 50
                                  type: array
                              required:
                                - label
                                - kind
                                - value
                              type: object
                            - additionalProperties: false
                              properties:
                                kind:
                                  enum:
                                    - keyValue
                                  type: string
                                label:
                                  maxLength: 80
                                  minLength: 1
                                  type: string
                                truncated:
                                  type: boolean
                                value:
                                  additionalProperties:
                                    type: string
                                  type: object
                              required:
                                - label
                                - kind
                                - value
                              type: object
                        - additionalProperties: false
                          properties:
                            source:
                              description: Plugin URN responsible for the entry.
                              type: string
                            sourceName:
                              description: >-
                                Plugin name from the catalog, shown as "reported
                                by".
                              type: string
                          required:
                            - source
                            - sourceName
                          type: object
                    type: array
                  durationMs:
                    nullable: true
                    type: number
                  processStatus:
                    enum:
                      - succeeded
                      - failed
                      - stopped
                      - running
                    nullable: true
                    type: string
                  sources:
                    items:
                      additionalProperties: false
                      properties:
                        name:
                          description: Plugin name from the catalog.
                          type: string
                        source:
                          description: Plugin URN.
                          type: string
                        status:
                          description: How this source answered.
                          type: string
                        traceRef:
                          description: 'Retrieval only: the processing this entry is about.'
                          type: string
                      required:
                        - source
                        - name
                        - status
                      type: object
                    type: array
                  startedAt:
                    nullable: true
                    type: string
                  status:
                    enum:
                      - ready
                      - pending
                      - not_found
                      - expired
                      - partial
                      - error
                    type: string
                  stepCount:
                    type: number
                  steps:
                    description: Steps of every source merged and sorted by start.
                    items:
                      additionalProperties: false
                      properties:
                        category:
                          enum:
                            - intention
                            - knowledge
                            - decision
                            - model
                            - tool
                            - http
                            - wait
                            - message
                            - handoff
                            - integration
                            - error
                            - generic
                          type: string
                        details:
                          items:
                            oneOf:
                              - additionalProperties: false
                                properties:
                                  kind:
                                    enum:
                                      - text
                                    type: string
                                  label:
                                    maxLength: 80
                                    minLength: 1
                                    type: string
                                  truncated:
                                    type: boolean
                                  value:
                                    type: string
                                required:
                                  - label
                                  - kind
                                  - value
                                type: object
                              - additionalProperties: false
                                properties:
                                  kind:
                                    enum:
                                      - json
                                    type: string
                                  label:
                                    maxLength: 80
                                    minLength: 1
                                    type: string
                                  truncated:
                                    type: boolean
                                  value: {}
                                required:
                                  - label
                                  - kind
                                  - value
                                type: object
                              - additionalProperties: false
                                properties:
                                  kind:
                                    enum:
                                      - list
                                    type: string
                                  label:
                                    maxLength: 80
                                    minLength: 1
                                    type: string
                                  truncated:
                                    type: boolean
                                  value:
                                    items:
                                      anyOf:
                                        - type: string
                                        - additionalProperties: false
                                          properties:
                                            href:
                                              maxLength: 2048
                                              type: string
                                            label:
                                              maxLength: 120
                                              minLength: 1
                                              type: string
                                          required:
                                            - label
                                            - href
                                          type: object
                                    maxItems: 50
                                    type: array
                                required:
                                  - label
                                  - kind
                                  - value
                                type: object
                              - additionalProperties: false
                                properties:
                                  kind:
                                    enum:
                                      - keyValue
                                    type: string
                                  label:
                                    maxLength: 80
                                    minLength: 1
                                    type: string
                                  truncated:
                                    type: boolean
                                  value:
                                    additionalProperties:
                                      type: string
                                    type: object
                                required:
                                  - label
                                  - kind
                                  - value
                                type: object
                          type: array
                        durationMs:
                          nullable: true
                          type: number
                        error:
                          nullable: true
                          type: string
                        highlight:
                          description: >-
                            Short value of interest shown as the step chip (max
                            45 chars).
                          type: string
                        metrics:
                          items:
                            additionalProperties: false
                            properties:
                              label:
                                maxLength: 40
                                minLength: 1
                                type: string
                              value:
                                maxLength: 40
                                type: string
                            required:
                              - label
                              - value
                            type: object
                          type: array
                        plugin:
                          additionalProperties: false
                          description: >-
                            Catalog plugin named by `pluginURN`; when set,
                            `sourceName` is its name. Null otherwise.
                          nullable: true
                          properties:
                            pluginIcon:
                              nullable: true
                              type: string
                            pluginName:
                              type: string
                            pluginURN:
                              type: string
                          required:
                            - pluginURN
                            - pluginName
                            - pluginIcon
                          type: object
                        pluginURN:
                          description: >-
                            Plugin the provider says is responsible for the
                            step.
                          type: string
                        source:
                          description: Plugin URN responsible for the entry.
                          type: string
                        sourceIcon:
                          nullable: true
                          type: string
                        sourceName:
                          description: >-
                            Plugin name from the catalog, shown as "reported
                            by".
                          type: string
                        startedAt:
                          type: string
                        status:
                          enum:
                            - succeeded
                            - failed
                            - stopped
                            - running
                            - discarded
                          type: string
                        stepID:
                          type: string
                        subtitle:
                          type: string
                        title:
                          type: string
                      required:
                        - stepID
                        - category
                        - title
                        - startedAt
                        - durationMs
                        - status
                        - source
                        - sourceName
                        - sourceIcon
                        - plugin
                      type: object
                    type: array
                  version:
                    enum:
                      - 1
                    type: number
                required:
                  - version
                  - status
                  - processStatus
                  - startedAt
                  - durationMs
                  - stepCount
                  - details
                  - steps
                  - sources
                type: object
          description: Response for status 200.
        '400':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/RequestValidationError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            RequestValidationError (error_code 1002): invalid params, or a body
            without 1 to 10 processings.
        '401':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/UnauthorizedError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: 'UnauthorizedError (error_code 1003): missing/invalid operator token.'
        '403':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      oneOf:
                        - $ref: '#/components/schemas/ForbiddenError'
                        - $ref: '#/components/schemas/ProcessingTracesDisabledError'
                        - $ref: '#/components/schemas/ProcessingTracesForbiddenError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            ForbiddenError (error_code 1004): caller is not an operator of this
            tenant. | ProcessingTracesDisabledError (error_code 1205): the
            tenant has the processing display turned off. |
            ProcessingTracesForbiddenError (error_code 1206): the role of the
            caller is below the configured audience.
        '404':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/SessionNotFoundError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            SessionNotFoundError (error_code 1060): sessionID does not exist for
            this tenant.
        '500':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/UnknownError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            UnknownError (error_code 5999): Unexpected internal error not
            otherwise documented for this endpoint.
components:
  schemas:
    RequestValidationError:
      additionalProperties: false
      properties:
        error:
          enum:
            - RequestValidationError
          type: string
        error_code:
          enum:
            - 1002
          type: number
        fields:
          items:
            additionalProperties: false
            properties:
              allowed:
                type: string
              field:
                type: string
              received:
                type: string
            required:
              - field
              - received
              - allowed
            type: object
          type: array
        message:
          example: Invalid request data.
          type: string
        statusCode:
          enum:
            - 400
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
        - fields
      type: object
    UnauthorizedError:
      additionalProperties: false
      properties:
        error:
          enum:
            - UnauthorizedError
          type: string
        error_code:
          enum:
            - 1003
          type: number
        message:
          example: You are not authorized to perform this request.
          type: string
        statusCode:
          enum:
            - 401
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    ForbiddenError:
      additionalProperties: false
      properties:
        error:
          enum:
            - ForbiddenError
          type: string
        error_code:
          enum:
            - 1004
          type: number
        message:
          example: You do not have access to this resource.
          type: string
        statusCode:
          enum:
            - 403
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    ProcessingTracesDisabledError:
      additionalProperties: false
      properties:
        error:
          enum:
            - ProcessingTracesDisabledError
          type: string
        error_code:
          enum:
            - 1205
          type: number
        message:
          example: Processing display is turned off for this tenant.
          type: string
        statusCode:
          enum:
            - 403
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    ProcessingTracesForbiddenError:
      additionalProperties: false
      properties:
        error:
          enum:
            - ProcessingTracesForbiddenError
          type: string
        error_code:
          enum:
            - 1206
          type: number
        message:
          example: Your role in this tenant cannot see message processing.
          type: string
        statusCode:
          enum:
            - 403
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    SessionNotFoundError:
      additionalProperties: false
      properties:
        error:
          enum:
            - SessionNotFoundError
          type: string
        error_code:
          enum:
            - 1060
          type: number
        message:
          example: Session not found.
          type: string
        statusCode:
          enum:
            - 404
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    UnknownError:
      additionalProperties: false
      properties:
        error:
          enum:
            - UnknownError
          type: string
        error_code:
          enum:
            - 5999
          type: number
        message:
          example: For some unknown reason your request has not succeeded.
          type: string
        statusCode:
          enum:
            - 500
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object

````

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