انتقل إلى المحتوى

لم يُكتب وصف هذه العملية بالعربية بعد، فأوصافها بالإنجليزية.

Send POS receipt

POST/admin/v1/stores/{store_id}/pos/sales/{order_id}/receipt/send
  • pos:sell
  • يدعم Idempotency-Key

Sends the sale's receipt by WhatsApp, SMS or email, and records it on the sale. With save_customer, a walk-in becomes a customer with that number.

معاملات المسار

  • store_idstringمطلوب

    معرّف من نوع store، مثل store_01k8qs5s…. يصل إلى التطبيق مع التثبيت، في رابط OAuth وفي رد رمز الوصول.

  • order_idstringمطلوب

    معرّف من نوع ord، مثل ord_01k8qs5s….

الترويسات

  • Idempotency-Keystring

    أرسل المفتاح نفسه لإعادة المحاولة بأمان: تُعاد الإجابة الأولى لمدة ٢٤ ساعة.

  • shop-api-versionYYYY-MM

    الإصدار الذي تُكتب به الإجابة. بدونه يُستخدم الإصدار المثبّت لتطبيقك، وإلا الأحدث.

الجسم

  • channelenumمطلوب

    How a register sale's receipt reaches the customer.

    • email
    • sms
    • whatsapp
  • tostringمطلوب

    A phone number (in the store's country, or E.164) for whatsapp and sms; an email address for email.

  • save_customerboolean

    Save a walk-in as a customer with this number.

ما يُرجعه

200 Sent: the receipt.

الأخطاء

  • 404not_foundNot a register sale.
  • 409The store hasn't set up this channel (receipt_not_sent).
  • 422validation_failedNot a phone number or email address.