Assuming you have applied the card balance, and there is a remainder (missing_sum
is greater than 0). When you carry out a payment, it will redeem the full balance of the card. The missing sum is paid with the normal payment.
In this case we will execute the payment with POST /api/v2/Smart/Transactions/{id}/start/cash
after you have received the payment at the cash register:
Request
POST /api/v2/Smart/Transactions/STX_KJXJDUN542NR3WMRHRVU5WWM6ZQEA2/start/cash HTTP/1.1
Host: connect-testing.secuconnect.com
Authenticate: Bearer qb56tjj1bcvo9n2nj4u38k84lo
Content-Type: application/json
Accept: application/json
{
}
Now our system is informed about the completed cash payment. It will also execute the loyalty transaction now.
Response
{
"object"
:
"smart.transactions"
,
"id"
:
"STX_KJXJDUN542NR3WMRHRVU5WWM6ZQEA2"
,
"merchant"
: {
"object"
:
"general.merchants"
,
"id"
:
"MRC_35SZ3R5GGQQP4T0U2T5GFAN9P6C4PG"
,
"companyname"
:
"John's Bakery"
},
"device_source"
: {
"object"
:
"smart.devices"
,
"id"
:
"SDV_2YJDXYESB2YBHECVB5GQGSYPNM8UA6"
},
"transactions"
: [
{
"object"
:
"loyalty.transactions"
,
"id"
:
"LTX_YBYPUETZ2HQXURG9XU0M5H4KGWW0NH"
}
],
"created"
:
"2020-09-17T09:18:14+02:00"
,
"updated"
:
"2020-09-17T09:43:59+02:00"
,
"status"
:
"ok"
,
"merchantRef"
:
null
,
"transactionRef"
:
null
,
"intent"
:
null
,
"basket"
: {
"products"
: [
{
"id"
: 1,
"parent"
:
null
,
"articleNumber"
:
"30037"
,
"ean"
:
""
,
"desc"
:
"Sandwich Romano"
,
"quantity"
: 1,
"priceOne"
: 349,
"tax"
: 7,
"group"
: [],
"serialNumber"
:
null
,
"item_type"
:
"article"
,
"reference_id"
:
null
,
"contract_id"
:
null
,
"sum"
:
null
},
{
"id"
: 2,
"parent"
:
null
,
"articleNumber"
:
"30200"
,
"ean"
:
""
,
"desc"
:
"Fruit salad, small bowl"
,
"quantity"
: 1,
"priceOne"
: 249,
"tax"
: 7,
"group"
: [],
"serialNumber"
:
null
,
"item_type"
:
"article"
,
"reference_id"
:
null
,
"contract_id"
:
null
,
"sum"
:
null
},
{
"id"
: 3,
"parent"
:
null
,
"articleNumber"
:
"51"
,
"ean"
:
"4999012345678"
,
"desc"
:
"Water, mildly sprinkling, 0.25 ltr."
,
"quantity"
: 2,
"priceOne"
: 99,
"tax"
: 19,
"group"
: [],
"serialNumber"
:
null
,
"item_type"
:
"article"
,
"reference_id"
:
null
,
"contract_id"
:
null
,
"sum"
:
null
}
],
"texts"
: [],
"type"
:
"default"
},
"receipt"
: [
{
"type"
:
"separator"
,
"value"
: {
"caption"
:
"Kundenkarte"
}
},
{
"type"
:
"name-value"
,
"value"
: {
"name"
:
"Kartennummer: "
,
"value"
:
"9276004429942845"
,
"decoration"
: []
}
},
{
"type"
:
"name-value"
,
"value"
: {
"name"
:
"TA Code: "
,
"value"
:
"29187332"
,
"decoration"
: []
}
},
{
"type"
:
"space"
},
{
"type"
:
"textline"
,
"value"
: {
"text"
:
"Umsatz erfasst:"
,
"decoration"
: []
}
},
{
"type"
:
"textline"
,
"value"
: {
"text"
:
"7,96 EUR"
,
"decoration"
: [
"important"
]
}
},
{
"type"
:
"space"
},
{
"type"
:
"textline"
,
"value"
: {
"text"
:
"Aktuelles Guthaben"
,
"decoration"
: []
}
},
{
"type"
:
"textline"
,
"value"
: {
"text"
:
"10,00 EUR"
,
"decoration"
: [
"important"
]
}
}
],
"basket_info"
: {
"sum"
: 796,
"currency"
:
"EUR"
,
"gratuity"
:
null
,
"missing_sum"
: 0
},
"idents"
: [
{
"object"
:
"smart.idents"
,
"id"
:
"smi_1"
,
"prefix"
:
"9276"
,
"name"
:
"secucard Kundenkarte"
,
"type"
:
"card"
,
"value"
:
"9276004429942845"
,
"valid"
:
true
,
"merchantcard"
: {
"object"
:
"loyalty.merchantcards"
,
"id"
:
"MCD_2RXTNXPRM2YG9922UMBHHAEWEGN6AJ"
,
"merchant"
: {
"object"
:
"general.merchants"
,
"id"
:
"MRC_35SZ3R5GGQQP4T0U2T5GFAN9P6C4PG"
},
"created_for_merchant"
: {
"object"
:
"general.merchants"
,
"id"
:
"MRC_35SZ3R5GGQQP4T0U2T5GFAN9P6C4PG"
},
"card"
: {
"object"
:
"loyalty.cards"
,
"id"
:
"CRD_2U7MTNAMM3PMBPAB50C9G2AEHA9GPJ"
,
"cardnumber"
:
"9276004429942845"
,
"created"
:
"2015-09-28T16:01:20+02:00"
},
"cardgroup"
: {
"object"
:
"loyalty.cardgroups"
,
"id"
:
"CRG_2BESGJNETJJRZVVYS8R7JWGVWK4PRZ"
,
"display_name"
:
"Geschenkgutschein"
,
"display_name_raw"
:
"Geschenkgutschein"
,
"stock_warn_limit"
: 0,
"picture"
:
"https://connect.secucard.com/ds_g/8e79737df1e2513db48908b342c3cc436edf501a"
},
"created_for_store"
: {
"object"
:
"general.stores"
,
"id"
:
"STO_2ZCZRU9V6U8QA7B49K94667UP6C4PJ"
},
"customer"
: {
"object"
:
"loyalty.customers"
,
"id"
:
"CUS_2YBREKK0A2MNAXJ752TSDD9DH3PKAJ"
,
"contact"
: {
"name"
:
"Max Mustermann"
,
"forename"
:
"Max"
,
"surname"
:
"Mustermann"
,
"dob"
:
"2018-02-14T00:00:00+00:00"
},
"created"
:
"2018-05-03T10:14:06+02:00"
,
"consent_for_communication"
:
true
},
"is_base_card"
:
true
,
"points"
: 0,
"cash_balance"
: 1000,
"bonus_balance"
: 0,
"balance"
: 1000,
"last_usage"
:
"2020-09-24T15:51:06+02:00"
,
"last_charge"
:
"2020-09-24T14:40:57+02:00"
,
"stock_status"
:
"active"
,
"lock_status"
:
"unlocked"
,
"passcode"
: 0,
"expiry_date"
:
null
},
"customer"
: {
"object"
:
"loyalty.customers"
,
"id"
:
"CUS_2YBREKK0A2MNAXJ752TSDD9DH3PKAJ"
,
"contact"
: {
"name"
:
"Max Mustermann"
,
"forename"
:
"Max"
,
"surname"
:
"Mustermann"
,
"dob"
:
"2018-02-14T00:00:00+00:00"
},
"created"
:
"2018-05-03T10:14:06+02:00"
,
"consent_for_communication"
:
true
}
}
],
"payment_method"
:
"cash"
,
"trans_id"
:
"29187332"
,
"is_demo"
:
true
,
"application_context"
: {
"locks"
: {
"customer"
:
false
},
"return_urls"
:
null
,
"iframe_opts"
:
null
},
"checkout_links"
:
null
,
"payment_links"
:
null
}
You can see, there is a Loyalty Transaction in the field /transactions
. There are also some receipt lines for it in the field receipt
. There is another section that describes how to print or display the receipt.