younifyd
Menu

Refund captured payment

Refund captured payment

POST/v2/payments/captures/{capture_id}/refund

Use it in a workflow

  1. Add a step and choose the PayPal connector.
  2. Pick the Refund captured payment action (under Payments).
  3. Fill in the fields below, then reference the result from later steps as {{refundCapturedPayment.response.data}}.

Request

Path parameters

capture_idstringrequired

The PayPal-generated ID for the captured payment to refund.

Headers

PayPal-Request-Idstring

A unique ID identifying the request header for idempotency purposes.

Preferstring

The preferred server response upon successful completion of the request. Value is:<ul><li><code>return=minimal</code>. The server returns a minimal response to optimize communication between the API caller and the server. A minimal response includes the <code>id</code>, <code>status</code> and HATEOAS links.</li><li><code>return=representation</code>. The server returns a complete resource representation, including the current state of the resource.</li></ul>

Default "return=minimal"

Authorizationstring

Holds authorization information for external API calls.

PayPal-Auth-Assertionstring

Header for an API client-provided JWT assertion that identifies the merchant. Establishing the consent to act-on-behalf of a merchant is a prerequisite for using this header.

Request body

Enter the body as JSON in the step's Body field.

amountany
custom_idstring

The API caller-provided external ID. Used to reconcile API caller-initiated transactions with PayPal transactions. Appears in transaction and settlement reports. The pattern is defined by an external party and supports Unicode.

invoice_idstring

The API caller-provided external invoice ID for this order. The pattern is defined by an external party and supports Unicode.

note_to_payerstring

The reason for the refund. Appears in both the payer's transaction history and the emails that the payer receives. The pattern is defined by an external party and supports Unicode.

payment_instructionany
json
{
  "amount": null,
  "custom_id": "string",
  "invoice_id": "string",
  "note_to_payer": "string",
  "payment_instruction": null
}

Response

Returns 200 with an object. Read it in later steps with {{refundCapturedPayment.response.data.<field>}}.

Need more? See the PayPal guide for connection setup and behaviour shared by every action.