Refunds

Create a refund session

Changed on

Create a refund session

post/api/v1/refund-session

Request

Request body

merchant_idstring uuid

Merchant ID. Defaults to the logged-in merchant if not provided. Required for admin tokens.

idstring

Shopify refund session ID

gidstring

Global identifier

payment_idstring required

Original payment ID

amountstring required

Refund amount

currencystring required

ISO 4217 currency code

merchant_localestring

Merchant locale

proposed_atstring

When the refund was proposed

testboolean

Whether this is a test refund

Example request

{
  "merchant_id": "550e8400-e29b-41d4-a716-446655440000",
  "id": "JM1YXF4yUe0vmo-FHsgVK3ZC",
  "gid": "gid://shopify/RefundSession/JM1YXF4yUe0vmo-FHsgVK3ZC",
  "payment_id": "rSOX4QcIGECb4ZEydY8GgMTfO",
  "amount": "1.00",
  "currency": "GBP",
  "merchant_locale": "en",
  "proposed_at": "2025-02-21T11:17:05Z",
  "test": true
}

Response

Success

idstring required
statusstring required
reasonstring

Changes

    • breaking

      the request property's minLength was increased from 0 to 3

    • breaking

      added the pattern ^[A-Za-z]{3}$ to the request property

    • breaking

      the / response's property type changed from string to no type for status

    • warning

      the request property's maxLength was set to 3

    • warning

      removed the optional property / from the response with the status

    • info

      added the new optional request property

    • info

      added the optional property / to the response with the status

    • info

      added subschema #1 subschema #2 to the / response property allOf list for the response status

    • info

      endpoint added