Inquiry Status

Inquiry Status is an optional service provided by Espay Payment Gateway that allows you to check the transaction status based on the order_id. By using this service, you can retrieve either the latest transaction status or the complete transaction status history for the same order_id by specifying the sortBy parameter.

Type Value
Service Code
26
Name
Inquiry Status
HTTP Method
POST

Flow

You send the required parameters to make a request, and Espay Payment Gateway will respond in JSON format.

API URL

Environment URL
Sandbox
Port of HTTPS (443)
https://sandbox-api.espay.id/apimerchant/v1.0/transfer-va/status
Production
Port of HTTPS (443)
https://api-merchant.espay.id/apimerchant/v1.0/transfer-va/status

Headers

Name Type Mandatory Description
Content-Type
String
Y
Content of your request body.

Example:
application/json
X-TIMESTAMP
String (25)
Y
Customer's current local date and time.

Format:
yyyy-MM-ddThh:mi:ssTZD (ISO 8601)

Example:
2024-03-14T07:49:28+07:00
X-SIGNATURE
String (255)
Y
Code used to validate transactions. Learn Payment Gateway | Asymmetric Signature
X-EXTERNAL-ID
String (32)
Y
Numeric String. Reference number that should be unique on the same day.
X-PARTNER-ID
String (50)
Y
Merchant Code from Espay team.

Example:
SGWYESSISHOP
CHANNEL-ID
String (5)
Y
Channel id.

Value:
Espay
Authorization-Customer
String (150)
C
Access Token B2B2C.
Espay -> Bank
Y: Yes, O: Optional, C: Conditional

Request Parameters

Parameter Type Mandatory Description
partnerServiceId
String (8)
Y
Partner service Id.

Format:
padding space + ESPAY

Value:
" ESPAY"
customerNo
String (20)
Y
Merchant code from Espay team.

Example:
SGWYESSISHOP
virtualAccountNo
String (28)
Y
Unique code to identify the order/billing/invoice.

Example:
Transaction number, invoice ID, etc.
inquiryRequestId
String (128)
C
Unique ID for Inquiry from Espay.
paymentRequestId
String (128)
O
Unique ID for payments from Espay.
additionalInfo
Object
C
  billNo
String (32)
C
Billing number for the static virtual account from the virtual account service (remark4).
  isPaymentNotif
String(1)
O
Transaction conditions.

Format:
  productCode
String (32)
C
Product code. Conditional if checking status using EDC or offline payment.
  paymentRef
String (18)
O
Transaction ID from Espay. Optional, only for EDC Machine Transaction.
  terminalId
String (32)
O
Terminal machine id. Optional, only for EDC Machine Transaction.
  traceNumber
String (32)
O
Trace number. Optional, only for EDC Machine Transaction.
  sortBy
String (8)
O
Specifies the transaction status to be returned. If sortBy is not provided, the default response returns the latest transaction status excluding IP.

Format:
  • TDD: Returns the latest transaction status, including IP.
  • ALL : Returns all transaction statuses (S, SP, EX, F, and IP).
Y: Yes, O: Optional, C: Conditional

Response Parameters

Parameter Type Mandatory Description
responseCode
String (7)
Y
Response code. See response codes here.

Format:
HTTP Code + Service Code + Error Code

Example:
200+26+00 = 2002600
responseMessage
String (150)
Y
Response description. See response descriptions here.
virtualAccountData
Object
Y
  partnerServiceId
String (8)
Y
Partner service Id.

Format:
padding space + ESPAY

Value:
" ESPAY"
  customerNo
String (20)
Y
Merchant code from Espay team.

Example:
SGWYESSISHOP
  paymentFlagStatus
String (2)
Y
Payment status.

Format:
  • Success: S
  • Failed: F
  • Suspect: SP
  • In Process: IP
  • Expired: EX
  • Waiting Correction: WC
  • Waiting Settlement: WS
  paymentFlagReason
Object
    english
String (64)
Y
Transaction description (English version).
    indonesia
String (64)
Y
Transaction description (Indonesian version).
  virtualAccountNo
String (28)
Y
Unique code to identify the order/billing/invoice.

Example:
Transaction number, invoice ID, etc.
  inquiryRequestId
String (128)
Y
Unique ID for Inquiry from Espay.
  paymentRequestId
String (128)
C
Unique ID for payments from Espay.
  paidAmount
