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

# Get orders (PMS)

> Returns a list of the orders



## OpenAPI

````yaml get /consumers/{consumer_id}/pms/orders
openapi: 3.1.0
info:
  title: Chift API
  description: >-
    The Chift API is a universal API giving you access to financial data from
    the software of your clients. It helps software companies to offer native
    integrations to their clients without the effort needed to maintain those
    native integrations. By using the APIs (Accounting, POS, eCommerce) of
    Chift, you connect once and allow your clients to use their software
    packages.
  version: 1.0.0
servers:
  - url: https://api.chift.eu
    description: Chift
security:
  - bearerAuth: []
paths:
  /consumers/{consumer_id}/pms/orders:
    get:
      tags:
        - Property Management System
        - Orders
      summary: Get orders (PMS)
      description: Returns a list of the orders
      operationId: pms_get_orders
      parameters:
        - name: consumer_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Consumer Id
        - name: page
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            default: 1
            title: Page
          description: Page number
        - name: size
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            default: 50
            title: Size
          description: Page size
        - name: date_from
          in: query
          required: true
          schema:
            type: string
            format: date
            title: Date From
        - name: date_to
          in: query
          required: true
          schema:
            type: string
            format: date
            title: Date To
        - name: location_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Location Id
        - name: state
          in: query
          required: false
          schema:
            $ref: '#/components/schemas/PMSStates'
            default: consumed
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ChiftPage_PMSOrderItem_'
        '400':
          content:
            application/json:
              example:
                message: Error while trying to perform your request
                status: error
              schema:
                $ref: '#/components/schemas/ChiftError'
          description: Bad Request
        '405':
          content:
            application/json:
              example:
                message: >-
                  The resource {Method} - {Resource} is not supported by
                  {ConnectorName}
                status: error
              schema:
                $ref: '#/components/schemas/ChiftError'
          description: Method Not Allowed
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '502':
          content:
            application/json:
              example:
                message: Error while trying to authenticate to {ConnectorName}
                status: error
              schema:
                $ref: '#/components/schemas/ChiftError'
          description: Bad Gateway
      security:
        - mcp_auth:
            - pms
            - pms.read
            - pms.orders
            - pms.orders.read
