Я пытаюсь сгенерировать продажу по HTTP-запросу POST, используя SquarePOS API
Это запрос, который я выполняю в Почтальоне
curl -X POST \
https://connect.squareup.com/v2/locations/*****/orders \
-H 'Authorization: Bearer ******' \
-H 'Cache-Control: no-cache' \
-H 'Content-Type: application/json' \
-H 'Postman-Token: ******' \
-d '{
"idempotency_key": "123456AZD",
"reference_id": "my-order-006",
"line_items": [
{
"name": "Américain - Article de base",
"quantity": "1",
"base_price_money": {
"amount": 1599,
"currency": "EUR"
}
}
],
"taxes": [
],
"discounts": [
]
}'
Сервер отвечает
{
"order": {
"id": "DQYutFAsu5hB8Xr56zBdmiilxd4F",
"location_id": "N7VH9XRBT57MP",
"line_items": [
{
"quantity": "1",
"name": "Américain - Article de base",
"base_price_money": {
"amount": 1599,
"currency": "EUR"
},
"gross_sales_money": {
"amount": 1599,
"currency": "EUR"
},
"total_tax_money": {
"amount": 0,
"currency": "EUR"
},
"total_discount_money": {
"amount": 0,
"currency": "EUR"
},
"total_money": {
"amount": 1599,
"currency": "EUR"
}
}
],
"created_at": "2018-04-30T12:44:47.816Z",
"updated_at": "2018-04-30T12:44:47.816Z",
"status": "OPEN",
"reference_id": "my-order-006",
"total_tax_money": {
"amount": 0,
"currency": "EUR"
},
"total_discount_money": {
"amount": 0,
"currency": "EUR"
},
"total_money": {
"amount": 1599,
"currency": "EUR"
}
}
}
Что говорит о том, что заказ был успешно создан. Однако, просматривая панель управления SquarePOS, я не вижу продажи в списке продаж.
Что-то мне не хватает при создании заказа?