Balance
An example request and response of a gift card balance check.
Request
Request
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
POST /api/payments/payment-account/balance HTTP/1.1
Authorization: Bearer <AccessToken>
Hmac: HMAC authentication filter
Content-Type: application/json
{
"accountIdentifier": {
"accountId": 123456789,
"accountKey": 7013360000000001000,
"cvc": 123,
"encryptedPin": "000",
"expiryDate": "12/20",
"securityCode": 123,
"track2": "7013360000000000000=2012125123"
}
}
Required | Field | Type | Description |
---|---|---|---|
check | accountIdentifier |
Object |
|
accountId |
string |
Swedbank Pay internal id for card/account. | |
check | accountKey |
string |
Primary Account Number (PAN) for card/account. This is mandatory if ‘track2’ is not present. |
cvc |
string |
Card Verification Code. | |
encryptedPin |
string |
If ‘000’ is set on authorization request, encrypted PIN block will be returned here. | |
expiryDate |
string |
Expiry date on card (only applicable for PaymentInstrumentType ‘creditcard’) where expiry date is printed on card. Format MM/YY | |
securityCode |
string |
Card Security Code. | |
track2 |
string |
Track 2 excluding start and end sentinel. |
Response
Response:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
{
"_links": [
{
"deprecation": "string",
"href": "string",
"hreflang": "string",
"media": "string",
"rel": "string",
"templated": true,
"title": "string",
"type": "string"
}
],
"paymentAccount": {
"accountSummary": {
"accountId": 123456789,
"balance": 10000,
"currency": "NOK",
"expiryDate": "2020-01-15",
"paymentInstrumentType": "giftcard"
},
"issuerSummary": {
"acquirerId": "string",
"acquirerName": "string",
"issuerId": "string",
"issuerName": "string",
"settlementProvided": true
}
}
}