Retrieving Device Information for Test Orders Using Square API Explorer

Hello community,

I’m currently experimenting with the Square API Explorer to create test orders for my application. However, I’ve noticed that the orders I’m retrieving through the Orders API don’t include the device field in the response.

I would like to ensure that the device field is consistently provided in the response so that I can associate orders with the POS devices used to create them.

Is there a way to ensure that a device ID is always provided in the Orders response, especially when creating test orders using the Square API Explorer? Should I include additional parameters in my order requests to obtain the device information?

I’m particularly interested in test orders created directly through Square Point of Sale (POS) devices at a specific location. Could anyone share insights or best practices to achieve this in the context of the Square API Explorer?

Thank you for your guidance!

Hey @Muraya, welcome to the forums! The device_details field is set automatically, so there is not currently a way to do so via API Explorer — it should be populated when the transaction comes through Square Point of Sale though.

You’ll also want to be using the Payments API to retrieve objects that contain device_details, not the Orders API.

Let me know if there’s anything I can clarify!

Hey @josh-square , thank you!
I’m currently working on an integration with Square API, and I’m trying to retrieve device details for orders that are being placed but not yet paid for. I understand that the device_details field in the Square Payments API provides information about the device that processed a payment, but I’m specifically interested in orders that have not been paid for yet.

Is there a way to obtain the device details for such orders through the Square API? I’ve noticed that the device_details field is populated when a payment is processed through Square Point of Sale (POS) devices, but I’m unable to find a direct method to retrieve this information for orders in their pre-payment state.

I’m looking to associate orders with the specific POS device from which they are created, even before they are paid for. This would help me track the origin of each order and better manage my integration.

Got it, thanks for the clarification! Unfortunately getting this data prior to payment is not currently possible.

Bummer! Okay, thanks!

1 Like