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

# Get a message

> Look up a single message by id.

Works for a message you sent or an agent reply. Useful for polling a long-running reply until `status` goes from `streaming` to `completed`.


## OpenAPI

````yaml api-reference/openapi.json GET /messages/{message_id}
openapi: 3.1.0
info:
  title: Biomni Public API — V0
  description: >-
    The public API for **Biomni** — the AI agent platform for clinical genomics
    (variant annotation, ClinVar lookups, PMID-cited literature, and project
    file drives). Create projects and Tasks, send messages to the agent, stream
    its replies, manage files, and check your usage — all from your own code.


    **Authentication**: send `Authorization: Bearer <your-api-key>`. The adapter
    forwards your key straight to Biomni; it never stores it.


    **Safe retries**: send `Idempotency-Key: <token>` on POST endpoints
    (`/projects`, `/tasks`, `/messages`, `/files/uploads`) so a retried request
    won't create a duplicate.
  version: 0.1.0
servers:
  - url: https://api.phylo.bio/api/v1
security: []
paths:
  /messages/{message_id}:
    get:
      tags:
        - messages
      summary: Get a message
      description: Look up a single message by id.
      operationId: get_message_messages__message_id__get
      parameters:
        - name: message_id
          in: path
          required: true
          schema:
            type: string
            title: Message Id
      responses:
        '200':
          description: Message record (user or aggregated assistant).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Message'
              examples:
                user_message:
                  summary: A user message
                  value:
                    id: msg_a4f9b5cc30d8
                    object: message
                    task_id: sess_d9711ec9b477
                    created: 1779132780
                    role: user
                    content:
                      - type: text
                        text: >-
                          I'm a clinical genomics analyst working up Patient001.
                          There are 3 BRCA1 pathogenic-flagged variants in the
                          attached VCF. For each variant: describe ClinVar
                          significance, flag PARP inhibitor eligibility, note
                          any conflicts in the literature. Cite ClinVar VCV/RCV
                          IDs and PMIDs.
                    metadata: {}
                    platform: api
                completed_assistant:
                  summary: Aggregated assistant message (completed turn)
                  value:
                    id: msg_1a0ef0fa8e26
                    object: message
                    task_id: sess_d9711ec9b477
                    created: 1779132785
                    role: assistant
                    status: completed
                    completed_at: 1779133414
                    content:
                      - type: text
                        text: >-
                          Loaded the genetic-variant-annotation skill. For these
                          3 BRCA1 variants I'll (1) query ClinVar's REST API
                          directly for each rsID to get current assertions,
                          review status, star ratings, and conditions, and (2)
                          cross-reference NCBI's ClinVar records for conflicting
                          submissions and literature PMIDs.
                      - type: tool_use
                        id: toolu_01RkjLRcNtbVHBBwWDDk7gmF
                        name: Skill
                        input:
                          action: load
                          name: genetic-variant-annotation
                      - type: tool_result
                        tool_use_id: toolu_01RkjLRcNtbVHBBwWDDk7gmF
                        content: >-
                          # Skill: genetic-variant-annotation


                          **Category**: genomics_genetics


                          **Description**: Annotate genomic variants in VCF
                          files with functional effects, clinical significance,
                          and pathogenicity predictions. … (truncated)
                      - type: text
                        text: >-
                          Here is the full structured report. Two deliverables
                          are saved: `report_Patient001_BRCA1_variants.md` and
                          `Patient001_BRCA1_variant_report.json`. All three
                          variants are confirmed pathogenic by ClinVar (3-star
                          review); PARP inhibitor eligibility applies for HBOC
                          and ovarian indications. … (truncated; real response
                          has 61 content blocks)
                    metadata: {}
                    platform: api
                    input:
                      user_message_id: msg_a4f9b5cc30d8
                      file_ids: []
                running_assistant:
                  summary: Aggregated assistant message (still streaming)
                  value:
                    id: msg_running01abcd
                    object: message
                    task_id: sess_2719df714819
                    created: 1779131500
                    role: assistant
                    status: streaming
                    content:
                      - type: text
                        text: Looking up ClinVar records for rs80357065…
                      - type: tool_use
                        id: toolu_01ABCD
                        name: execute_python
                        input:
                          code: import requests; …
                    metadata: {}
                    platform: api
      security:
        - bearerAuth: []
components:
  schemas:
    Message:
      properties:
        id:
          type: string
          title: Id
        object:
          type: string
          const: message
          title: Object
          default: message
        task_id:
          type: string
          title: Task Id
        created:
          type: integer
          title: Created
        role:
          type: string
          enum:
            - user
            - assistant
            - system
          title: Role
        content:
          items:
            additionalProperties: true
            type: object
          type: array
          title: Content
        finish_reason:
          anyOf:
            - type: string
            - type: 'null'
          title: Finish Reason
        status:
          anyOf:
            - type: string
              enum:
                - pending
                - streaming
                - completed
                - cancelling
                - cancelled
                - failed
            - type: 'null'
          title: Status
        stop_reason:
          anyOf:
            - type: string
              enum:
                - stop
                - length
                - cancelled
                - error
            - type: 'null'
          title: Stop Reason
        started_at:
          anyOf:
            - type: integer
            - type: 'null'
          title: Started At
        completed_at:
          anyOf:
            - type: integer
            - type: 'null'
          title: Completed At
        error:
          anyOf:
            - type: string
            - type: 'null'
          title: Error
        metadata:
          additionalProperties: true
          type: object
          title: Metadata
        platform:
          type: string
          enum:
            - api
            - mcp
            - web
            - desktop
            - mobile
          title: Platform
          default: api
        input:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Input
        output:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Output
        _links:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Links
      type: object
      required:
        - id
        - task_id
        - created
        - role
        - content
      title: Message
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Requires an API key. See the Authentication guide.

````