API ReferenceInvoices

Refund an invoice

Request a full or partial refund from the payment provider.

Omit amount to refund the full remaining refundable balance. Partial amounts are decimal strings in the invoice currency; response amounts use integer minor units. Provider credentials and raw provider payloads are never returned.

POST
/v2/invoices/{invoice}/refunds

Authorization

AuthorizationBearer <token>

Provide your SellApp API key as a bearer token.

In: header

Path Parameters

invoice*integer

The invoice path parameter.

Header Parameters

X-STORE?string

Store slug. Required for OAuth access tokens. API keys may omit it to use their current store, or the first accessible store when no current store is selected.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://sell.app/api/v2/invoices/0/refunds" \  -H "X-STORE: launch-lab" \  -H "Content-Type: application/json" \  -d '{    "amount": "12.50"  }'
{
  "data": {
    "invoice": {
      "id": 9001,
      "payment": {
        "fee": {
          "base": "0",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "0",
            "inclusive": "0"
          }
        },
        "gateway": {
          "type": "STRIPE",
          "data": {}
        },
        "subtotal": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "expires_at": "2026-09-02T12:00:00Z",
        "full_price": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "original_amount": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        }
      },
      "status": {
        "history": [
          {
            "setAt": "2026-09-01T12:00:00Z",
            "status": "PENDING",
            "updatedAt": "2026-09-01T12:01:00Z"
          }
        ],
        "status": {
          "setAt": "2026-09-01T12:01:00Z",
          "status": "COMPLETED",
          "updatedAt": "2026-09-07T12:00:00Z"
        }
      },
      "webhooks": [],
      "feedback": "",
      "created_at": "2026-09-01T12:00:00Z",
      "updated_at": "2026-09-07T12:00:00Z",
      "store_id": 1,
      "coupon_id": null,
      "subscription_id": null,
      "customer_information": {
        "id": 77,
        "email": "maya@example.com",
        "country": "United States",
        "location": "Portland",
        "ip": "192.0.2.1",
        "proxied": false,
        "browser_agent": "Example browser",
        "vat": {
          "amount": "0",
          "country": "US"
        },
        "discord_data": null,
        "billing_details": null
      },
      "product_variants": [
        {
          "id": 4321,
          "product_id": 120,
          "title": "Standard"
        }
      ]
    },
    "refund": {
      "status": "pending",
      "provider": "stripe",
      "provider_refund_id": "re_example_launch_lab",
      "amount_cents": 1250,
      "currency": "USD"
    }
  }
}
{
  "type": "invalid_request_error",
  "code": "bad_request",
  "message": "The request could not be understood.",
  "status": 400,
  "param": null,
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#bad-request"
}
{
  "type": "authentication_error",
  "code": "unauthenticated",
  "message": "Unauthenticated.",
  "status": 401,
  "param": null,
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#unauthenticated"
}
{
  "type": "authorization_error",
  "code": "forbidden",
  "message": "This action is unauthorized.",
  "status": 403,
  "param": null,
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#forbidden"
}
{
  "type": "not_found_error",
  "code": "resource_not_found",
  "message": "Not Found.",
  "status": 404,
  "param": null,
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#resource-not-found"
}
{
  "type": "validation_error",
  "code": "validation_failed",
  "message": "The selected product variant id is invalid.",
  "status": 422,
  "param": "product_variant_id",
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#validation-failed",
  "errors": {
    "product_variant_id": [
      "The selected product variant id is invalid."
    ]
  }
}
{
  "type": "rate_limit_error",
  "code": "rate_limit_exceeded",
  "message": "Too Many Attempts.",
  "status": 429,
  "param": null,
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#rate-limit-exceeded"
}
{
  "type": "api_error",
  "code": "api_error",
  "message": "Server Error",
  "status": 500,
  "param": null,
  "request_id": "01992a65-e064-71ba-b38f-902b7966a6be",
  "docs_url": "https://sell.app/docs/api/errors#api-error"
}