Refund

Build integration to refund customers with Trustly

Before you start

  • Make sure that you have completed Sign up and received a Trustly test account.
  • If you have a native app implementation, integrate Trustly SDKs.

Refund flow

In a typical Refund flow:

  1. Your system sends an API call to Refund.

  2. Trustly responds with "result" : "1" to acknowledge the call is received.

  3. Trustly checks whether the funds have been settled.

    • If the funds are not settled, Trustly will process the refund request when the funds are settled.
    • If the funds are settled, Trustly will process the refund request.
  4. Trustly sends a Payout confirmation when the funds are successfully sent from Trustly.

📘

Payout confirmation notification

The Payout confirmation is not enabled by default. Contact Trustly Integration Support, if you need it.

  1. If the refund fails, Trustly will send a Credit notification.
  2. Your system responds to the received notifications.

Step 1: Integrate your system with Trustly

Develop business logic according to the charge flow.

  1. Make sure that your integration follows security requirements. See Security.

  2. Make sure that you have sufficient funds in your Trustly account. You can schedule API call to Balance to ensure that your balance is sufficient.

  3. When a customer requests a refund, you system sends a call to Refund.

  4. Make sure that your integration logs and handles error codes that are returned from API calls. See Error handling.

  5. Make sure that your integration responds correctly to Trustly notifications.

Step 2: Do acceptance testing

Prior to going live, the Trustly Integration Specialist will perform Acceptance testing. Make sure your integration has passed all test cases, including:

  • Refund API calls, both full and partial
  • Verify that your integration has the correct responses to notifications. See Notification tool.

Step 3: Verify and go live

Follow the instructions to go live.