API
  1. Acquiring
API
  • Guides
    • Welcome
    • Interface
  • API Reference
    • Introduction
    • Endpoints
    • Data Types
    • Signing
    • 3-D Secure Verification
    • Subscription
    • Errors
    • Webhooks
    • Items Information
    • Changelog
    • Acquiring
      • Create a direct payment
        POST
      • Create a APM payment
        POST
      • Create a redirect (iFrame) payment
        POST
      • Query a transaction
        POST
      • Refund a transaction
        POST
      • Search a refund transaction
        POST
      • Review a transaction
        POST
      • Cancel a transaction
        POST
      • Cancel a subscription
        POST
      • Capture a transaction
        POST
      • Create a payout
        POST
      • Optimise payment methods
        POST
    • Issuing
      • Cardholder
        • Create cardholder
          POST
        • Delete cardholder
          POST
        • Query cardholder
          POST
      • Group
        • Create group
        • Query group details
        • Cancel group
        • Refund group
        • Update group status
        • Recharge group
      • Card
        • Create a card
        • Query card BIN
        • Recharge card
        • Withdraw from a card
        • Cancel a card
        • Update card status
        • Update card limit
        • Query card details
  • Appendix
    • Test Cards
    • Bank Code
    • Country Code
    • Currency Code
    • Payment Methods
  1. Acquiring

Refund a transaction

POST
/v1/refund
Refund orders by batch up to 50 orders in a single request.
Merchant can also manually refund a transaction in Merchant Portal.

Request

Header Params

Body Params application/json

Example
{
    "merchant_id": "{{merchant_id}}",
	"account_id": "{{account_id}}",
	"encryption_data": "e0570d4ba9730c85815363401fc6c0cd1501b3919c820a524529a40d0f1bfad7",
    "refund_orders":[
        {
            "transaction_id": "1379868618653958144",
		    "order_no": "1731469069933",
            "currency": "USD",
            "amount": "10.36",
            "refund_amount": "3.33",
            "refund_reason": "Interface Test"
        }
    ]
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://test-api.sufupayment.com/v1/refund' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-raw '{
    "merchant_id": "701001",
	"account_id": "701001010",
	"encryption_data": "e0570d4ba9730c85815363401fc6c0cd1501b3919c820a524529a40d0f1bfad7",
    "refund_orders":[
        {
            "transaction_id": "1379868618653958144",
		    "order_no": "1731469069933",
            "currency": "USD",
            "amount": "10.36",
            "refund_amount": "3.33",
            "refund_reason": "Interface Test"
        }
    ]
}'

Responses

🟢200Success
application/json
Body

Example
{
    "account_id": "701001010",
    "refund_orders": [
        {
            "amount": "10.36",
            "currency": "USD",
            "order_no": "1731469069933",
            "refund_amount": "3.33",
            "refund_message": "V0000:OK",
            "refund_reason": "Interface Test",
            "refund_reference": "",
            "refund_reference_id": "1379868618653958144-01",
            "refund_status": "1",
            "transaction_id": "1379868618653958144"
        }
    ],
    "return_message": "OK",
    "return_status": "1",
    "encryption_data": "e0570d4ba9730c85815363401fc6c0cd1501b3919c820a524529a40d0f1bfad7",
    "merchant_id": "701001"
}
Modified at 2024-11-15 07:35:50
Previous
Query a transaction
Next
Search a refund transaction