# Get offers

`POST /v1/products/offers`

Returns who sells each product and at what price, for the rows of a New order page. This is the one batch
endpoint in the API. Call it for the visible rows and the selected rows, in chunks of 500.

It skips suppliers that cannot ship to the address, and uses the company's delivery address when you send none.
When you name a `supplierId`, that supplier comes back with `canShipToAddress: false` instead of being skipped. A
supplier that is `archived_by_supplier` or `blocked` still comes back, flagged by `status`, so your page can show
why. It is never `recommended`.

Each product's `offers` are sorted best first: in stock first, then suppliers the company is connected to, then
by rating. Only `prequalified` and `verified` companies can call it.


```yaml
requestBody:
  required: true
  content:
    application/json:
      schema:
        type: object
        required:
          - productIds
        properties:
          productIds:
            type: array
            minItems: 1
            maxItems: 500
            items:
              type: string
          supplierId:
            type: string
            description: Return only the offers of this supplier.
          deliveryAddress:
            type: object
            required:
              - line1
              - city
              - state
              - postalCode
              - country
            properties:
              line1:
                type: string
                description: Street address.
              line2:
                type: string
                description: Suite, unit, or floor.
              city:
                type: string
              state:
                type: string
                pattern: ^[A-Z]{2}$
                description: A two-letter US state code.
                examples:
                  - CO
              postalCode:
                type: string
                description: ZIP code.
              country:
                type: string
                const: US
              phone:
                type: string
                description: Phone number for the delivery. Required on the company. Optional on
                  an order, which then uses the company's phone.
      examples:
        One product:
          value:
            productIds:
              - prod-4Fz9QbX2kL
responses:
  "200":
    description: The offers per product, and the suppliers they refer to.
    content:
      application/json:
        schema:
          type: object
          required:
            - products
            - suppliers
            - currency
          properties:
            products:
              type: array
              items:
                type: object
                required:
                  - productId
                  - hazardousMaterials
                  - type
                  - offers
                properties:
                  productId:
                    type: string
                    examples:
                      - prod-4Fz9QbX2kL
                  hazardousMaterials:
                    type: boolean
                  type:
                    type: string
                    enum:
                      - professional
                      - retail
                  offers:
                    type: array
                    description: The offers, best first.
                    items:
                      type: object
                      required:
                        - supplierId
                        - unitPrice
                        - available
                        - status
                        - plannedAvailability
                        - discountLevels
                        - recommended
                      properties:
                        supplierId:
                          type: string
                          examples:
                            - sup-1Ry6tUi3Op
                        unitPrice:
                          type: number
                          description: An amount in dollars, with up to two decimal places.
                        available:
                          type: integer
                          description: How many units can be ordered now.
                        status:
                          type: string
                          enum:
                            - published
                            - unavailable
                            - discontinued
                        plannedAvailability:
                          type:
                            - string
                            - "null"
                          format: date
                          description: The date the product is back in stock, or `null`.
                        discountLevels:
                          type: array
                          items:
                            type: object
                            required:
                              - minQuantity
                              - discountPercent
                              - discountAmount
                              - name
                              - endsAt
                            properties:
                              minQuantity:
                                type: integer
                                description: The quantity from which this discount applies.
                              discountPercent:
                                type: number
                                description: The discount in percent, or `0` when `discountAmount` applies.
                              discountAmount:
                                type: number
                                description: An amount in dollars, with up to two decimal places.
                              name:
                                type:
                                  - string
                                  - "null"
                                description: The name of the discount, or `null`.
                              endsAt:
                                type:
                                  - string
                                  - "null"
                                format: date
                                description: The date the discount ends, or `null`.
                        recommended:
                          type: boolean
                          description: "`true` on the first offer."
            suppliers:
              type: array
              description: The suppliers the offers refer to.
              items:
                type: object
                required:
                  - id
                  - name
                  - logo
                  - rating
                  - status
                  - maxQuantityPerOrder
                  - freeShippingThreshold
                  - shippingFee
                  - shippingType
                  - orderDiscountLevels
                  - canShipToAddress
                properties:
                  id:
                    type: string
                    examples:
                      - sup-1Ry6tUi3Op
                  name:
                    type: string
                    examples:
                      - Amberlin
                  logo:
                    type:
                      - string
                      - "null"
                    format: uri
                  rating:
                    type:
                      - integer
                      - "null"
                    minimum: 0
                    maximum: 100
                  status:
                    type: string
                    description: >
                      `active`: the salon location can order from the supplier.
                      `archived_by_client`: the salon archived the supplier.

                      `archived_by_supplier`: the supplier archived the salon
                      location, and the salon cannot order from it any more.

                      `blocked`: Beauty Router blocked the supplier.
                    enum:
                      - active
                      - archived_by_client
                      - archived_by_supplier
                      - blocked
                  maxQuantityPerOrder:
                    type: integer
                    minimum: 1
                    description: The most units of one product in one order.
                  freeShippingThreshold:
                    type:
                      - number
                      - "null"
                    description: Orders at or above this amount ship free. `null` when the supplier
                      has no free shipping.
                  shippingFee:
                    type:
                      - number
                      - "null"
                    description: The flat shipping charge. `null` when `shippingType` is `carrier`.
                  shippingType:
                    type: string
                    enum:
                      - flat
                      - carrier
                    description: "`flat` for a flat amount, `carrier` for a carrier quote."
                  orderDiscountLevels:
                    type: array
                    description: Discounts on the whole order.
                    items:
                      type: object
                      required:
                        - minAmount
                        - discountPercent
                        - discountAmount
                        - name
                        - endsAt
                      properties:
                        minAmount:
                          type: number
                          description: An amount in dollars, with up to two decimal places.
                        discountPercent:
                          type: number
                          description: The discount in percent, or `0` when `discountAmount` applies.
                        discountAmount:
                          type: number
                          description: An amount in dollars, with up to two decimal places.
                        name:
                          type:
                            - string
                            - "null"
                          description: The name of the discount, or `null`.
                        endsAt:
                          type:
                            - string
                            - "null"
                          format: date
                          description: The date the discount ends, or `null`.
                  canShipToAddress:
                    type: boolean
                    description: Whether the supplier ships to the address. It can be `false` only
                      for a supplier you named.
            currency:
              type: string
              const: usd
              description: Always `usd`.
        examples:
          One product:
            value:
              products:
                - productId: prod-4Fz9QbX2kL
                  hazardousMaterials: false
                  type: professional
                  offers:
                    - supplierId: sup-1Ry6tUi3Op
                      unitPrice: 24.5
                      available: 120
                      status: published
                      plannedAvailability: null
                      discountLevels:
                        - minQuantity: 12
                          discountPercent: 10
                          discountAmount: 0
                          name: Salon Stock-Up
                          endsAt: 2026-12-31
                      recommended: true
              suppliers:
                - id: sup-1Ry6tUi3Op
                  name: Amberlin
                  logo: https://images.beautyrouter.com/sup-1Ry6tUi3Op/logo.png
                  rating: 94
                  status: active
                  maxQuantityPerOrder: 48
                  freeShippingThreshold: 150
                  shippingFee: 12
                  shippingType: flat
                  orderDiscountLevels:
                    - minAmount: 500
                      discountPercent: 5
                      discountAmount: 0
                      name: Holiday Order Bonus
                      endsAt: 2026-12-31
                  canShipToAddress: true
              currency: usd
  "400":
    description: "`validation_failed`: a field is missing or has a wrong value.
      `field` names it."
    content:
      application/json:
        schema:
          type: object
          description: The body of every error response.
          required:
            - error
          properties:
            error:
              type: object
              required:
                - code
                - message
              properties:
                code:
                  type: string
                  description: A stable error code.
                  enum:
                    - invalid_app_token
                    - invalid_user_token
                    - user_token_expired
                    - origin_not_allowed
                    - ip_not_allowed
                    - user_cannot_manage_company
                    - user_cannot_order
                    - company_blocked
                    - company_not_verified
                    - app_setup_incomplete
                    - not_found
                    - validation_failed
                    - email_invalid_format
                    - email_domain_not_found
                    - email_mailbox_not_found
                    - address_state_without_license
                    - hazmat_destination
                    - ship_to_restricted
                    - verification_data_missing
                    - document_locked
                    - document_already_uploaded
                    - file_too_large
                    - file_type_not_supported
                    - reply_not_expected
                    - order_action_not_allowed
                    - supplier_refused_cancel
                    - order_total_changed
                    - order_has_problems
                    - idempotency_key_reused
                    - idempotency_key_in_use
                    - rate_limit_exceeded
                    - internal_error
                message:
                  type: string
                  description: A sentence for developers. It can change, so do not match on it.
                field:
                  type: string
                  description: The request field that caused the error. Only some errors have it.
                missing:
                  type: array
                  items:
                    type: string
                  description: Only on `verification_data_missing` and `app_setup_incomplete`.
                    What still needs to be set.
                quote:
                  type: object
                  required:
                    - groups
                    - unresolvedLines
                    - companyProblems
                    - total
                    - currency
                  properties:
                    groups:
                      type: array
                      description: One group per supplier. Each group becomes one order.
                      items:
                        type: object
                        required:
                          - supplierId
                          - lines
                          - productsTotal
                          - orderDiscount
                          - shipping
                          - freeShippingRemaining
                          - salesTax
                          - taxExemption
                          - total
                          - chargeTiming
                          - problems
                        properties:
                          supplierId:
                            type: string
                            examples:
                              - sup-1Ry6tUi3Op
                          lines:
                            type: array
                            items:
                              type: object
                              required:
                                - productId
                                - quantity
                                - unitPrice
                                - discount
                                - total
                              properties:
                                productId:
                                  type: string
                                quantity:
                                  type: integer
                                unitPrice:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                discount:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                total:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                          productsTotal:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          orderDiscount:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          shipping:
                            type: object
                            required:
                              - amount
                              - kind
                            properties:
                              amount:
                                type:
                                  - number
                                  - "null"
                                description: The shipping charge in US dollars, or `null` when it cannot be
                                  worked out.
                              kind:
                                type: string
                                enum:
                                  - free
                                  - flat
                                  - carrier
                          freeShippingRemaining:
                            type:
                              - number
                              - "null"
                            description: How much more to order for free shipping, or `null` when it does
                              not apply.
                          salesTax:
                            type:
                              - number
                              - "null"
                            description: The sales tax in US dollars, or `null` when it cannot be worked
                              out.
                          taxExemption:
                            type: object
                            required:
                              - certificateId
                              - notAppliedReason
                            properties:
                              certificateId:
                                type:
                                  - string
                                  - "null"
                                description: The exemption certificate used, or `null`.
                              notAppliedReason:
                                type:
                                  - string
                                  - "null"
                                enum:
                                  - no_certificate
                                  - other_state
                                  - not_reviewed
                                  - null
                                description: Why no certificate applies, or `null` when one does.
                          total:
                            type:
                              - number
                              - "null"
                            description: >
                              The amount the salon pays for this group in US
                              dollars, or `null` when it cannot be worked out.
                              Send it back as

                              `expectedTotal`. A group with problems has no
                              `expectedTotal`.
                          chargeTiming:
                            type: string
                            enum:
                              - now
                              - after_verification
                            description: >
                              `now`: Beauty Router charges the card when the
                              order is created. `after_verification`: the
                              company is

                              `prequalified`, so the charge waits until its
                              verification ends.
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    unresolvedLines:
                      type: array
                      description: The lines no supplier can take.
                      items:
                        type: object
                        required:
                          - productId
                          - quantity
                          - problems
                        properties:
                          productId:
                            type: string
                          quantity:
                            type: integer
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    companyProblems:
                      type: array
                      description: What stops every group.
                      items:
                        type: object
                        required:
                          - code
                          - message
                        properties:
                          code:
                            type: string
                            description: What stops a group or the whole request. See
                              [Problems](/create-orders/#problems).
                            enum:
                              - buying_suspended
                              - supplier_unavailable
                              - address_state_without_license
                              - ship_to_restricted
                              - hazmat_destination
                              - address_not_deliverable
                              - connection_required
                              - connection_blocked
                              - insufficient_stock
                              - product_unavailable
                              - shipping_unavailable
                              - tax_unavailable
                              - delivery_address_required
                              - delivery_phone_required
                              - payment_card_required
                              - payment_card_unusable
                              - quantity_limit_exceeded
                              - order_limit_exceeded
                              - order_below_minimum
                          message:
                            type: string
                            description: A sentence you can show. It can change, so do not match on it.
                          productId:
                            type: string
                            description: The product. Only on problems with one product.
                          supplierId:
                            type: string
                            description: The supplier. Only on problems with one supplier.
                          available:
                            type: integer
                            description: How many units can be ordered. Only on `insufficient_stock`.
                    total:
                      type:
                        - number
                        - "null"
                      description: The sum of all the groups in US dollars, or `null` when a group's
                        total is.
                    currency:
                      type: string
                      const: usd
                      description: Always `usd`.
        examples:
          validation_failed:
            value:
              error:
                code: validation_failed
                message: ein must have 9 digits.
                field: ein
  "401":
    description: >
      `invalid_user_token`: the user token is missing or wrong.
      `user_token_expired`: the user token expired. Log the

      user in again with `POST /v1/login`.
    content:
      application/json:
        schema:
          type: object
          description: The body of every error response.
          required:
            - error
          properties:
            error:
              type: object
              required:
                - code
                - message
              properties:
                code:
                  type: string
                  description: A stable error code.
                  enum:
                    - invalid_app_token
                    - invalid_user_token
                    - user_token_expired
                    - origin_not_allowed
                    - ip_not_allowed
                    - user_cannot_manage_company
                    - user_cannot_order
                    - company_blocked
                    - company_not_verified
                    - app_setup_incomplete
                    - not_found
                    - validation_failed
                    - email_invalid_format
                    - email_domain_not_found
                    - email_mailbox_not_found
                    - address_state_without_license
                    - hazmat_destination
                    - ship_to_restricted
                    - verification_data_missing
                    - document_locked
                    - document_already_uploaded
                    - file_too_large
                    - file_type_not_supported
                    - reply_not_expected
                    - order_action_not_allowed
                    - supplier_refused_cancel
                    - order_total_changed
                    - order_has_problems
                    - idempotency_key_reused
                    - idempotency_key_in_use
                    - rate_limit_exceeded
                    - internal_error
                message:
                  type: string
                  description: A sentence for developers. It can change, so do not match on it.
                field:
                  type: string
                  description: The request field that caused the error. Only some errors have it.
                missing:
                  type: array
                  items:
                    type: string
                  description: Only on `verification_data_missing` and `app_setup_incomplete`.
                    What still needs to be set.
                quote:
                  type: object
                  required:
                    - groups
                    - unresolvedLines
                    - companyProblems
                    - total
                    - currency
                  properties:
                    groups:
                      type: array
                      description: One group per supplier. Each group becomes one order.
                      items:
                        type: object
                        required:
                          - supplierId
                          - lines
                          - productsTotal
                          - orderDiscount
                          - shipping
                          - freeShippingRemaining
                          - salesTax
                          - taxExemption
                          - total
                          - chargeTiming
                          - problems
                        properties:
                          supplierId:
                            type: string
                            examples:
                              - sup-1Ry6tUi3Op
                          lines:
                            type: array
                            items:
                              type: object
                              required:
                                - productId
                                - quantity
                                - unitPrice
                                - discount
                                - total
                              properties:
                                productId:
                                  type: string
                                quantity:
                                  type: integer
                                unitPrice:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                discount:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                total:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                          productsTotal:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          orderDiscount:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          shipping:
                            type: object
                            required:
                              - amount
                              - kind
                            properties:
                              amount:
                                type:
                                  - number
                                  - "null"
                                description: The shipping charge in US dollars, or `null` when it cannot be
                                  worked out.
                              kind:
                                type: string
                                enum:
                                  - free
                                  - flat
                                  - carrier
                          freeShippingRemaining:
                            type:
                              - number
                              - "null"
                            description: How much more to order for free shipping, or `null` when it does
                              not apply.
                          salesTax:
                            type:
                              - number
                              - "null"
                            description: The sales tax in US dollars, or `null` when it cannot be worked
                              out.
                          taxExemption:
                            type: object
                            required:
                              - certificateId
                              - notAppliedReason
                            properties:
                              certificateId:
                                type:
                                  - string
                                  - "null"
                                description: The exemption certificate used, or `null`.
                              notAppliedReason:
                                type:
                                  - string
                                  - "null"
                                enum:
                                  - no_certificate
                                  - other_state
                                  - not_reviewed
                                  - null
                                description: Why no certificate applies, or `null` when one does.
                          total:
                            type:
                              - number
                              - "null"
                            description: >
                              The amount the salon pays for this group in US
                              dollars, or `null` when it cannot be worked out.
                              Send it back as

                              `expectedTotal`. A group with problems has no
                              `expectedTotal`.
                          chargeTiming:
                            type: string
                            enum:
                              - now
                              - after_verification
                            description: >
                              `now`: Beauty Router charges the card when the
                              order is created. `after_verification`: the
                              company is

                              `prequalified`, so the charge waits until its
                              verification ends.
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    unresolvedLines:
                      type: array
                      description: The lines no supplier can take.
                      items:
                        type: object
                        required:
                          - productId
                          - quantity
                          - problems
                        properties:
                          productId:
                            type: string
                          quantity:
                            type: integer
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    companyProblems:
                      type: array
                      description: What stops every group.
                      items:
                        type: object
                        required:
                          - code
                          - message
                        properties:
                          code:
                            type: string
                            description: What stops a group or the whole request. See
                              [Problems](/create-orders/#problems).
                            enum:
                              - buying_suspended
                              - supplier_unavailable
                              - address_state_without_license
                              - ship_to_restricted
                              - hazmat_destination
                              - address_not_deliverable
                              - connection_required
                              - connection_blocked
                              - insufficient_stock
                              - product_unavailable
                              - shipping_unavailable
                              - tax_unavailable
                              - delivery_address_required
                              - delivery_phone_required
                              - payment_card_required
                              - payment_card_unusable
                              - quantity_limit_exceeded
                              - order_limit_exceeded
                              - order_below_minimum
                          message:
                            type: string
                            description: A sentence you can show. It can change, so do not match on it.
                          productId:
                            type: string
                            description: The product. Only on problems with one product.
                          supplierId:
                            type: string
                            description: The supplier. Only on problems with one supplier.
                          available:
                            type: integer
                            description: How many units can be ordered. Only on `insufficient_stock`.
                    total:
                      type:
                        - number
                        - "null"
                      description: The sum of all the groups in US dollars, or `null` when a group's
                        total is.
                    currency:
                      type: string
                      const: usd
                      description: Always `usd`.
        examples:
          invalid_user_token:
            value:
              error:
                code: invalid_user_token
                message: The user token is missing or not valid.
          user_token_expired:
            value:
              error:
                code: user_token_expired
                message: The user token expired. Log the user in again.
  "403":
    description: "`company_not_verified`: the company is not `prequalified` or `verified`."
    content:
      application/json:
        schema:
          type: object
          description: The body of every error response.
          required:
            - error
          properties:
            error:
              type: object
              required:
                - code
                - message
              properties:
                code:
                  type: string
                  description: A stable error code.
                  enum:
                    - invalid_app_token
                    - invalid_user_token
                    - user_token_expired
                    - origin_not_allowed
                    - ip_not_allowed
                    - user_cannot_manage_company
                    - user_cannot_order
                    - company_blocked
                    - company_not_verified
                    - app_setup_incomplete
                    - not_found
                    - validation_failed
                    - email_invalid_format
                    - email_domain_not_found
                    - email_mailbox_not_found
                    - address_state_without_license
                    - hazmat_destination
                    - ship_to_restricted
                    - verification_data_missing
                    - document_locked
                    - document_already_uploaded
                    - file_too_large
                    - file_type_not_supported
                    - reply_not_expected
                    - order_action_not_allowed
                    - supplier_refused_cancel
                    - order_total_changed
                    - order_has_problems
                    - idempotency_key_reused
                    - idempotency_key_in_use
                    - rate_limit_exceeded
                    - internal_error
                message:
                  type: string
                  description: A sentence for developers. It can change, so do not match on it.
                field:
                  type: string
                  description: The request field that caused the error. Only some errors have it.
                missing:
                  type: array
                  items:
                    type: string
                  description: Only on `verification_data_missing` and `app_setup_incomplete`.
                    What still needs to be set.
                quote:
                  type: object
                  required:
                    - groups
                    - unresolvedLines
                    - companyProblems
                    - total
                    - currency
                  properties:
                    groups:
                      type: array
                      description: One group per supplier. Each group becomes one order.
                      items:
                        type: object
                        required:
                          - supplierId
                          - lines
                          - productsTotal
                          - orderDiscount
                          - shipping
                          - freeShippingRemaining
                          - salesTax
                          - taxExemption
                          - total
                          - chargeTiming
                          - problems
                        properties:
                          supplierId:
                            type: string
                            examples:
                              - sup-1Ry6tUi3Op
                          lines:
                            type: array
                            items:
                              type: object
                              required:
                                - productId
                                - quantity
                                - unitPrice
                                - discount
                                - total
                              properties:
                                productId:
                                  type: string
                                quantity:
                                  type: integer
                                unitPrice:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                discount:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                total:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                          productsTotal:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          orderDiscount:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          shipping:
                            type: object
                            required:
                              - amount
                              - kind
                            properties:
                              amount:
                                type:
                                  - number
                                  - "null"
                                description: The shipping charge in US dollars, or `null` when it cannot be
                                  worked out.
                              kind:
                                type: string
                                enum:
                                  - free
                                  - flat
                                  - carrier
                          freeShippingRemaining:
                            type:
                              - number
                              - "null"
                            description: How much more to order for free shipping, or `null` when it does
                              not apply.
                          salesTax:
                            type:
                              - number
                              - "null"
                            description: The sales tax in US dollars, or `null` when it cannot be worked
                              out.
                          taxExemption:
                            type: object
                            required:
                              - certificateId
                              - notAppliedReason
                            properties:
                              certificateId:
                                type:
                                  - string
                                  - "null"
                                description: The exemption certificate used, or `null`.
                              notAppliedReason:
                                type:
                                  - string
                                  - "null"
                                enum:
                                  - no_certificate
                                  - other_state
                                  - not_reviewed
                                  - null
                                description: Why no certificate applies, or `null` when one does.
                          total:
                            type:
                              - number
                              - "null"
                            description: >
                              The amount the salon pays for this group in US
                              dollars, or `null` when it cannot be worked out.
                              Send it back as

                              `expectedTotal`. A group with problems has no
                              `expectedTotal`.
                          chargeTiming:
                            type: string
                            enum:
                              - now
                              - after_verification
                            description: >
                              `now`: Beauty Router charges the card when the
                              order is created. `after_verification`: the
                              company is

                              `prequalified`, so the charge waits until its
                              verification ends.
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    unresolvedLines:
                      type: array
                      description: The lines no supplier can take.
                      items:
                        type: object
                        required:
                          - productId
                          - quantity
                          - problems
                        properties:
                          productId:
                            type: string
                          quantity:
                            type: integer
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    companyProblems:
                      type: array
                      description: What stops every group.
                      items:
                        type: object
                        required:
                          - code
                          - message
                        properties:
                          code:
                            type: string
                            description: What stops a group or the whole request. See
                              [Problems](/create-orders/#problems).
                            enum:
                              - buying_suspended
                              - supplier_unavailable
                              - address_state_without_license
                              - ship_to_restricted
                              - hazmat_destination
                              - address_not_deliverable
                              - connection_required
                              - connection_blocked
                              - insufficient_stock
                              - product_unavailable
                              - shipping_unavailable
                              - tax_unavailable
                              - delivery_address_required
                              - delivery_phone_required
                              - payment_card_required
                              - payment_card_unusable
                              - quantity_limit_exceeded
                              - order_limit_exceeded
                              - order_below_minimum
                          message:
                            type: string
                            description: A sentence you can show. It can change, so do not match on it.
                          productId:
                            type: string
                            description: The product. Only on problems with one product.
                          supplierId:
                            type: string
                            description: The supplier. Only on problems with one supplier.
                          available:
                            type: integer
                            description: How many units can be ordered. Only on `insufficient_stock`.
                    total:
                      type:
                        - number
                        - "null"
                      description: The sum of all the groups in US dollars, or `null` when a group's
                        total is.
                    currency:
                      type: string
                      const: usd
                      description: Always `usd`.
        examples:
          company_not_verified:
            value:
              error:
                code: company_not_verified
                message: The company must be prequalified or verified to see wholesale prices
                  and order.
  "429":
    description: "`rate_limit_exceeded`: too many requests. Wait a moment and try again."
    content:
      application/json:
        schema:
          type: object
          description: The body of every error response.
          required:
            - error
          properties:
            error:
              type: object
              required:
                - code
                - message
              properties:
                code:
                  type: string
                  description: A stable error code.
                  enum:
                    - invalid_app_token
                    - invalid_user_token
                    - user_token_expired
                    - origin_not_allowed
                    - ip_not_allowed
                    - user_cannot_manage_company
                    - user_cannot_order
                    - company_blocked
                    - company_not_verified
                    - app_setup_incomplete
                    - not_found
                    - validation_failed
                    - email_invalid_format
                    - email_domain_not_found
                    - email_mailbox_not_found
                    - address_state_without_license
                    - hazmat_destination
                    - ship_to_restricted
                    - verification_data_missing
                    - document_locked
                    - document_already_uploaded
                    - file_too_large
                    - file_type_not_supported
                    - reply_not_expected
                    - order_action_not_allowed
                    - supplier_refused_cancel
                    - order_total_changed
                    - order_has_problems
                    - idempotency_key_reused
                    - idempotency_key_in_use
                    - rate_limit_exceeded
                    - internal_error
                message:
                  type: string
                  description: A sentence for developers. It can change, so do not match on it.
                field:
                  type: string
                  description: The request field that caused the error. Only some errors have it.
                missing:
                  type: array
                  items:
                    type: string
                  description: Only on `verification_data_missing` and `app_setup_incomplete`.
                    What still needs to be set.
                quote:
                  type: object
                  required:
                    - groups
                    - unresolvedLines
                    - companyProblems
                    - total
                    - currency
                  properties:
                    groups:
                      type: array
                      description: One group per supplier. Each group becomes one order.
                      items:
                        type: object
                        required:
                          - supplierId
                          - lines
                          - productsTotal
                          - orderDiscount
                          - shipping
                          - freeShippingRemaining
                          - salesTax
                          - taxExemption
                          - total
                          - chargeTiming
                          - problems
                        properties:
                          supplierId:
                            type: string
                            examples:
                              - sup-1Ry6tUi3Op
                          lines:
                            type: array
                            items:
                              type: object
                              required:
                                - productId
                                - quantity
                                - unitPrice
                                - discount
                                - total
                              properties:
                                productId:
                                  type: string
                                quantity:
                                  type: integer
                                unitPrice:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                discount:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                total:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                          productsTotal:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          orderDiscount:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          shipping:
                            type: object
                            required:
                              - amount
                              - kind
                            properties:
                              amount:
                                type:
                                  - number
                                  - "null"
                                description: The shipping charge in US dollars, or `null` when it cannot be
                                  worked out.
                              kind:
                                type: string
                                enum:
                                  - free
                                  - flat
                                  - carrier
                          freeShippingRemaining:
                            type:
                              - number
                              - "null"
                            description: How much more to order for free shipping, or `null` when it does
                              not apply.
                          salesTax:
                            type:
                              - number
                              - "null"
                            description: The sales tax in US dollars, or `null` when it cannot be worked
                              out.
                          taxExemption:
                            type: object
                            required:
                              - certificateId
                              - notAppliedReason
                            properties:
                              certificateId:
                                type:
                                  - string
                                  - "null"
                                description: The exemption certificate used, or `null`.
                              notAppliedReason:
                                type:
                                  - string
                                  - "null"
                                enum:
                                  - no_certificate
                                  - other_state
                                  - not_reviewed
                                  - null
                                description: Why no certificate applies, or `null` when one does.
                          total:
                            type:
                              - number
                              - "null"
                            description: >
                              The amount the salon pays for this group in US
                              dollars, or `null` when it cannot be worked out.
                              Send it back as

                              `expectedTotal`. A group with problems has no
                              `expectedTotal`.
                          chargeTiming:
                            type: string
                            enum:
                              - now
                              - after_verification
                            description: >
                              `now`: Beauty Router charges the card when the
                              order is created. `after_verification`: the
                              company is

                              `prequalified`, so the charge waits until its
                              verification ends.
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    unresolvedLines:
                      type: array
                      description: The lines no supplier can take.
                      items:
                        type: object
                        required:
                          - productId
                          - quantity
                          - problems
                        properties:
                          productId:
                            type: string
                          quantity:
                            type: integer
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    companyProblems:
                      type: array
                      description: What stops every group.
                      items:
                        type: object
                        required:
                          - code
                          - message
                        properties:
                          code:
                            type: string
                            description: What stops a group or the whole request. See
                              [Problems](/create-orders/#problems).
                            enum:
                              - buying_suspended
                              - supplier_unavailable
                              - address_state_without_license
                              - ship_to_restricted
                              - hazmat_destination
                              - address_not_deliverable
                              - connection_required
                              - connection_blocked
                              - insufficient_stock
                              - product_unavailable
                              - shipping_unavailable
                              - tax_unavailable
                              - delivery_address_required
                              - delivery_phone_required
                              - payment_card_required
                              - payment_card_unusable
                              - quantity_limit_exceeded
                              - order_limit_exceeded
                              - order_below_minimum
                          message:
                            type: string
                            description: A sentence you can show. It can change, so do not match on it.
                          productId:
                            type: string
                            description: The product. Only on problems with one product.
                          supplierId:
                            type: string
                            description: The supplier. Only on problems with one supplier.
                          available:
                            type: integer
                            description: How many units can be ordered. Only on `insufficient_stock`.
                    total:
                      type:
                        - number
                        - "null"
                      description: The sum of all the groups in US dollars, or `null` when a group's
                        total is.
                    currency:
                      type: string
                      const: usd
                      description: Always `usd`.
        examples:
          rate_limit_exceeded:
            value:
              error:
                code: rate_limit_exceeded
                message: Too many requests. Wait a moment and try again.
  "500":
    description: "`internal_error`: something failed on Beauty Router's side. Try
      again later."
    content:
      application/json:
        schema:
          type: object
          description: The body of every error response.
          required:
            - error
          properties:
            error:
              type: object
              required:
                - code
                - message
              properties:
                code:
                  type: string
                  description: A stable error code.
                  enum:
                    - invalid_app_token
                    - invalid_user_token
                    - user_token_expired
                    - origin_not_allowed
                    - ip_not_allowed
                    - user_cannot_manage_company
                    - user_cannot_order
                    - company_blocked
                    - company_not_verified
                    - app_setup_incomplete
                    - not_found
                    - validation_failed
                    - email_invalid_format
                    - email_domain_not_found
                    - email_mailbox_not_found
                    - address_state_without_license
                    - hazmat_destination
                    - ship_to_restricted
                    - verification_data_missing
                    - document_locked
                    - document_already_uploaded
                    - file_too_large
                    - file_type_not_supported
                    - reply_not_expected
                    - order_action_not_allowed
                    - supplier_refused_cancel
                    - order_total_changed
                    - order_has_problems
                    - idempotency_key_reused
                    - idempotency_key_in_use
                    - rate_limit_exceeded
                    - internal_error
                message:
                  type: string
                  description: A sentence for developers. It can change, so do not match on it.
                field:
                  type: string
                  description: The request field that caused the error. Only some errors have it.
                missing:
                  type: array
                  items:
                    type: string
                  description: Only on `verification_data_missing` and `app_setup_incomplete`.
                    What still needs to be set.
                quote:
                  type: object
                  required:
                    - groups
                    - unresolvedLines
                    - companyProblems
                    - total
                    - currency
                  properties:
                    groups:
                      type: array
                      description: One group per supplier. Each group becomes one order.
                      items:
                        type: object
                        required:
                          - supplierId
                          - lines
                          - productsTotal
                          - orderDiscount
                          - shipping
                          - freeShippingRemaining
                          - salesTax
                          - taxExemption
                          - total
                          - chargeTiming
                          - problems
                        properties:
                          supplierId:
                            type: string
                            examples:
                              - sup-1Ry6tUi3Op
                          lines:
                            type: array
                            items:
                              type: object
                              required:
                                - productId
                                - quantity
                                - unitPrice
                                - discount
                                - total
                              properties:
                                productId:
                                  type: string
                                quantity:
                                  type: integer
                                unitPrice:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                discount:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                                total:
                                  type: number
                                  description: An amount in dollars, with up to two decimal places.
                          productsTotal:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          orderDiscount:
                            type: number
                            description: An amount in dollars, with up to two decimal places.
                          shipping:
                            type: object
                            required:
                              - amount
                              - kind
                            properties:
                              amount:
                                type:
                                  - number
                                  - "null"
                                description: The shipping charge in US dollars, or `null` when it cannot be
                                  worked out.
                              kind:
                                type: string
                                enum:
                                  - free
                                  - flat
                                  - carrier
                          freeShippingRemaining:
                            type:
                              - number
                              - "null"
                            description: How much more to order for free shipping, or `null` when it does
                              not apply.
                          salesTax:
                            type:
                              - number
                              - "null"
                            description: The sales tax in US dollars, or `null` when it cannot be worked
                              out.
                          taxExemption:
                            type: object
                            required:
                              - certificateId
                              - notAppliedReason
                            properties:
                              certificateId:
                                type:
                                  - string
                                  - "null"
                                description: The exemption certificate used, or `null`.
                              notAppliedReason:
                                type:
                                  - string
                                  - "null"
                                enum:
                                  - no_certificate
                                  - other_state
                                  - not_reviewed
                                  - null
                                description: Why no certificate applies, or `null` when one does.
                          total:
                            type:
                              - number
                              - "null"
                            description: >
                              The amount the salon pays for this group in US
                              dollars, or `null` when it cannot be worked out.
                              Send it back as

                              `expectedTotal`. A group with problems has no
                              `expectedTotal`.
                          chargeTiming:
                            type: string
                            enum:
                              - now
                              - after_verification
                            description: >
                              `now`: Beauty Router charges the card when the
                              order is created. `after_verification`: the
                              company is

                              `prequalified`, so the charge waits until its
                              verification ends.
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    unresolvedLines:
                      type: array
                      description: The lines no supplier can take.
                      items:
                        type: object
                        required:
                          - productId
                          - quantity
                          - problems
                        properties:
                          productId:
                            type: string
                          quantity:
                            type: integer
                          problems:
                            type: array
                            items:
                              type: object
                              required:
                                - code
                                - message
                              properties:
                                code:
                                  type: string
                                  description: What stops a group or the whole request. See
                                    [Problems](/create-orders/#problems).
                                  enum:
                                    - buying_suspended
                                    - supplier_unavailable
                                    - address_state_without_license
                                    - ship_to_restricted
                                    - hazmat_destination
                                    - address_not_deliverable
                                    - connection_required
                                    - connection_blocked
                                    - insufficient_stock
                                    - product_unavailable
                                    - shipping_unavailable
                                    - tax_unavailable
                                    - delivery_address_required
                                    - delivery_phone_required
                                    - payment_card_required
                                    - payment_card_unusable
                                    - quantity_limit_exceeded
                                    - order_limit_exceeded
                                    - order_below_minimum
                                message:
                                  type: string
                                  description: A sentence you can show. It can change, so do not match on it.
                                productId:
                                  type: string
                                  description: The product. Only on problems with one product.
                                supplierId:
                                  type: string
                                  description: The supplier. Only on problems with one supplier.
                                available:
                                  type: integer
                                  description: How many units can be ordered. Only on `insufficient_stock`.
                    companyProblems:
                      type: array
                      description: What stops every group.
                      items:
                        type: object
                        required:
                          - code
                          - message
                        properties:
                          code:
                            type: string
                            description: What stops a group or the whole request. See
                              [Problems](/create-orders/#problems).
                            enum:
                              - buying_suspended
                              - supplier_unavailable
                              - address_state_without_license
                              - ship_to_restricted
                              - hazmat_destination
                              - address_not_deliverable
                              - connection_required
                              - connection_blocked
                              - insufficient_stock
                              - product_unavailable
                              - shipping_unavailable
                              - tax_unavailable
                              - delivery_address_required
                              - delivery_phone_required
                              - payment_card_required
                              - payment_card_unusable
                              - quantity_limit_exceeded
                              - order_limit_exceeded
                              - order_below_minimum
                          message:
                            type: string
                            description: A sentence you can show. It can change, so do not match on it.
                          productId:
                            type: string
                            description: The product. Only on problems with one product.
                          supplierId:
                            type: string
                            description: The supplier. Only on problems with one supplier.
                          available:
                            type: integer
                            description: How many units can be ordered. Only on `insufficient_stock`.
                    total:
                      type:
                        - number
                        - "null"
                      description: The sum of all the groups in US dollars, or `null` when a group's
                        total is.
                    currency:
                      type: string
                      const: usd
                      description: Always `usd`.
        examples:
          internal_error:
            value:
              error:
                code: internal_error
                message: Something went wrong. Try again later.
parameters: []
```
