Description (User's Transaction List)
Show the list of Transactions related with the user. (GET)Can include the parameter "include" in the url to get more information:
- * store - provide store related with the transaction
- * fixed_code - provide fixed code related with the transaction
- * emv_code - provide emv code related with the transaction
Queries
In order to search Transactions you can add in the url the follow parameters.
- * id - id of the transaction
- * user_id - User Id who create the transaction
- * company_id - Company id where the transaction was created
- * store_id - Store id where the transaction was created
- * gateway_id - gateway Id used to create the transaction
- * barcode_id - Id of the barcode (if exists)
- * fixed_id - Id of the fixed code (if exists)
- * status - Status of the transaction
- * amount - Amount of the transaction
- * currency - Currency of the transaction
- * charge - Charge of the transaction
- * paid_at - date when the transaction was paid
- * settled_at - date when the transaction was settled
- * transaction_id - external id generated by the gateway
- * custom_id - Custom Identifier sent by user
- * refunded_at - date when the transaction was refunded
- * created_at - date when the transaction was created
- * updated_at - date when the transaction was updated
- * limit - control the records show on each page (if not set, default load 40 records)
- * page - control load the number of the page
Operators
- * "=" - the result is equal to
- * ">" - the result is bigger than
- * "<" - the result is less than
Example:
https://api-h2h-staging.yedpay.com/v1/users/{{user_id}}/transactions?include=store&created_at%3E=2017-09-12%2016:00:00&limit=50&page=1
-
* note - replace special characters to encoded characters:
- change spaces using "%20"
- change ">" using "%3E"
- change "<" using "%3C"
End Point
https://api-h2h-staging.yedpay.com/v1/users/{{user_id}}/transactions
Variable
| # | Name | Type | Description |
|---|---|---|---|
| 1 | user_id | String | User's ID |
Request Header
| # | Key | Value | Description |
|---|---|---|---|
| 1 | Authorization | Bearer {{access_token}} | Login Token |
Body
| # | Name | Type | Description |
|---|
Response
| # | Name | Type | Description |
|---|---|---|---|
| 1 | success | Boolean | The request is received without error. |
| 2 | data | Array | Include transaction's information (id, user_id, company_id etc..) |
Success Response - data
| # | Name | Type | Description |
|---|---|---|---|
| 1 | id | String(64) | Id of the transaction |
| 2 | user_id | String(64) | Id of the user who create the transaction |
| 3 | company_id | String(64) | Id of the Company |
| 4 | store_id | String(64) | Id of the Store |
| 5 | gateway_id | Integer | Id of the Gateway used to Generate the transaction |
| 6 | gateway_sub_id | Integer | Id of gateway subtype, default 1 |
| 7 | gateway_sub_name | String(65,535) | Name of the gateway subtype |
| 8 | gateway_code | String | {{gateway_id}}_{{gateway_sub_id}} - 1_1 - Alipay - 4_1 - Alipay Online, 4_2 - Alipay Online PC2Mobile, 4_3 - Alipay Online SDK - 7_1 - VISA, 7_2 - Mastercard - 8_1 - WeChat Pay, 8_2 - WeChat Pay Online, 8_3 - WeChat Pay Online SDK - 9_5 - UnionPay UPOP, 9_6 - UnionPay QR - 10_1 - UnionPay Merchant Presented Code, 10_2 - UnionPay Customer Presented Code - 11_1 - UnionPay POS, 11_2 - UnionPay POS V2 - 12_1 - VISA Online, 12_2 - Mastercard Online, 12_3 - Google Pay, 12_4 - Apple Pay - 13_1 - HSBC FPS Online, 13_2 - HSBC FPS Offline |
| 9 | barcode_id | String(64) | Id of the Barcode uset to generate the transaction (only apply for alipay Global) |
| 10 | payment_link_id | String(64) | (optinal) Id of the Pay Link |
| 11 | status | String | Status of the transaction |
| 12 | amount | String(15) | Amount of the transaction |
| 13 | currency | String(3) | Currency of the transaction |
| 14 | charge | String(15) | Total of charge fee for the transaction |
| 15 | refunded | String(15) | Refunded Amount of the Transaction |
| 16 | refund_charge | String(15) | Refund Charge of the Transaction |
| 17 | net | String(15) | Net Amount of the Transaction |
| 18 | tips | String(15) | Tips Amount of the Transaction |
| 19 | forex | Double | Forex |
| 20 | paid_at | Datetime | Date when the transaction was paid "YYYY-mm-dd h:i:s" |
| 21 | can_settle_after | Datetime | Date when the transaction balance will be settled "YYYY-mm-dd h:i:s" |
| 22 | is_balance_settled | Boolean | The transaction balance is settled or not |
| 23 | settled_at | Datetime | Date when the transaction was settled "YYYY-mm-dd h:i:s" |
| 24 | transaction_id | String(15) | Unique transaction identifier of Yedpay |
| 25 | reference_id | String(191) | Transaction identifier of the Gateway Provider |
| 26 | payer | String | Email of the payer (Alipay Global) |
| 27 | buyer_id | String | Buyer identity (Alipay Global) |
| 28 | wallet_type | String(20) | Wallet type of the transaction (Applicable for Alipay and WeChatPay) |
| 29 | extra_parameters | String(65,535) | (optional) Custom information send by customer |
| 30 | custom_id | String(36) | (optional) Custom Id Send By Customer |
| 31 | fixed_id | String(64) | (optional) Id of the Fixed Code |
| 32 | refunded_at | Datetime | Date when the transaction was Refunded "YYYY-mm-dd h:i:s" |
| 33 | created_at | Datetime | Date when the transaction was created "YYYY-mm-dd h:i:s" |
| 34 | updated_at | Datetime | Date when the was Updated "YYYY-mm-dd h:i:s" |
| 35 | expired_at | Datetime | (optional) Date when the transaction Expire "YYYY-mm-dd h:i:s" |
| 36 | pin_key | String | (optional) PIN Key for pin encryption (Applicable for UnionPay POS and precreated transaction status) |
| 37 | _links | Array | Include Checkout and QRCode Links:
- checkout - qrcode - (alipay online) checkout_wap - (alipay online) checkout_code - (alipay online) qrcode_wap |
| 38 | cancellation_details | Array | (exists if status is cancelled) Information of cancellation (request_user_id: The User who sent request, first_name: First name of the user, last_name: Last name of the user remark: reason of the sending request) |
| 39 | refund_details | Array | (exists if status is refunded) Information of refund (request_user_id: The User who sent request, first_name: First name of the user, last_name: Last name of the user remark: reason of the sending request) |
| 40 | fail_details | Array | (exists if status is failed) Information of failed transaction (request_user_id: The User who sent request, first_name: First name of the user, last_name: Last name of the user remark: reason of the sending request) |
Example Success Response
{
"success": true,
"data": [
{
"id": "xXxXxXxXxXXxXx",
"user_id": "xXxXxXxXxXXxXx",
"company_id": "xXxXxXxXxXXxXx",
"store_id": "xXxXxXxXxXXxXx",
"gateway_id": 1,
"gateway_sub_id": 1,
"gateway_sub_name": "Alipay",
"gateway_code": "1_1",
"barcode_id": "xXxXxXxXxXXxXx",
"status": "paid",
"amount": "10.00",
"currency": "HKD",
"charge": 1.20,
"refunded": "0.00",
"refund_charge": "0.00",
"net": "9.75",
"tips": "0.00",
"forex": 1,
"paid_at": "2018-11-20 14:06:45",
"can_settle_after": "2018-11-21 00:00:00",
"is_balance_settled": true,
"settled_at": "",
"transaction_id": "xXxXxXxXxXXxXx",
"reference_id": "xXxXxXxXxXXxXx",
"payer": "",
"buyer_id": "",
"wallet_type": "",
"extra_parameters": "{\"extra_1\": \"value_1\", \"extra_2\": \"value_2\", \"extra_3\": \"value_3\", \"extra_4\": \"value_4\"}",
"custom_id": "XxXxXxXxXxXxXxXxXx",
"fixed_id": "",
"refunded_at": "",
"created_at": "2018-11-20 14:06:45",
"updated_at": "2018-11-20 14:06:45",
"expired_at": "2018-11-21 14:06:45",
"_links": [
{
"rel": "checkout",
"href": "https://qr.alipay.com/xxxxxxxx"
},
{
"rel": "qrcode",
"href": "https://api-h2h-staging.yedpay.com/v1/q/alipay/xxxxxxx"
}
]
},
],
"meta": {
"pagination": {
"total": 1,
"count": 1,
"per_page": 40,
"current_page": 1,
"total_pages": 1,
"links": {
"next": "xxxxxx"
}
}
}
}
Example Error Response
{
"success": false,
"message": "Unauthenticated.",
"status": 500
}
v1.89.5-20251216 © The Payment Cards Group Limited. All rights reserved.