Customer_id missing on some orders while using order search

This order has no customer_id when I do order search:
stdClass Object ( [id] => 6a9uibBEZlgbIHHi14L2WVk9429YY [location_id] => LVPWT9XXH5FNX [line_items] => Array ( [0] => stdClass Object ( [uid] => bf6f2b9b-b15c-3232-e9b2-bbc17cb6377e [catalog_object_id] => 557QGC5WG5NNW563EDAXJM2Y [catalog_version] => 1661548439017 [quantity] => 2 [name] => Paella Dinner [variation_name] => Regular [base_price_money] => stdClass Object ( [amount] => 2500 [currency] => USD ) [gross_sales_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [total_tax_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_discount_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [variation_total_price_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [item_type] => ITEM ) ) [created_at] => 2022-09-07T17:02:10.861Z [updated_at] => 2022-09-07T17:02:13.000Z [state] => COMPLETED [version] => 4 [total_tax_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_discount_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_tip_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [closed_at] => 2022-09-07T17:02:11.378Z [tenders] => Array ( [0] => stdClass Object ( [id] => NGgKbvobce1nwKTk8ZdtR5I2rvTZY [location_id] => LVPWT9XXH5FNX [transaction_id] => 6a9uibBEZlgbIHHi14L2WVk9429YY [created_at] => 2022-09-07T17:02:11Z [amount_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [type] => CASH [cash_details] => stdClass Object ( [buyer_tendered_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [change_back_money] => stdClass Object ( [amount] => 0 [currency] => USD ) ) [payment_id] => NGgKbvobce1nwKTk8ZdtR5I2rvTZY ) ) [total_service_charge_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [net_amounts] => stdClass Object ( [total_money] => stdClass Object ( [amount] => 5000 [currency] => USD ) [tax_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [discount_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [tip_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [service_charge_money] => stdClass Object ( [amount] => 0 [currency] => USD ) ) [source] => stdClass Object ( [name] => terminal ) [pricing_options] => stdClass Object ( [auto_apply_discounts] => 1 ) [net_amount_due_money] => stdClass Object ( [amount] => 0 [currency] => USD ) )

Yet, when lookup the order: Sign In

I see it has a name: Thomas Sadler
square_cust_missing

When the payment was take with Virtual Terminal was the customer added to the sale prior to the payment? :slightly_smiling_face:

I am not sure. what if is wasn’t? either way, there should be a customer_id somewhere???

Currently, if the Dashboard shows a customer associated to the payment it doesn’t always mean that a customer_id will be in the order. If the customer is added at the time of sale it will have the customer_id associated to it. We’re constantly working to improve our features based on feedback like this, so I’ll be sure to share your request to the API product team. :slightly_smiling_face:

Here is how they enter the sale through pos: we make the sale, charge credit, cash or check. Then screen pops up to add customer.

I need the customer info for my report how do i get it? Through the payment?

If they add the customer after the payment has been completed the customer_id should be present in the order. If they skip that step then the customer_id isn’t guaranteed to be in the order. :slightly_smiling_face:

yes they did so why isn’t the cust-id there then?

Any news on this? Sounds like a bug to me. Can you get this fixed?

The team is looking into this. :slightly_smiling_face:

Any idea when this is going to be fixed? I need it ASAP for my event report! Thank you.

The team confirmed that at the time of payment the customer wasn’t set in the payment request. The customer was added to the sale in the Dashboard which at this time doesn’t update the already completed order and that is why the customer_id isn’t showing in the order response. :slightly_smiling_face:

so how do I get the customer_id?
when I do a sales item report, it is included in the csv!

At this time it’s currently not available with the API even though it’s showing in the downloaded report. We’re constantly working to improve our features based on feedback like this, so I’ll be sure to share your request to the API product team. :slightly_smiling_face:

Well I need this asap, can’t you fix it? Or would it be on the payment record?

It’s unfortunately not going to be on the payment record as well. We are looking to make this better in the future. At this time there isn’t a public roadmap for this feature. With Virtual Terminal all customers should be added to the sale prior to payment. Adding the customer after payment will result with no customer_id in the order of the payment. :slightly_smiling_face:

We need an event report with a list of who paid to attend the event. We have been getting this through the Sales Item report, but it takes hours to format and massage the CSV file every time we need the report for an event. So I spent hours building this report using your API, to discover that I am not getting the customer ID when the sale is done through the POS system. This is just not right. I am extremely frustrated with Square and their lack of reporting. To me this is a bug in the API and it needs to be fixed ASAP so I can get my report out. Can you please escalate this and get it fixed please?

And by the way the POS system doesn’t ask for a customer until after the purchase!!!

Currently with the POS if you add a customer after the payment before hitting new sale the customer_id will be included in the order. The order example that you provided was taken with Virtual Terminal in the Seller Dashboard. With Virtual Terminal you are only given the option to add a customer before a sale. Not After. This is why there isn’t a customer_id in the order.

You can update the payment record in the Transactions section of the Dashboard to include a customer however it won’t add the customer to order that’s returned in the API response. This is what happened with this particular payment. We’re constantly working to improve our features based on feedback like this, so I’ll be sure to share your request to the API product team. :slightly_smiling_face:

But why is it in the Item Sales report then? This does not make any sense, it should not matter when the customer is added it should always be part of the order. Now go do the right thing and fix the damn bug :wink:

I haven’t heard back from you, I really need this to get fixed!
Here is another one that does not have a customer_id, yet it is an online order: i0apfaY9UicizhQXJBv9hdBgxMcZY

stdClass Object ( [id] => i0apfaY9UicizhQXJBv9hdBgxMcZY [location_id] => LVPWT9XXH5FNX [line_items] => Array ( [0] => stdClass Object ( [uid] => opYkcMKcyYZ15S1EatpVIC [catalog_object_id] => QGBOGCZPOEINK2FSLEGRSTIF [catalog_version] => 1663799744608 [quantity] => 2 [name] => Veterans Appreciation Night - Dinner for you & guest [variation_name] => [base_price_money] => stdClass Object ( [amount] => 1800 [currency] => USD ) [modifiers] => Array ( [0] => stdClass Object ( [uid] => 1jA3EBTmyv3dH6NbPVgEH [base_price_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_price_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [name] => Marine Corp [catalog_object_id] => ZFQECDLU44C6YLRLYUJ3PNAZ [catalog_version] => 1663799744608 [quantity] => 1 ) ) [gross_sales_money] => stdClass Object ( [amount] => 3600 [currency] => USD ) [total_tax_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_discount_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_money] => stdClass Object ( [amount] => 3600 [currency] => USD ) [variation_total_price_money] => stdClass Object ( [amount] => 3600 [currency] => USD ) [item_type] => ITEM ) ) [fulfillments] => Array ( [0] => stdClass Object ( [uid] => q0SJB9PTLMK0JPCvvkXCWC [type] => DIGITAL [state] => PROPOSED [line_item_application] => ALL ) ) [created_at] => 2022-09-23T05:05:53.938Z [updated_at] => 2022-09-23T05:05:57.000Z [state] => OPEN [version] => 4 [reference_id] => 11ed3afd317d7a7aa9c1ac1f6bbbd01e [total_tax_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_discount_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_tip_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [total_money] => stdClass Object ( [amount] => 3600 [currency] => USD ) [tenders] => Array ( [0] => stdClass Object ( [id] => X3Og6gt1py9KnJ0JrUszt2DrHaJZY [location_id] => LVPWT9XXH5FNX [transaction_id] => i0apfaY9UicizhQXJBv9hdBgxMcZY [created_at] => 2022-09-23T05:05:54Z [amount_money] => stdClass Object ( [amount] => 3600 [currency] => USD ) [type] => CARD [card_details] => stdClass Object ( [status] => CAPTURED [card] => stdClass Object ( [card_brand] => VISA [last_4] => 8110 [fingerprint] => sq-1-O3tVWxtMc2JC639hmY0oIuZD9r-qKrgy7c1-nxseT9S3F9GpQcsmIJaisFlodT71rQ ) [entry_method] => KEYED ) [payment_id] => X3Og6gt1py9KnJ0JrUszt2DrHaJZY ) ) [total_service_charge_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [net_amounts] => stdClass Object ( [total_money] => stdClass Object ( [amount] => 3600 [currency] => USD ) [tax_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [discount_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [tip_money] => stdClass Object ( [amount] => 0 [currency] => USD ) [service_charge_money] => stdClass Object ( [amount] => 0 [currency] => USD ) ) [source] => stdClass Object ( [name] => Square Online ) [net_amount_due_money] => stdClass Object ( [amount] => 0 [currency] => USD ) )