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

# Get an order by ID

> Return the order details for the given order ID.

<span className="badge-read">Key: Read</span><span className="badge-company">Scope: Company</span>


## OpenAPI

````yaml https://api.getprimo.com/openapi.json get /orders/{orderId}
openapi: 3.1.1
info:
  title: Public API - BETA
  description: Read docs on https://docs.getprimo.com/
  version: '1.0'
  contact: {}
servers:
  - url: https://api.getprimo.com
security:
  - apikey: []
tags: []
paths:
  /orders/{orderId}:
    get:
      tags:
        - Orders
      summary: Get an order by ID
      description: Return the order details for the given order ID.
      operationId: getOrder
      parameters:
        - name: orderId
          required: true
          in: path
          schema:
            type: string
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetOrder_Output'
components:
  schemas:
    GetOrder_Output:
      type: object
      properties:
        id:
          type: string
        reference:
          type: string
        status:
          type: string
          enum:
            - PLACED
            - CONFIRMED
            - SHIPPED
            - CLOSED
            - CANCELED
        employeeId:
          anyOf:
            - type: string
            - type: 'null'
        createdAt:
          type: string
          format: date-time
          pattern: >-
            ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
        onboardingDate:
          anyOf:
            - type: string
              format: date-time
              pattern: >-
                ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
            - type: 'null'
        priceNoVAT:
          description: Price excluding VAT, in the order currency
          type: number
        currency:
          anyOf:
            - type: string
              enum:
                - EUR
                - GBP
                - USD
                - CHF
                - CAD
            - type: 'null'
        cancelRequest:
          type: boolean
        products:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              name:
                type: string
              type:
                type: string
                enum:
                  - LAPTOP
                  - SMARTPHONE
                  - TABLET
                  - MONITOR
                  - KEYBOARD
                  - MOUSE
                  - MOUSEPAD
                  - WEBCAM
                  - HEADSET
                  - SPEAKER
                  - CABLE_ADAPTER
                  - HUB
                  - CHARGER
                  - STORAGE_DEVICE
                  - LAPTOP_CASE
                  - SHIPPING_MATERIAL
                  - ERGONOMIC
                  - WARRANTY
                  - OTHER
              supplierName:
                anyOf:
                  - type: string
                  - type: 'null'
            required:
              - id
              - name
              - type
            additionalProperties: false
        purchases:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              status:
                type: string
                enum:
                  - PENDING
                  - FULFILLED
                  - SHIPPED
                  - DELIVERED
                  - UNKNOWN
                  - PRE_TRANSIT
                  - IN_TRANSIT
                  - OUT_FOR_DELIVERY
                  - AVAILABLE_FOR_PICKUP
                  - RETURN_TO_SENDER
                  - FAILURE
                  - CANCELLED
                  - ERROR
              products:
                type: array
                items:
                  type: string
              trackingLink:
                anyOf:
                  - type: string
                  - type: 'null'
              estimatedDeliveryDate:
                anyOf:
                  - type: string
                    format: date-time
                    pattern: >-
                      ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                  - type: 'null'
            required:
              - id
              - status
              - products
            additionalProperties: false
      required:
        - id
        - reference
        - status
        - createdAt
        - priceNoVAT
        - cancelRequest
        - products
        - purchases
      additionalProperties: false
  securitySchemes:
    apikey:
      scheme: bearer
      bearerFormat: API key
      type: http
      description: >-
        Use your Primo API key in the Authorization header as `Bearer
        <API_KEY>`.

````