unPLUGDevelopers

Orders and refunds API

Get an order

GET/v1/orders/{id}

Returns the order object.

Permissions: Secret key with checkout:write.

Path parameters#

  • idstring (uuid)Required

Response fields#

Returns 200 with Order

  • idstring (uuid)
    unPLUG's id for the order.
  • external_order_idstringNullable
    Your order id. Unique in your brand, forever.
  • statusstring
    credited, partially_refunded or refunded. See Order statuses.
    One of credited, partially_refunded, refunded
  • member_idstring (uuid)Nullable
    null for a guest order, which earns nothing.
  • location_idstring (uuid)
  • channelstring
    app or web for orders you send. Points earned at the register also show up, as orders with in_store. May grow.
    One of app, web, in_store
  • fulfillmentstringNullable
    pickup, delivery, curbside or dine_in.
  • placed_atstring (date-time)
    When the guest placed the order. The earn rate and bonuses in force at this time apply.
  • currencystring
    USD.
  • subtotal_centsinteger
    Sum of the lines, before discounts, tax and tip.
    Min 0
  • discount_centsinteger
    All discounts on the order, including the unPLUG redemption.
    Min 0
  • tax_centsinteger
    Recorded for reports. They never earn.
    Min 0
  • tip_centsinteger
    Recorded for reports. They never earn.
    Min 0
  • total_centsinteger
    What the guest paid: subtotal minus discount, plus tax and tip.
    Min 0
  • itemsarray of CartItem
    The cart lines, same shape as preview.
    Show attributesCartItem
    • line_idstring
      Your id for the line, unique within the cart.
    • pos_item_idstring
      Square catalog item variation id.
    • namestring
    • quantityinteger
      Min 1
    • unit_price_centsinteger
      Integer cents.
      Min 0
    • pos_category_idsarray of string
    • modifiersarray of object
      Show attributesHide attributes
      • pos_modifier_idstring
      • namestring
      • price_centsinteger
        Integer cents.
        Min 0
  • points_earnedinteger
    Points from the earn rate, on the subtotal after discounts, rounded down.
  • bonus_pointsinteger
    Extra points from promotions in force at placed_at.
  • redemptionsarray of object
    [{ "id", "status" }] for each redemption the order used.
    Show attributesHide attributes
    • idstring (uuid)
    • statusstring
  • memberobjectNullable
    { "points_balance", "tier" } right after the order was credited. Only on the create response and the order.credited webhook.
    Show attributesHide attributes
    • points_balanceinteger
    • Show attributesTierRef
      • idstring (uuid)
      • namestring
  • created_atstring (date-time)
    When unPLUG recorded the order.

Error descriptions#

404Not found
not_found

No order with this id in your brand.

Any endpoint can also return the common errors.