> ## 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 all orders

> Returns a list of all the orders



## OpenAPI

````yaml get /consumers/{consumer_id}/commerce/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}/commerce/orders:
    get:
      tags:
        - eCommerce
        - Orders
      summary: Get all orders
      description: Returns a list of all the orders
      operationId: ecommerce_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: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            title: Date From
          description: Filter orders created at or after this date (e.g. 2023-01-31)
        - name: date_to
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            title: Date To
          description: Filter orders created at or before this date (e.g. 2023-01-31)
        - name: updated_after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Updated After
          description: >-
            Filter orders last updated at or after this date (e.g.
            2023-01-31T15:00:00 for 31 of January 2023 at 3PM UTC). UTC is the
            only format that is supported on all connectors.
        - name: include_detailed_refunds
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/BoolParam'
              - type: 'null'
            default: 'false'
            title: Include Detailed Refunds
          description: Include detailed information concerning refunds
        - name: include_product_categories
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/BoolParam'
              - type: 'null'
            default: 'false'
            title: Include Product Categories
          description: Include detailed information about categories
        - name: include_customer_details
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/BoolParam'
              - type: 'null'
            default: 'true'
            title: Include Customer Details
          description: Include detailed information about customer
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ChiftPage_OrderItemOut_'
        '400':
          content:
            application/json:
              examples:
                Invalid date_from:
                  value:
                    message: >-
                      The date format of the field 'Date From' is not valid. The
                      expected format is the following: YYYY-MM-DD.
                    status: error
                Invalid date_to:
                  value:
                    message: >-
                      The date format of the field 'Date To' is not valid. The
                      expected format is the following: YYYY-MM-DD.
                    status: error
              schema:
                $ref: '#/components/schemas/ChiftError'
          description: Bad Request
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - mcp_auth:
            - commerce
            - commerce.read
            - commerce.orders
            - commerce.orders.read