Object
Y
    value
String (16.2)
Y
Paid amount.

Format:
Desimal .00 (ISO 4217)

Example:
150000.00
    currency
String (3)
Y
Transaction currency code.

Format:
  • Rupiah: IDR
  totalAmount
Object
Y
    value
String (16.2)
Y
Paid amount.

Format:
Desimal .00 (ISO 4217)

Example:
150000.00
    currency
String(3)
Y
Transaction currency code.

Format:
  • Rupiah: IDR
  trxDateTime
String (25)
Y
Date and time of transaction creation.

Format:
yyyy-MM-ddThh:mi:ssTZD (ISO 8601)

Example:
2022-08-21T14:45:28+07:00
  transactionDate
String (25)
Y
Payment date and time.

Format:
yyyy-MM-ddThh:mi:ssTZD (ISO 8601)

Example:
2022-08-21T14:56:11+07:00
  billDetails
Array of Object
Y
    billAmount
Object
Y
      value
String (16.2)
Y
Paid amount.

Format:
Desimal .00 (ISO 4217)

Example:
150000.00
      currency
String(3)
Y
Transaction currency code.

Format:
  • Rupiah: IDR
    billDescription
Object
Y
      english
String (18)
Y
Transaction description (English version).
      indonesia
String (18)
Y
Transaction description (Indonesian version).
    billNo
String (32)
C
Billing number for the static virtual account from the virtual account service (remark4).
additionalInfo
Object
C
  trxId
String (18)
Y
Transaction ID from Espay.
  expiredDatetime
String (25)
O
Time and expiration date of the transaction.

Format:
yyyy-MM-dd hh:mm:ss

Example:
2024-03-14 19:52:32
  memberCode
String(50)
O
Member code.

Format:
  • Virtual Account Static: Merchant Code
  • Virtual Account Dynamic: Virtual Account Number
  • E-Money: Merchant Code
  debitFrom
String(19)
O
Source account (debited account).
  debitFromName
String (64)
O
Source account name.
  debitFromBank
String (5)
O
Source account bank code.

Example:
008, 016, 002, etc.
  creditTo
String (19)
O
Destination account (credited account).
  creditToName
String (64)
O
Destination account name.
  creditToBank
String (5)
O
Destination account bank code. See the list of bank codes here.

Example:
008, 016, 002, etc.
  productCode
String (50)
O
Product code. See the list of product codes here.
  productValue
String (128)
O
Product value / payer phone number / payer masking card number / payer card type.
  rrn
String (12)
O
Unique code from QRIS payment.
  approvalCode
String (64)
O
Approval Code from bank.
  token
String (128)
O
Token from bank.
  userId
String (128)
O
ID user.
  message
Object
O
Additional information from bank.
  feeType
String (5)
O
Fee type.

Format:
  • Seller Fee: S
  • Buyer Fee: B
  txFee
String (16.2)
O
Transaction fee.

Format:
Desimal .00 (ISO 4217)

Example:
4400.00
  traceNumber
String (32)
O
Trace number from Payment. Conditional only EDC or offline payment.
  cardType
String (10)
C
Card type.

Format:
  • credit
  • debit
  data
Array of Object
C
Data transaction
Y: Yes, O: Optional, C: Conditional

Try It!

You can enter data using the input provided. After that, you submit and see the results!

Request

Value

Response


































Sample Headers

Content-Type:application/json
X-TIMESTAMP:2024-03-14T07:49:28+07:00
X-SIGNATURE:jXYIExgLGVYjAD1Shmj+1ezQV8pMgys+udT2Y02iHpqOkBf4eCNFKqAhlZXaMqnugMlJ9IGvXhgx5B/3LPD/uvR61oAvGBG6Q3IYQ4m2mqFbBOakbh0al5QEyWmHCL+Ixr1hUIcvWLQstAwR04B4tsXDnEaeEDV32yqXxVYS+n7O3VUUIpilcoC3FEagfg4Z9tkN97vNVzw8FMgszc+JekKRtM7fi8Xi/A2cmSg8P9Rwk3soIRCTPX7QlQ8asbqqvckci0D1t4fx/2IqkpVpMWmBl+FTKbiobjd+5z/yCu1SdtctJz/klMK38Og3jyLsi2jVkHC4HoqJBpXzCdDXbA==
X-EXTERNAL-ID:c4c48989-9a32-446c-82e6-869a5737a40f
X-PARTNER-ID:SGWYESSISHOP
CHANNEL-ID:ESPAY
               































