Orders Push Beta
Create Pickup Orders that are surfaced and managed in Square Point of Sale
Buyers are everywhere. And I really do mean everywhere. They’re purchasing on websites, web apps, native mobile apps, and even in messaging apps. There has been an explosion of places where buyers are making these purchases, and we’re here to connect them to our Sellers by giving developers the APIs and SDKs to do it. We’ve created tools like our In-App Payments SDK for integrating payments into native mobile apps, our Reader SDK for building custom POS apps connected to Square hardware to take in-person payments, and our Online Payments APIs to take payments from any website.
Today, Square is excited to announce the availability of Orders Push Beta. Orders Push is a new API that enables developers to create Orders that are displayed in the Square Point of Sale (iOS only) or Square dashboard.
On the surface, pushing orders to a Point of Sale (POS) sounds straightforward, but this is enabling any POS location to now become a place to fulfill orders.
What makes this new API really unique is that it enables developers to build their own order ahead mobile or web app (or any kind of app that take orders and payments) powered by Square Payments and push the orders directly into a Square merchant POS using Orders Push. Opening up a large number of potential sellers to leverage their solution and enable buyers to purchase their goods at any time from anywhere.
A pickup order in the Square Point of Sale.
Fulfillments and Square POS Orders
Orders Push introduces a new concept to Orders — fulfillment — which is a stateful representation of how an Order will be delivered to a customer. We can achieve this by simply passing "fulfillment"
with a ”*PICKUP”
*type on an Order. We then finalize the Order by authorizing a payment with the Transactions API.
Sellers running Square Point of Sale on an iPad will be alerted to the new order in their POS, they can optionally print an order ticket, and can manage their order. We provide fulfillment status (Open > Ready > Complete) for managing the fulfillment process. While we support only the “PICKUP”
fulfillment type today, we’re looking forward to supporting additional fulfillment workflows in the future.
curl -X POST https://connect.squareup.com/v2/locations/STORE_LOCATION_ID/orders \
-H "Authorization: Bearer SQUARE_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"idempotency_key": "UNIQUE_REQUEST_KEY",
"reference_id": "my-coffee-order-001",
"line_items": [
{
"name": "Coffee",
"quantity": "1",
"base_price_money": {
"amount": 200,
"currency": "USD"
}
}
],
"fulfillments": [
{
"type": "PICKUP",
"state": "PROPOSED",
"pickup_details": {
"recipient": {
"display_name": "Amelia Earhart",
"email_address": "[email protected]",
"phone_number": "1-212-555-4240"
},
"expires_at": "2019-02-14T20:21:54.859Z",
"auto_complete_duration": "P0DT1H0S",
"schedule_type": "SCHEDULED",
"pickup_at": "2019-02-14T19:21:54.859Z",
"pickup_window_duration": "PT1H0S",
"prep_time_duration": "PT20M",
"note": "Pour over coffee"
}
}
]
}'
Open Beta
In the Orders API documentation you’ll see that we’ve added a “BETA” tag to the related Orders Push fields. Beta endpoints and fields are subject to change and are not considered bulletproof, so keep this in mind during implementation and maintenance. We’re excited to hear how you’re using Orders Push and your feedback or feature requests, so please join us in our Slack community where we’ll set up a specific channel for this Beta.
If you want to keep up to date with the rest of our content, be sure to follow this blog & our Twitter account, and sign up for our developer newsletter! We also have a Slack community for connecting with and talking to other developers implementing Square APIs.