Skip to content
SoundSyncAudio software platform

Guide

Developer Refund API

Preview and confirm full-order or whole-product refunds with original payment, tax, share, and access checks.

SoundSync

Preview and confirmation

Current route and service contracts. Examples below are illustrative; live provider outcomes and client-host testing are separate checks.

GET /api/developer/purchases/:orderId/refund

Preview eligibility and the original refund breakdown.

Auth
Account Bearer JWT
Scope
Owned purchase and every affected product; refunds.create is required for preview and confirmation.
Request fields
  • query itemIds: string
Returns
Eligible preview with snapshot, availableItems, deadline, confirmationToken, and any unavailableReason; an existing blocking operation can return eligible:false.
Side effects
Retrieves the authorized resource. Operation-specific notes identify preparation or referral recording where applicable.
Notes
Developer JWT, refunds.create permission, and scope over every affected product are required. No payment is initiated.
Request, response and error reference

Query and header parameters

[
  {
    "name": "itemIds",
    "in": "query",
    "required": false,
    "schema": {
      "type": "string"
    }
  }
]

HTTP 200 response (application/json)

{
  "type": "object",
  "properties": {
    "eligible": {
      "type": "boolean"
    },
    "unavailableReason": {
      "type": [
        "string",
        "null"
      ]
    },
    "confirmationToken": {
      "type": "string"
    },
    "deadline": {
      "type": "string"
    },
    "snapshot": {
      "type": "object",
      "properties": {},
      "additionalProperties": true
    },
    "availableItems": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "minimum": 1
          },
          "product_id": {
            "type": "integer",
            "minimum": 1
          }
        },
        "additionalProperties": true
      }
    },
    "itemSelectionUnavailableReason": {
      "type": [
        "string",
        "null"
      ]
    },
    "operation": {
      "type": "object",
      "properties": {},
      "additionalProperties": true
    }
  },
  "additionalProperties": true
}

Documented failures: 503.

POST /api/developer/purchases/:orderId/refund

Confirm the current preview and request the refund.

Auth
Account Bearer JWT
Scope
Owned purchase and every affected product; refunds.create is required for preview and confirmation.
Request fields
  • confirm: true (required)
  • confirmationToken: string (required)
  • reason: string (required)
  • itemIds: array
Returns
202 with operation. Track its state; acceptance is not provider completion.
Side effects
Confirm the current preview and request the refund. Review the confirmation and retry requirements before repeating the request.
Notes
Do not send amount, amountCents, or items. Custom amount requests are rejected. The original capture must be eligible and the selected items must remain unrefunded.
Request, response and error reference

Request (application/json)

{
  "type": "object",
  "properties": {
    "confirm": {
      "const": true
    },
    "confirmationToken": {
      "type": "string"
    },
    "reason": {
      "type": "string",
      "minLength": 3,
      "maxLength": 1000
    },
    "itemIds": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "integer",
        "minimum": 1
      }
    }
  },
  "required": [
    "confirm",
    "confirmationToken",
    "reason"
  ],
  "additionalProperties": false
}

HTTP 202 response (application/json)

{
  "type": "object",
  "properties": {
    "operation": {
      "type": "object",
      "properties": {},
      "additionalProperties": true
    }
  },
  "additionalProperties": true
}

Documented failures: 400, 403, 404, 409, 503.

SoundSync

Illustrative preview request

Illustrative preview request
curl "https://www.soundsync.dev/api/developer/purchases/123/refund?itemIds=456" \
  -H "Authorization: Bearer DEVELOPER_TOKEN"

SoundSync

Illustrative confirmation body

Illustrative confirmation body
{
  "confirm": true,
  "confirmationToken": "TOKEN_FROM_CURRENT_PREVIEW",
  "reason": "Customer requested a product refund",
  "itemIds": [456]
}

SoundSync

Respond to the actual state

State or errorAction
requested / processing / pendingWait for the same operation; do not initiate another provider refund
succeededReconcile the selected access, tax, original shares, and statement
failed / canceledCheck the provider and stored operation before making a new request
needs_reviewContact support for reconciliation; payment completion and accounting completion can differ
REFUND_CONFIRMATION_REQUIREDFetch and review a fresh preview; do not reuse a changed quote
REFUND_WINDOW_CLOSED / REFUND_RENEWAL_EXCLUDEDStandard eligibility does not allow this payment
REFUND_ITEMS_INVALID / REFUND_SHARED_BUNDLE_ACCESSReview remaining whole items and linked bundle scope
REFUND_SETTLEMENT_BUSY / REFUND_DISPUTE_COLLISIONResolve the overlapping settlement or dispute before continuing

Financial and access boundaries

The customer receives the selected products' original paid amount and associated tax. SoundSync retains its original fee; actual additional refund charges belong to the developer. Original affiliate/collaborator shares reverse, and paid amounts are recovered from future earnings. Ordinary SoundSync-checkout processing remains covered; external merchant processing does not.

The 14-day window runs from the captured initial payment. Subscription renewals are excluded under the standard policy. External reseller reversal endpoints reconcile external fulfillment; they do not refund a SoundSync-collected payment.

The developer refund deadline

Eligible developers can initiate whole-product or full-order refunds before the 14-day deadline measured from the original captured payment. The server checks the captured amount, product scope, initial-payment eligibility and current refund state; a preview alone does not reserve or extend the window.

At the deadline, developer initiation is blocked. Contact SoundSync support for a review after that point; an exception is discretionary and not guaranteed. This does not restrict mandatory consumer rights. A request accepted within the window can finish provider processing and accounting afterward without becoming a second refund.