components:
  schemas:
    BoolParam:
      type: string
      enum:
        - 'true'
        - 'false'
      title: BoolParam
    ChiftPage_OrderItemOut_:
      properties:
        items:
          items:
            $ref: '#/components/schemas/OrderItemOut'
          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[OrderItemOut]
    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'
    OrderItemOut:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        order_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Order Number
        customer:
          anyOf:
            - $ref: '#/components/schemas/OrderCustomerItemOut'
            - type: 'null'
        billing_address:
          anyOf:
            - $ref: '#/components/schemas/CommerceAddressItemOut'
            - type: 'null'
        shipping_address:
          anyOf:
            - $ref: '#/components/schemas/CommerceAddressItemOut'
            - type: 'null'
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        last_updated_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Updated On
        confirmed_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Confirmed On
        delivery_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Delivery Date
        cancelled_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Cancelled On
        status:
          $ref: '#/components/schemas/OrderStatus'
        fulfillment:
          anyOf:
            - $ref: '#/components/schemas/EcommerceFulfillmentObject'
            - type: 'null'
        discount_amount:
          type: number
          title: Discount Amount
        untaxed_amount_without_fees:
          type: number
          title: Untaxed Amount Without Fees
          description: >-
            Untaxed amount without fees (e.g. shipping) but with discout.
            Refunds and returns are not included.
        tax_amount_without_fees:
          type: number
          title: Tax Amount Without Fees
          description: >-
            Total taxes applied to the order without taxes linked to fees (e.g.
            shipping).
        total_without_fees:
          type: number
          title: Total Without Fees
          description: >-
            Total of the order without fees (e.g. shipping) but with discount.
            Refunds and returns are not included.
        current_untaxed_amount:
          type: number
          title: Current Untaxed Amount
          description: >-
            Untaxed amount with discout and any kind of fee (e.g. shipping).
            After returns, removes and returns.
        current_tax_amount:
          type: number
          title: Current Tax Amount
          description: >-
            Total taxes applied to the order. After returns, removes and
            returns.
        current_total:
          type: number
          title: Current Total
          description: >-
            Current total of the order with discount. After returns, removes and
            returns.
        untaxed_amount:
          type: number
          title: Untaxed Amount
          description: >-
            Untaxed amount with discout and any kind of fee (e.g. shipping).
            Refunds and returns are not included.
        tax_amount:
          type: number
          title: Tax Amount
          description: >-
            Total taxes applied to the order. Refunds and returns are not
            included.
        total:
          type: number
          title: Total
          description: >-
            Total of the order with discount. Refunds and returns are not
            included.
        refunded_amount:
          anyOf:
            - type: number
            - type: 'null'
          title: Refunded Amount
          default: 0
        currency:
          type: string
          title: Currency
          description: Indicates the currency of the order (e.g. EUR).
        note:
          anyOf:
            - type: string
            - type: 'null'
          title: Note
        tags:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Tags
          default: []
        lines:
          items:
            $ref: '#/components/schemas/OrderLineItemOut'
          type: array
          title: Lines
        other_fees:
          anyOf:
            - items:
                $ref: '#/components/schemas/FeesItem'
              type: array
            - type: 'null'
          title: Other Fees
          default: []
        payment_method_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Payment Method Id
          description: Technical id of the payment method in the eCommerce
        transactions:
          anyOf:
            - items:
                $ref: '#/components/schemas/OrderTransactions'
              type: array
            - type: 'null'
          title: Transactions
          default: []
        payment_methods:
          anyOf:
            - items:
                $ref: '#/components/schemas/OrderPaymentMethods'
              type: array
            - type: 'null'
          title: Payment Methods
          default: []
        detailed_refunds:
          anyOf:
            - items:
                $ref: '#/components/schemas/OrderRefundItem'
              type: array
            - type: 'null'
          title: Detailed Refunds
        returns:
          anyOf:
            - items:
                $ref: '#/components/schemas/OrderReturnItem'
              type: array
            - type: 'null'
          title: Returns
          default: []
      type: object
      required:
        - id
        - source_ref
        - status
        - discount_amount
        - untaxed_amount_without_fees
        - tax_amount_without_fees
        - total_without_fees
        - current_untaxed_amount
        - current_tax_amount
        - current_total
        - untaxed_amount
        - tax_amount
        - total
        - currency
        - lines
      title: OrderItemOut
    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
    OrderCustomerItemOut:
      properties:
        first_name:
          anyOf:
            - type: string
            - type: 'null'
          title: First Name
        last_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Name
        phone:
          anyOf:
            - type: string
            - type: 'null'
          title: Phone
        internal_notes:
          anyOf:
            - type: string
            - type: 'null'
          title: Internal Notes
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
        id:
          type: string
          title: Id
          description: Technical id of the customer in Chift
      type: object
      required:
        - id
      title: OrderCustomerItemOut
    CommerceAddressItemOut:
      properties:
        address_type:
          $ref: '#/components/schemas/AddressType'
        company_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Company Name
        first_name:
          anyOf:
            - type: string
            - type: 'null'
          title: First Name
        last_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Name
        street:
          anyOf:
            - type: string
            - type: 'null'
          title: Street
        number:
          anyOf:
            - type: string
            - type: 'null'
          title: Number
        box:
          anyOf:
            - type: string
            - type: 'null'
          title: Box
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
        postal_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Postal Code
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: 'Format: ISO 3166-1 codes.'
        phone:
          anyOf:
            - type: string
            - type: 'null'
          title: Phone
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
        vat:
          anyOf:
            - type: string
            - type: 'null'
          title: Vat
      type: object
      required:
        - address_type
      title: CommerceAddressItemOut
    OrderStatus:
      type: string
      enum:
        - cancelled_unpaid
        - cancelled
        - draft
        - confirmed
        - shipped
        - refunded
      title: OrderStatus
    EcommerceFulfillmentObject:
      properties:
        fulfillment_type:
          $ref: '#/components/schemas/EcommerceFulfillmentType'
        shipping_from_address:
          anyOf:
            - $ref: '#/components/schemas/AddressItemOut'
            - type: 'null'
      type: object
      required:
        - fulfillment_type
      title: EcommerceFulfillmentObject
    OrderLineItemOut:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        variant:
          anyOf:
            - $ref: '#/components/schemas/OrderLineProductVariantItem'
            - type: 'null'
          description: Product variant
        quantity:
          type: integer
          title: Quantity
        current_quantity:
          type: integer
          title: Current Quantity
          description: Quantity without refunds and returns.
        unit_price:
          type: number
          title: Unit Price
          description: Unit price of the product without taxes.
        description:
          type: string
          title: Description
        tax_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Id
          description: Technical id of the tax rate in Chift
        tax_rate:
          type: number
          title: Tax Rate
          description: Indicates the tax rate used for the line (e.g. 21.0).
        untaxed_amount:
          type: number
          title: Untaxed Amount
          description: Untaxed amount of the order line with discount.
        tax_amount:
          type: number
          title: Tax Amount
          description: Total taxes applied to the order line.
        total:
          type: number
          title: Total
          description: Total of the order line with discount.
        discounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/CommerceDiscountItem'
              type: array
            - type: 'null'
          title: Discounts
          default: []
        gift_card:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Gift Card
          default: false
        is_gift:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Gift
          default: false
      type: object
      required:
        - id
        - source_ref
        - quantity
        - current_quantity
        - unit_price
        - description
        - tax_rate
        - untaxed_amount
        - tax_amount
        - total
      title: OrderLineItemOut
    FeesItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        type:
          $ref: '#/components/schemas/FeesType'
        removed:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Removed
          description: Indicates if the fee has been removed from the order
          default: false
        tax_rate:
          type: number
          title: Tax Rate
        tax_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Id
          description: Technical id of the tax rate in Chift
        discounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/CommerceDiscountItem'
              type: array
            - type: 'null'
          title: Discounts
          default: []
        untaxed_amount:
          type: number
          title: Untaxed Amount
        tax_amount:
          type: number
          title: Tax Amount
        total:
          type: number
          title: Total
      type: object
      required:
        - id
        - source_ref
        - type
        - tax_rate
        - untaxed_amount
        - tax_amount
        - total
      title: FeesItem
    OrderTransactions:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the transaction in the eCommerce
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        payment_method_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Payment Method Id
          description: Technical id of the payment method in the eCommerce
        payment_method_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Payment Method Name
          description: Name of the payment method
        amount:
          type: number
          title: Amount
        status:
          $ref: '#/components/schemas/CommerceTransactionStatus'
      type: object
      required:
        - id
        - amount
        - status
      title: OrderTransactions
    OrderPaymentMethods:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the payment method in the eCommerce
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Name of the payment method
      type: object
      required:
        - id
      title: OrderPaymentMethods
    OrderRefundItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        total:
          type: number
          title: Total
        reason:
          anyOf:
            - type: string
            - type: 'null'
          title: Reason
        order_lines:
          anyOf:
            - items:
                $ref: '#/components/schemas/RefundOrderLineItem'
              type: array
            - type: 'null'
          title: Order Lines
          default: []
        other:
          anyOf:
            - type: number
            - type: 'null'
          title: Other
          default: 0
        shipping_refunds:
          anyOf:
            - items:
                $ref: '#/components/schemas/ShippingRefund'
              type: array
            - type: 'null'
          title: Shipping Refunds
          default: []
        other_fees:
          anyOf:
            - items:
                $ref: '#/components/schemas/RefundFeesItem'
              type: array
            - type: 'null'
          title: Other Fees
          default: []
        transactions:
          anyOf:
            - items:
                $ref: '#/components/schemas/OrderTransactions'
              type: array
            - type: 'null'
          title: Transactions
          default: []
      type: object
      required:
        - id
        - source_ref
        - total
      title: OrderRefundItem
    OrderReturnItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the return in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        order_lines:
          anyOf:
            - items:
                $ref: '#/components/schemas/ReturnOrderLineItem'
              type: array
            - type: 'null'
          title: Order Lines
          default: []
        new_lines:
          anyOf:
            - items:
                $ref: '#/components/schemas/ReturnOrderLineItem'
              type: array
            - type: 'null'
          title: New Lines
          default: []
        linked_fees:
          anyOf:
            - items:
                $ref: '#/components/schemas/ReturnFeesItem'
              type: array
            - type: 'null'
          title: Linked Fees
          default: []
      type: object
      required:
        - id
        - source_ref
      title: OrderReturnItem
    AddressType:
      type: string
      enum:
        - main
        - delivery
        - invoice
      title: AddressType
    EcommerceFulfillmentType:
      type: string
      enum:
        - FBA
        - FBM
      title: EcommerceFulfillmentType
    AddressItemOut:
      properties:
        address_type:
          $ref: '#/components/schemas/AddressType'
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
        number:
          anyOf:
            - type: string
            - type: 'null'
          title: Number
        box:
          anyOf:
            - type: string
            - type: 'null'
          title: Box
        phone:
          anyOf:
            - type: string
            - type: 'null'
          title: Phone
        mobile:
          anyOf:
            - type: string
            - type: 'null'
          title: Mobile
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
        street:
          anyOf:
            - type: string
            - type: 'null'
          title: Street
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
        postal_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Postal Code
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: 'Format: ISO 3166-1 codes.'
      type: object
      required:
        - address_type
      title: AddressItemOut
    OrderLineProductVariantItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the product variant in Chift
        sku:
          anyOf:
            - type: string
            - type: 'null'
          title: Sku
        name:
          type: string
          title: Name
        categories:
          anyOf:
            - items:
                $ref: '#/components/schemas/CommerceProductCategoryItem'
              type: array
            - type: 'null'
          title: Categories
          default: []
      type: object
      required:
        - id
        - name
      title: OrderLineProductVariantItem
    CommerceDiscountItem:
      properties:
        name:
          type: string
          title: Name
        description:
          type: string
          title: Description
        amount:
          type: number
          title: Amount
      type: object
      required:
        - name
        - description
        - amount
      title: CommerceDiscountItem
    FeesType:
      type: string
      enum:
        - shipping
        - other
      title: FeesType
    CommerceTransactionStatus:
      type: string
      enum:
        - failed
        - pending
        - success
      title: CommerceTransactionStatus
    RefundOrderLineItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the order line in Chift
        variant:
          anyOf:
            - $ref: '#/components/schemas/OrderLineProductVariantItem'
            - type: 'null'
          description: Product variant
        quantity:
          type: integer
          title: Quantity
        untaxed_amount:
          type: number
          title: Untaxed Amount
          description: Untaxed amount refunded (after discount).
        tax_amount:
          type: number
          title: Tax Amount
          description: Total taxes refunded (after discount).
        total:
          type: number
          title: Total
          description: Total refunded (after discount).
      type: object
      required:
        - id
        - quantity
        - untaxed_amount
        - tax_amount
        - total
      title: RefundOrderLineItem
    ShippingRefund:
      properties:
        id:
          type: string
          title: Id
          description: Technical id in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        untaxed_amount:
          type: number
          title: Untaxed Amount
          description: Untaxed amount refunded (after discount).
        tax_amount:
          type: number
          title: Tax Amount
          description: Total taxes refunded (after discount).
        total:
          type: number
          title: Total
          description: Total refunded (after discount).
      type: object
      required:
        - id
        - source_ref
        - untaxed_amount
        - tax_amount
        - total
      title: ShippingRefund
    RefundFeesItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the fee in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        type:
          $ref: '#/components/schemas/FeesType'
        untaxed_amount:
          type: number
          title: Untaxed Amount
        tax_amount:
          type: number
          title: Tax Amount
        total:
          type: number
          title: Total
      type: object
      required:
        - id
        - source_ref
        - type
        - untaxed_amount
        - tax_amount
        - total
      title: RefundFeesItem
    ReturnOrderLineItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the order line in Chift
        variant:
          anyOf:
            - $ref: '#/components/schemas/OrderLineProductVariantItem'
            - type: 'null'
          description: Product variant
        quantity:
          type: integer
          title: Quantity
        untaxed_amount:
          type: number
          title: Untaxed Amount
          description: Untaxed amount refunded (after discount).
        tax_amount:
          type: number
          title: Tax Amount
          description: Total taxes refunded (after discount).
        total:
          type: number
          title: Total
          description: Total refunded (after discount).
      type: object
      required:
        - id
        - quantity
        - untaxed_amount
        - tax_amount
        - total
      title: ReturnOrderLineItem
    ReturnFeesItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the fee in Chift
        source_ref:
          $ref: '#/components/schemas/Ref'
          description: Technical id in the target software
        type:
          $ref: '#/components/schemas/FeesType'
        untaxed_amount:
          type: number
          title: Untaxed Amount
        tax_amount:
          type: number
          title: Tax Amount
        total:
          type: number
          title: Total
      type: object
      required:
        - id
        - source_ref
        - type
        - untaxed_amount
        - tax_amount
        - total
      title: ReturnFeesItem
    CommerceProductCategoryItem:
      properties:
        id:
          type: string
          title: Id
          description: Technical id of the category in Chift
        name:
          type: string
          title: Name
      type: object
      required:
        - id
        - name
      title: CommerceProductCategoryItem
  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.

````