Link Search Menu Expand Document

Receipt created webhook

Triggered as a result of a basket being sent successfully to Spaaza and a digital receipt being subsequently created in Spaaza.

The object returned as a result of registering to this webhook is as follows:

{
  "id": 123456,
  "timestamp": "2017-07-03T11:56:04Z",
  "type": "in_store",
  "download_url": "https://s3-eu-west-1.amazonaws.com/test01-receipts-bucket/receipts/123456.pdf",
  "quantity": 1,
  "subtotal": 1000,
  "total_value": 1000,
  "payment_method": "unknown",
  "line_items": [
    {
      "product_id": 0,
      "barcode": "2000046371025",
      "sku": "2000046371025",
      "name": "ACME shorts",
      "description": "the best pair you can buy",
      "type": "shorts",
      "original_price": 1000,
      "quantity": 1,
      "sale_price": 1000,
      "vouchers": 0,
      "metadata": {
        "color": "blue",
        "size": "L",
        "image": ""
      },
      "sale_discount": ""
    }
  ],
  "tax_lines": [],
  "chain": {
    "id": 1740,
    "name": "ACME",
    "email": "support@acme.co.za",
    "logo_url": "https://s3-eu-west-1.amazonaws.com/receipts-chain-logo/1000.png",
    "website_url": "",
    "currency": "South African Rand",
    "currency_symbol": "R",
    "business": {
      "id": 0,
      "name": "ACME Cape Town",
      "address": {
        "address_1": "1 Table Mountain Drive",
        "address_2": "",
        "address_3": "",
        "towncity": "Cape Town",
        "postal_code": "",
        "country_code": "ZA",
        "location": {
          "lat": -33.962822,
          "lon": 18.4098410
        }
      },
      "phone_number": "+272189777777",
      "email": "table-mountain@acme.co.za",
      "website_url": ""
    },
    "receipts_service_active": true
  },
  "shopper": {
    "id": 897654,
    "user_name": "",
    "entity_code": "",
    "first_name": "John",
    "last_name": "Smith",
    "country_code": "",
    "gender": "M",
    "birthday": "1982-05-30",
    "total_points_balance": 0,
    "email": "john.smith@email.com",
    "registered": false,
    "shipping_address": {
      "address_1": "",
      "address_2": "",
      "address_3": "",
      "towncity": "",
      "postal_code": "",
      "country_code": "",
      "location": {
        "lat": 0,
        "lon": 0
      }
    },
    "billing_address": {
      "address_1": "",
      "address_2": "",
      "address_3": "",
      "towncity": "",
      "postal_code": "",
      "country_code": "",
      "location": {
        "lat": 0,
        "lon": 0
      }
    }
  },
  "monetary_wallet": {
    "contributions": [
      {
        "amount": 100,
        "campaign_title": "Earn big on every purchase"
      }
    ],
    "total": 1640,
    "title": "ACME Bucks"
  },
  "points_wallet": {
    "contributions": [],
    "total": 0,
    "title": ""
  },
  "basket_vouchers": [
    {
      "campaign_title": "Boardriders Bucks",
      "voucher_text": "",
      "amount": 500,
      "type": "wallet"
    }
  ]
},