Refund Reasons API Routes
A refund reason is a possible reason used when issuing a refund to the customer, such as when returning an item and refunding the customer.
These API routes allow admin users to manage refund reasons.
GET /admin/refund-reasons#
List Refund Reasons
Retrieve a list of refund reasons. The refund reasons can be filtered by fields such as id. The refund reasons can also be sorted or paginated.
Authentication: secret API key (HTTP Basic authorization), cookie session, JWT bearer token.
Query parameters
fieldsstringOptional+ it will be added to the default fields, using - will remove it from the default fields. without prefix it will replace the entire default fields.offsetnumberOptionallimitnumberOptionalorderstringOptional-.idstring | string[]OptionalqstringOptional$andobject[]Optional$orobject[]Optionalwith_deletedbooleanOptionalRequest examples
Responses
200 OK
limitnumberoffsetnumbercountnumberrefund_reasonsobject[]The refund reason's refund reasons.
refund_reasonsobject[]400, 401, 404, 409, 422, 500: an error response is returned.
POST /admin/refund-reasons#
Create Refund Reason
Create a refund reason.
Authentication: secret API key (HTTP Basic authorization), cookie session, JWT bearer token.
Query parameters
fieldsstringOptional+ it will be added to the default fields, using - will remove it from the default fields. without prefix it will replace the entire default fields.Request body (application/json)
labelstringdescriptionstringOptionalcodestringRequest examples
Responses
200 OK
refund_reasonobjectThe refund reason's details.
refund_reasonobject400, 401, 404, 409, 422, 500: an error response is returned.
GET /admin/refund-reasons/{id}#
Get a Refund Reason
Retrieve a refund reason by its ID. You can expand the refund reason's relations or select the fields that should be returned.
Authentication: secret API key (HTTP Basic authorization), cookie session, JWT bearer token.
Path parameters
idstringQuery parameters
fieldsstringOptional+ it will be added to the default fields, using - will remove it from the default fields. without prefix it will replace the entire default fields.Request examples
Responses
200 OK
refund_reasonobjectThe refund reason's details.
refund_reasonobject400, 401, 404, 409, 422, 500: an error response is returned.
POST /admin/refund-reasons/{id}#
Update a Refund Reason
Update a refund reason's details.
Authentication: secret API key (HTTP Basic authorization), cookie session, JWT bearer token.
Path parameters
idstringQuery parameters
fieldsstringOptional+ it will be added to the default fields, using - will remove it from the default fields. without prefix it will replace the entire default fields.Request body (application/json)
labelstringOptionaldescriptionstringOptionalcodestringOptionalRequest examples
Responses
200 OK
refund_reasonobjectThe refund reason's details.
refund_reasonobject400, 401, 404, 409, 422, 500: an error response is returned.
DELETE /admin/refund-reasons/{id}#
Delete a Refund Reason
Delete a refund reason.
Authentication: secret API key (HTTP Basic authorization), cookie session, JWT bearer token.
Path parameters
idstringRequest examples
Responses
200 OK
idstringobjectstringDefault: "refund_reason"
deletedboolean400, 401, 404, 409, 422, 500: an error response is returned.