Hey folks, trying to figure out if it’s possible for me to build a custom solution via the Square API to fulfill a particular set of client requirements.
The client has existing Inventory & POS for their physical retail locations through Square, and wants to add ecomm. They need the ecomm frontend to be via WooCommerce (Can’t do a Square Online storefront), but want all backend to operate & be managed via Square (Item Catalogue, Inventory, Payment Gateway, Customer & Order data/crm, etc).
I know the Square extension for WooCommerce will handle the inventory sync, but wont sync Customer or Order data from WooCommerce into Square. They want to be able to setup an official Square fulfillment/shipping integration (ShipBob, Shippo, etc), but I can’t find any info in the docs about whether or not manually adding successful WooCommerce orders into Square via the Create Order API endpoint would trigger a configured fulfillment/shipping integration like this?
The UX & dev flow would be:
WooComm item catalogue is synced from Square >>
Customer completes successful WooCommerce Order (using Square as payment gatway) >>
Automated WooComm function is triggered to 'Create_Order' and add customer data into Square via Square API
My 2 questions here are:
Can I use the Create Order endpoint like this to just add an Order record into Square, and have it marked as already paid/processed (since it was already completed via WooComm)? Will there be any conflicts or duplicate issues here, since the payment gateway was also Square and a payment was already recorded from the actual WooComm transaction?
Will an already configured Shippo or ShipBob fulfillment integration be triggered by this manual record entry of a WooCommerce completed Order?
I believe the WooCommerce integration does create itemized order within Square. Have you checked with WooCommerce about that?
Also the flow you described would create duplicate records in Square. A payment can’t be added to an order after it’s been completed.
Thanks for the response, Bryan! The WooComm reps I spoke with said that Order and Customer data does not sync from Woo into Square. They said there would be a Payment Transaction recorded into Square (since Square would be used as the gateway, but not Order or Customer data). Any idea how I could confirm 100% either way?
And RE: the duplicate thing. The flow I mentioned was assuming Woo would not automatically sync the Order data to Square. If that’s the case, is it possible with the Square API to Create Order, but mark it as “already paid/processed” in the create request?
Client wants to use WooComm on the front end, but use the Square Dashboard as their single CRM to manage orders and customers for both their physical retail location sales, and ecomm via Woo. In the case where Woo definitely doesn’t sync that info to Square, just trying to figure out if it’s even possible for me to build a custom solution to make that happen for them
Interesting, I guess you could test it using Sandbox cause I know WooCommerce has steps to take test payments with Square.
The problem is that all payments that are created in Square will have an
order_id. So if WooCommerce integration processes the payment that payment will automatically have an order. Then if you create an itemized order that order has to be paid for to show in the Seller Dashboard. The only way that you could pay for that order and have it show on the Dashboard would be an external payment. There isn’t a way to associate another payment that’s been completed to a new order.
Yeah, lol I’m actually firing up a dummy wp proj now to just dive in and start tinkering to see how it all actually works.
That’s interesting to know that at least some version of an Order entity is definitely created in Square upon successful Woo transaction. So maybe the “Woo doesn’t send Orders to square” messaging im getting from Woo really means “A Square Order is created… it’s just gonna be mostly empty cuz we’re not sending any of the contextual Order data”.
If that’s the case, and assuming Woo’s version of an “order_id” matches the one in Square… At the very least, I could probably bind a listener to Woo orders, and auto trigger an event to grab and query for that order_id via Square API, then hit the UpdateOrder endpoint to fill in all the Order and Customer data that Woo refused to send over to Square (product line items, prices, customer data, etc.). lol Right? Are there any limitations to what fields/props can be appended with UpdateOrder that would be a blocker to that logic?
Also, thanks for the responses and help by the way, greatly appreciated!
In order to update the order details you’ll need to get the order before it’s paid for. I don’t really know when WooCommerce creates the order but it’s worth a look.
lol woof, I keep striking out.
Interesting findings actually… I configured a test environment and hooked up Woo+Square to my Square account and made some test sandbox purchases. Purchases from Woo are not actually creating any visible Orders in Square at all… The Transaction line items are all showing up correctly in Square’s dashboard, all the Reports throughout are reflecting the transactions, it’s even actually syncing Customer data into Square (which Woo folks said it wouldn’t do)… but nothing at all in Orders, just says “No orders to display”.
If I pop open the detail drawer of a “Transaction” line item, I can see that it tags a transaction with:
Order Source: Sandbox for sq0idp-v0EfMiJhRybZnOEo6L9JGw
and it’s a clickable link, but it just routes to a totally empty Orders section. So it looks like there is at least some form of Order entity created and logged… but for whatever reason, it’s not showing up in the Orders browser? Is there some minimum combo of props/values that need to be set on an Order object for it to show up in the browser? Only thing I can think of is something like an Order requires the property “current_order_state” (or something…) to be set, which probably isn’t being written for the case of a Woo generated transaction Order… and cuz it’s missing something, it’s just being filtered out of the Orders list in the dash?
I’m actually looking at the “Search Orders” json right now from the API explorer… it’s all there. Like ALL the Order Data that Woo folks said wouldn’t send to Square… line items, pricing + tax data, “state”: “COMPLETED”, transaction id’s, etc.
Any way I can DM you the full JSON results here and maybe you can see something that might indicate why these Order records aren’t showing up in the Dashboard?
That’s what I thought. Thanks for taking the time to test. The reason that the orders aren’t showing in the Orders section of the Dashboard is case the orders don’t have a
fulfillment. Only orders that have a
fulfillment and are fully paid for will show in the Orders section. Otherwise all other itemized/non-itemized payments will be in the Transactions section.
If you use Transactions section as your source of truth instead of Orders you should be good to go.
Yeah, this is exactly it. I was able to clone one of the Woo purchases that was hidden, “pay it” and “add fulfillment” in the API explorer, and that one showed up in Orders!
The last piece of this puzzle I need to figure before I can push the project forward on Square, is whether Square Fulfillment/Shipping integrations will work with this flow? Not sure exactly where in the data/logic chain the handoff from Woo to Square is happening, or which system is actually building/mutating that final json Order structure (paid + completed + missing fulfillment key<>vals)… But with however that’s actually happening, will a Square-side fulfillment/shipping integration actually work (ShipBob, Shippo, EasyShip & ShipStation)? Or do those need to hook into an earlier step of the data funnel than the Woo >>> Square flow would provide access to?
I know a bunch of these providers have Woo specific integrations… I just know the Client requirements might need a certain integration that’s only available on the Square side. Also, new to the forums here, so if derailing from the OP topic like this breaks etiquette, I can spin up a new thread
Great! I believe that the integrations should pickup the
fulfillment cause that’s how all orders are handled. I may be worth reaching out to the 3rd party providers or just testing.
You’re the man! Thanks for all the help Bryan!
Hi–Did you end up completing this project? A client needs to do the same thing, and I’m looking for a developer. She’s had one failed attempt with another vendor so need to keep budget small.