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

# Get Results Metadata

> Retrieve order result metadata via the Junction API. Requires authentication with your team API key.

<RequestExample>
  ```bash cURL theme={null}
  curl --request GET \
       --url '{{BASE_URL}}/v3/order/<order_id>/result/metadata' \
       --header 'accept: application/json' \
       --header 'x-vital-api-key: YOUR_API_KEY'
  ```

  ```python Python theme={null}
  from junction import Junction
  from junction.environment import JunctionEnvironment

  client = Junction(
      api_key="YOUR_API_KEY",
      environment=JunctionEnvironment.SANDBOX,
  )

  data = client.lab_tests.get_result_metadata("<order_id>")
  ```

  ```typescript TypeScript theme={null}
  import { JunctionClient, JunctionEnvironment } from "@junction-api/sdk";

  const client = new JunctionClient({
      apiKey: "YOUR_API_KEY",
      environment: JunctionEnvironment.Sandbox,
  });

  const data = await client.labTests.getResultMetadata({ orderId: "<order_id>" });
  ```

  ```java Java theme={null}
  import com.junction.api.Junction;
  import com.junction.api.core.Environment;

  Junction client = Junction.builder()
      .apiKey("YOUR_API_KEY")
      .environment(Environment.SANDBOX)
      .build();

  var data = client.labTests().getResultMetadata("<order_id>");
  ```

  ```go Go theme={null}
  import (
      "context"

      junction "github.com/junction-api/junction-go"
      "github.com/junction-api/junction-go/client"
      "github.com/junction-api/junction-go/option"
  )

  c := client.NewClient(
      option.WithApiKey("YOUR_API_KEY"),
      option.WithBaseURL(junction.Environments.Sandbox),
  )

  response, err := c.LabTests.GetResultMetadata(context.TODO(), &junction.GetResultMetadataLabTestsRequest{
      OrderId: "<order_id>",
  })
  if err != nil {
      return err
  }
  fmt.Printf("Received data %s\n", response)
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "age": 19,
    "dob": "18/08/1993",
    "clia_number": "12331231",
    "patient": "Bob Smith",
    "provider": "Dr. Jack Smith",
    "laboratory": "Quest Diagnostics",
    "date_reported": "2020-01-01",
    "date_collected": "2022-02-02",
    "specimen_number": "123131",
    "date_received": "2022-01-01",
    "status": "final",
    "interpretation": "normal"
  }
  ```
</ResponseExample>


## OpenAPI

````yaml GET /v3/order/{order_id}/result/metadata
openapi: 3.1.0
info:
  title: Junction API
  description: https://docs.junction.com/
  version: 0.4.483
servers:
  - url: https://api.us.junction.com
    x-fern-server-name: Production
  - url: https://api.eu.junction.com
    x-fern-server-name: ProductionEU
  - url: https://api.sandbox.us.junction.com
    x-fern-server-name: Sandbox
  - url: https://api.sandbox.eu.junction.com
    x-fern-server-name: SandboxEU
security:
  - apiKeyAuth: []
paths:
  /v3/order/{order_id}/result/metadata:
    get:
      tags:
        - order
      summary: Get Lab Test Result Metadata
      description: |-
        Return metadata related to order results, such as lab metadata,
        provider and sample dates.
      operationId: get_lab_test_result_metadata_v3_order__order_id__result_metadata_get
      parameters:
        - name: order_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Order Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LabResultsMetadata'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    LabResultsMetadata:
      properties:
        age:
          type: string
          title: Age
        dob:
          type: string
          title: Dob
        clia_#:
          anyOf:
            - type: string
            - type: 'null'
          title: 'Clia #'
        patient:
          type: string
          title: Patient
        provider:
          anyOf:
            - type: string
            - type: 'null'
          title: Provider
        laboratory:
          anyOf:
            - type: string
            - type: 'null'
          title: Laboratory
        date_reported:
          type: string
          title: Date Reported
          deprecated: true
        date_collected:
          anyOf:
            - type: string
            - type: 'null'
          title: Date Collected
          deprecated: true
        specimen_number:
          type: string
          title: Specimen Number
        date_received:
          anyOf:
            - type: string
            - type: 'null'
          title: Date Received
          deprecated: true
        status:
          type: string
          title: Status
          default: final
        interpretation:
          anyOf:
            - type: string
            - type: 'null'
          title: Interpretation
        patient_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Patient Id
        account_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Account Id
      type: object
      required:
        - age
        - dob
        - patient
        - date_reported
        - specimen_number
      title: LabResultsMetadata
      example:
        age: 19
        clia_number: '12331231'
        date_collected: '2022-02-02'
        date_received: '2022-01-01'
        date_reported: '2020-01-01'
        dob: 18/08/1993
        interpretation: normal
        laboratory: Quest Diagnostics
        patient: Bob Smith
        provider: Dr. Jack Smith
        specimen_number: '123131'
        status: final
    HTTPValidationError:
      properties:
        detail:
          title: Detail
      type: object
      title: HTTPValidationError
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-vital-api-key
      description: Vital Team API Key

````