Sample Request

{
    "partnerServiceId": " ESPAY",
    "customerNo": "SGWYESSISHOP",
    "virtualAccountNo": "DIGORDER000001",
    "inquiryRequestId": "abcdef-123456-abcdef",
    "paymentRequestId": "abcdef-123456-fedcba",
    "additionalInfo": {
        "billNo": "invoiceid0001",
        "isPaymentNotif":"Y",
        "paymentRef": "ESP1661161958ZQEG",
        "terminalId": "10380579",
        "traceNumber": "7007432222",
        "sortBy": "ALL"
    }
}
               





















































Sample Positive Response

{
    "responseCode": "2002600",
    "responseMessage": "Successful",
    "virtualAccountData": {
        "partnerServiceId": " ESPAY",
        "customerNo": "SGWYESSISHOP",
        "paymentFlagStatus": "IP",
        "paymentFlagReason": {
            "english": "In Process",
            "indonesia": "Dalam Proses"
        },
        "virtualAccountNo": "DIGORDER000001",
        "inquiryRequestId": "abcdef-123456-abcdef",
        "paymentRequestId": "abcdef-123456-fedcba",
        "paidAmount": {
            "value": "154400.00",
            "currency": "IDR"
        },
        "totalAmount": {
            "value": "150000.00",
            "currency": "IDR"
        },
        "trxDateTime": "2024-03-14T17:54:45+07:00",
        "transactionDate": "2024-03-14T17:52:31+07:00",
        "billDetails": [
            {
                "billAmount": {
                    "value": "150000.00",
                    "currency": "IDR"
                },
                "billDescription": {
                    "english": "Invoice DIGORDER000001",
                    "indonesia": "Invoice DIGORDER000001"
                },
                "billNo": "invoiceid0001"
            }
        ]
    },
    "additionalInfo": {
        "trxId": "ESP171041355218DT",
        "expiredDatetime": "2024-03-14 19:52:32",
        "memberCode": "SGWYESSISHOP",
        "debitFrom": "16095902XXXX",
        "debitFromName": "BCA",
        "debitFromBank": "014",
        "creditTo": "1111111111111",
        "creditToName": "1111111111111",
        "creditToBank": "014",
        "productCode": "BCAATM",
        "productValue": "4490525531976673",
        "rrn": "229018831918293",
        "approvalCode": "123456787654",
        "token": "",
        "userId": null,
        "feeType": "B",
        "userId": "4400.00",
        "traceNumber": "7007432222",
        "cardType": "debit",
        "data": [
            {
                "trxId": "ESP171041355218DT",
                "expiredDatetime": "2024-03-14 19:52:32",
                "memberCode": "SGWYESSOSHOP",
                "debitFrom": "",
                "debitFromName": "",
                "debitFromBank": "014",
                "creditTo": "1111111111111",
                "creditToName": "1111111111111",
                "creditToBank": "014",
                "productCode": "BCAATM",
                "productValue": "4490521409988818",
                "rrn": null,
                "approvalCode": null,
                "token": "",
                "userId": null,
                "feeType": "S",
                "txFee": "0.00",
                "virtualAccountNo": "2026073101",
                "paymentFlagStatus": "IP",
                "paidAmount": {
                    "value": "150000.00",
                    "currency": "IDR"
                },
                "totalAmount": {
                    "value": "150000.00",
                    "currency": "IDR"
                },
                "trxDateTime": "2024-03-14T17:54:45+07:00",
                "transactionDate": "",
                "cardType": "",
                "refundData": null
            },
            {
                "trxId": "ESP17854705667RML",
                "expiredDatetime": "2024-03-14 19:52:32",
                "memberCode": "SGWYESSOSHOP",
                "debitFrom": "",
                "debitFromName": "",
                "debitFromBank": "503",
                "creditTo": "1111111",
                "creditToName": "1111111",
                "creditToBank": "503",
                "productCode": "OVO",
                "productValue": "4490521409988818",
                "rrn": null,
                "approvalCode": null,
                "token": "",
                "userId": null,
                "feeType": "S",
                "txFee": "0.00",
                "virtualAccountNo": "2026073101",
                "paymentFlagStatus": "S",
                "paidAmount": {
                    "value": "25000.00",
                    "currency": "IDR"
                },
                "totalAmount": {
                    "value": "25000.00",
                    "currency": "IDR"
                },
                "trxDateTime": "2024-03-14T17:52:45+07:00",
                "transactionDate": "",
                "cardType": "",
                "refundData": null
            }
        ]
    }
}
                