components:
  schemas:
    PMSStates:
      type: string
      enum:
        - consumed
        - closed
      title: PMSStates
    ChiftPage_PMSOrderItem_:
      properties:
        items:
          items:
            $ref: '#/components/schemas/PMSOrderItem'
          type: array
          title: Items
        total:
          type: integer
          minimum: 0
          title: Total
        page:
          type: integer
          minimum: 1
          title: Page
        size:
          type: integer
          minimum: 1
          title: Size
      type: object
      required:
        - items
        - total
        - page
        - size
      title: ChiftPage[PMSOrderItem]
    ChiftError:
      properties:
        message:
          type: string
          title: Message
        status:
          anyOf:
            - type: string
            - type: 'null'
          title: Status
          default: error
        detail:
          anyOf:
            - type: string
            - type: 'null'
          title: Detail
          default: ''
      type: object
      required:
        - message
      title: ChiftError
    HTTPValidationError:
      title: Validation Error
      required:
        - message
      type: object
      properties:
        message:
          title: Message
          type: string
          default: Validation error
        status:
          title: Status
          type: string
          default: error
        detail:
          title: Detail
          type: array
          items:
            $ref: '#/components/schemas/ValidationError'
    PMSOrderItem:
      properties:
        id:
          type: string
          title: Id
          description: Unique identifier of the order
          examples:
            - '123'
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        order_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Order Number
          description: Order number (often unique reference during the day)
          examples:
            - '1'
        creation_date:
          type: string
          format: date-time
          title: Creation Date
          description: Creation date of the order
          examples:
            - '2025-01-01T00:00:00Z'
        closing_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Closing Date
          description: Closing date of the order
          examples:
            - '2025-01-01T00:00:00Z'
        service_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Service Date
          description: >-
            Indicates the date of the service to which the order belongs (can be
            used to group orders by closure date)
          examples:
            - '2025-01-01T00:00:00Z'
        device_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Device Id
          description: ID of device that created the order
          examples:
            - device-123
        total:
          type: number
          title: Total
          description: Total amount including tax of the order
          examples:
            - 11
        tax_amount:
          type: number
          title: Tax Amount
          description: Total amount of the taxes of the order
          examples:
            - 1
        total_discount:
          anyOf:
            - type: number
            - type: 'null'
          title: Total Discount
          description: Total amount of the discounts of the order
          default: '0'
          examples:
            - 10
        total_refund:
          anyOf:
            - type: number
            - type: 'null'
          title: Total Refund
          description: Total amount of the refunds of the order
          default: '0'
          examples:
            - 5
        total_tip:
          anyOf:
            - type: number
            - type: 'null'
          title: Total Tip
          description: >-
            Total amount of the tips of the order. Tips are not part of the
            total of the order
          default: '0'
          examples:
            - 1
        delivery_fee:
          anyOf:
            - type: number
            - type: 'null'
          title: Delivery Fee
          description: Total amount of the delivery fees of the order
          default: '0'
          examples:
            - 1
        mode:
          anyOf:
            - $ref: '#/components/schemas/Mode'
            - type: 'null'
          description: Delivery Mode
          default: UNKNOWN
          examples:
            - eat_in
        source:
          anyOf:
            - $ref: '#/components/schemas/Source'
            - type: 'null'
          description: Source of the order
          default: UNKNOWN
          examples:
            - web
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
          description: Currency of the order
          examples:
            - EUR
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: 'Country of the order, format: ISO 3166-1 codes.'
          examples:
            - FR
        loyalty:
          anyOf:
            - type: integer
            - type: 'null'
          title: Loyalty
          description: Loyalty points of the order
          examples:
            - 100
        customer_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Customer Id
          description: Unique identifier of the customer
          examples:
            - customer-123
        location_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Location Id
          description: Unique identifier of the location
          examples:
            - location-123
        taxes:
          anyOf:
            - items:
                $ref: '#/components/schemas/TotalTaxItem'
              type: array
            - type: 'null'
          title: Taxes
          description: List of taxes of the order
          default: []
        guests:
          anyOf:
            - type: integer
            - type: 'null'
          title: Guests
          description: Number of guests linked to the order
          examples:
            - 1
        items:
          items:
            $ref: '#/components/schemas/PMSOrderLineItem'
          type: array
          title: Items
          description: List of items related to the order
        service_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Service Id
          description: Reference to the service related to this order
        reservation:
          anyOf:
            - $ref: '#/components/schemas/ReservationItem'
            - type: 'null'
          description: Reference to the reservation related to this order
        bills:
          anyOf:
            - items:
                $ref: '#/components/schemas/InvoiceItem'
              type: array
            - type: 'null'
          title: Bills
          description: Reference to the bills related to this order
      type: object
      required:
        - id
        - source_ref
        - creation_date
        - total
        - tax_amount
        - items
      title: PMSOrderItem
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    Ref:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: Technical id in the target software
        model:
          anyOf:
            - type: string
            - type: 'null'
          title: Model
          description: Name of the model/entity in the target software
      type: object
      title: Ref
    Mode:
      type: string
      enum:
        - EAT_IN
        - TAKEAWAY
        - DELIVERY
        - UNKNOWN
      title: Mode
    Source:
      type: string
      enum:
        - WEB
        - MOBILE
        - KIOSK
        - POS
        - REMOTE_POS
        - JUSTEAT
        - FOODORA
        - UBEREATS
        - GLOVO
        - DELIVEROO
        - SMILEIN
        - UNKNOWN
      title: Source
    TotalTaxItem:
      properties:
        tax_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Id
          description: Unique identifier of the tax
          examples:
            - 371ca583-d218-4900-b236-397532cf0e39
        tax_rate:
          type: number
          title: Tax Rate
          description: Tax rate
          examples:
            - '10'
        tax_amount:
          type: number
          title: Tax Amount
          description: Tax amount
          examples:
            - '1'
        total:
          type: number
          title: Total
          description: Total amount including tax
          examples:
            - '11'
      type: object
      required:
        - tax_rate
        - tax_amount
        - total
      title: TotalTaxItem
    PMSOrderLineItem:
      properties:
        id:
          type: string
          title: Id
          description: Unique identifier of the order line item
          examples:
            - '123'
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        type:
          anyOf:
            - $ref: '#/components/schemas/POSLineItemType'
            - type: 'null'
          description: Type of the order line item
          examples:
            - product
        menu_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Menu Id
          description: Unique identifier of the menu
          examples:
            - '456'
        quantity:
          type: number
          title: Quantity
          description: Quantity of the order line item
          examples:
            - 1
        unit_price:
          type: number
          title: Unit Price
          description: Unit price (without tax) of the order line item
          examples:
            - 10
        total:
          type: number
          title: Total
          description: Total amount including tax of the order line item
          examples:
            - 11
        tax_amount:
          type: number
          title: Tax Amount
          description: Total amount of the taxes of the order line item
          examples:
            - 1
        tax_rate:
          anyOf:
            - type: number
            - type: 'null'
          title: Tax Rate
          description: Tax rate of the order line item
          examples:
            - 10
        tax_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Id
          description: Unique identifier of the tax of the order line item
          examples:
            - 371ca583-d218-4900-b236-397532cf0e39
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Description of the order line item
          examples:
            - Pizza
        discounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/DiscountItem'
              type: array
            - type: 'null'
          title: Discounts
          description: >-
            List of discounts of the order line item. Discounts of items are
            always part of the total discount of the order
          default: []
          examples:
            - []
        product_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Product Id
          description: Reference to the product related to this item
          examples:
            - '789'
        accounting_category_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Accounting Category Id
          description: >-
            Sometimes used by a POS to give a specific accounting category to an
            order item
          examples:
            - '123'
      type: object
      required:
        - id
        - source_ref
        - quantity
        - unit_price
        - total
        - tax_amount
      title: PMSOrderLineItem
    ReservationItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        start_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Start Date
          description: Start date of the reservation
          examples:
            - '2024-10-01T12:00:00'
        end_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: End Date
          description: End date of the reservation
          examples:
            - '2024-10-10T12:00:00'
        creation_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Creation Date
          description: Creation date of the reservation
          examples:
            - '2024-09-25T12:00:00'
        resource_id:
          anyOf:
            - $ref: '#/components/schemas/ChiftId'
            - type: 'null'
          description: Unique reference to the resource related to the reservation
        resource_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Resource Name
          description: Name of the resource related to the reservation
          examples:
            - Room 101
        resource_identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Resource Identifier
          description: Identifier of the resource related to the reservation
          examples:
            - R101
      type: object
      required:
        - id
        - source_ref
      title: ReservationItem
    InvoiceItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        invoice_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Invoice Number
          description: Number/sequence
          examples:
            - INV-12345
        creation_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Creation Date
          description: Creation date of the invoice
          examples:
            - '2023-10-01T12:00:00'
        closing_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Closing Date
          description: Closing date of the invoice
          examples:
            - '2023-10-10T12:00:00'
        partners:
          anyOf:
            - items:
                $ref: '#/components/schemas/InvoicePartnerItem'
              type: array
            - type: 'null'
          title: Partners
          description: List of partners related to the invoice
      type: object
      required:
        - id
        - source_ref
        - invoice_number
      title: InvoiceItem
    POSLineItemType:
      type: string
      enum:
        - menu
        - product
        - service
        - general_discount
      title: POSLineItemType
    DiscountItem:
      properties:
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Name of the discount
          examples:
            - Percentage discount
        total:
          type: number
          title: Total
          description: Total amount of the discount
          examples:
            - 10
        type:
          $ref: '#/components/schemas/DiscountType'
          description: Type of the discount
          default: UNKNOWN
          examples:
            - offered
      type: object
      required:
        - total
      title: DiscountItem
    ChiftId:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
      type: object
      required:
        - id
        - source_ref
      title: ChiftId
    InvoicePartnerItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        type:
          $ref: '#/components/schemas/PartnerType-Output'
          description: Type of the partner
          examples:
            - account
        address:
          anyOf:
            - $ref: '#/components/schemas/AddressItem'
            - type: 'null'
          description: Address of the partner
        first_name:
          anyOf:
            - type: string
            - type: 'null'
          title: First Name
          description: First name of the partner. In case the partner is an individual.
          examples:
            - John
        last_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Name
          description: Last name of the partner. In case the partner is an individual.
          examples:
            - Doe
        company_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Company Name
          description: Company name of the partner. In case the partner is a company.
          examples:
            - Acme Corp
      type: object
      required:
        - id
        - source_ref
        - type
      title: InvoicePartnerItem
    DiscountType:
      type: string
      enum:
        - OFFERED
        - UNKNOWN
        - LOSS
      title: DiscountType
    PartnerType-Output:
      type: string
      enum:
        - owner
        - account
      title: PartnerType
    AddressItem:
      properties:
        address_type:
          anyOf:
            - type: string
            - type: 'null'
          title: Address Type
          description: Type of the address
          examples:
            - home
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Name given to the address (e.g. 'home')
          examples:
            - Home
        street:
          anyOf:
            - type: string
            - type: 'null'
          title: Street
          description: Street name
          examples:
            - Main Street
        number:
          anyOf:
            - type: string
            - type: 'null'
          title: Number
          description: Number of the address
          examples:
            - '123'
        box:
          anyOf:
            - type: string
            - type: 'null'
          title: Box
          description: Box of the address
          examples:
            - A
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
          description: City name
          examples:
            - Paris
        postal_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Postal Code
          description: Postal code of the address
          examples:
            - '75000'
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: 'Country, format: ISO 3166-1 codes.'
          examples:
            - FR
      type: object
      title: AddressItem
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        This access token needs to be included in each of your request to the
        Chift API.

````