POS Transactions
For the completeness of data in the Piggy system, Piggy Clients may choose to create POS Transactions and link these to Credit Receptions.
Create POS Transaction
Creates a POS Transaction in the Piggy system. You may choose to set a transaction ID and/or a terminal ID.
POST
https://api.piggy.eu/api//pos-transactionsHeaders
Authorization
Bearer {{ api_key }}Accept
application/jsonBody
amount_in_centsnumberREQUIREDPurchase amount in cents (€10.40 = 1040)
transaction_idnumberOPTIONALID for transaction
terminal_idnumberOPTIONALID of the terminal used for transaction
Response Example
Show more
1
2
3
4
5
6
7
8
9
{
"data": {
"uuid": "1234-abcdefgh-5678-defghijk",
"transaction_id": "1",
"terminal_id": "1",
"created_at": "2021-01-01T12:00:00+00:00",
"amount_in_cents": 100
}
}
Code
Message
1003Invalid input.
Push POS Transaction
Send a push to Device after a POS Transaction creation, so a Credit Reception may be created using the Device.
POST
https://api.piggy.eu/api//pos-transactions/{pos_transaction_uuid}/pushHeaders
ParamsAuthorization
Bearer {{ api_key }}Accept
application/jsonpos_transaction_uuidstringREQUIREDThe POS Transaction UUID
Response Example
Show more
1
2
3
4
{
"data": [ ],
"meta": [ ]
}
Code
Message
1027POS Transaction not found.
6001The POS transaction is already linked to a credit reception.
