Skip to main content
POST
Node.js

Authorizations

Authorization
string
header
required

A secret API key, made under Developers in the dashboard: Authorization: Bearer shoply_sk_...

Headers

Idempotency-Key
string

A word of your own for this one change, up to 180 letters, digits, dots, dashes, underscores and colons. Sent again with the same key, the request is not carried out twice: the first answer comes back, with Idempotent-Replay: true.

Path Parameters

storeId
string
required

The store's ID. A key reaches the store it was made in: GET /key answers which.

orderId
string
required

The order. The ID in a checkout's address is the order's ID.

Body

application/json
destination
enum<string>
required

source: back through the payment provider, to what paid. balance: credit on the buyer's balance at the store. record: only marked as refunded, because you returned the money yourself.

Available options:
source,
balance,
record
reason
enum<string>
required

Why.

Available options:
requested,
duplicate,
fraudulent,
other
amount
number

For balance only: how much to credit, from 0.01 up to what was paid, with at most 2 decimals. Left out, all of it.

Response

It worked.

success
boolean
message
unknown
code
unknown
data
object