Contoh Respons Negatif

{
    "responseCode": "4012600",
    "responseMessage": "Unauthorized. Invalid Signature from Client"
}
                    

HTTP

POST /apimerchant/v1.0/transfer-va/status HTTP/1.1
Host: sandbox-api.espay.id
Content-Type: application/json
X-TIMESTAMP: 2024-03-14T07:49:28+07:00
X-SIGNATURE: jXYIExgLGVYjAD1Shmj+1ezQV8pMgys+udT2Y02iHpqOkBf4eCNFKqAhlZXaMqnugMlJ9IGvXhgx5B/3LPD/uvR61oAvGBG6Q3IYQ4m2mqFbBOakbh0al5QEyWmHCL+Ixr1hUIcvWLQstAwR04B4tsXDnEaeEDV32yqXxVYS+n7O3VUUIpilcoC3FEagfg4Z9tkN97vNVzw8FMgszc+JekKRtM7fi8Xi/A2cmSg8P9Rwk3soIRCTPX7QlQ8asbqqvckci0D1t4fx/2IqkpVpMWmBl+FTKbiobjd+5z/yCu1SdtctJz/klMK38Og3jyLsi2jVkHC4HoqJBpXzCdDXbA==
X-EXTERNAL-ID: 70e4f317-527a-42a3-9527-a9a5f649d873
X-PARTNER-ID: SGWYESSISHOP
CHANNEL-ID: ESPAY

{
    "partnerServiceId": " ESPAY",
    "customerNo": "SGWYESSISHOP",
    "virtualAccountNo": "DIGORDER000001",
    "inquiryRequestId": "abcdef-123456-abcdef",
    "paymentRequestId": "abcdef-123456-abcdef",
    "additionalInfo": {
		"billNo": "invoiceid0001",
        "isPaymentNotif":"Y",
        "productCode": "EDCWS",
        "paymentRef": "ESP1661161958ZQEG",
        "terminalId": "10380579",
        "traceNumber": "7007432222"
    }
}
               


CURL

curl --location 'https://sandbox-api.espay.id/apimerchant/v1.0/transfer-va/status' \
--header 'Content-Type: application/json' \
--header 'X-TIMESTAMP: 2024-03-14T07:49:28+07:00' \
--header 'X-SIGNATURE: jXYIExgLGVYjAD1Shmj+1ezQV8pMgys+udT2Y02iHpqOkBf4eCNFKqAhlZXaMqnugMlJ9IGvXhgx5B/3LPD/uvR61oAvGBG6Q3IYQ4m2mqFbBOakbh0al5QEyWmHCL+Ixr1hUIcvWLQstAwR04B4tsXDnEaeEDV32yqXxVYS+n7O3VUUIpilcoC3FEagfg4Z9tkN97vNVzw8FMgszc+JekKRtM7fi8Xi/A2cmSg8P9Rwk3soIRCTPX7QlQ8asbqqvckci0D1t4fx/2IqkpVpMWmBl+FTKbiobjd+5z/yCu1SdtctJz/klMK38Og3jyLsi2jVkHC4HoqJBpXzCdDXbA==' \
--header 'X-EXTERNAL-ID: 73dafefe-f301-4402-892e-7bfbd326d3bf' \
--header 'X-PARTNER-ID: SGWYESSISHOP' \
--header 'CHANNEL-ID: ESPAY' \
--data '{
    "partnerServiceId": " ESPAY",
    "customerNo": "SGWYESSISHOP",
    "virtualAccountNo": "DIGORDER000001",
    "inquiryRequestId": "abcdef-123456-abcdef",
    "paymentRequestId": "abcdef-123456-abcdef",
    "additionalInfo": {
		"billNo": "invoiceid0001",
        "isPaymentNotif":"Y",
        "productCode": "EDCWS",
        "paymentRef": "ESP1661161958ZQEG",
        "terminalId": "10380579",
        "traceNumber": "7007432222"
    }
}'
               
Scroll to Top