Closed andreground closed 7 years ago
{
"error": "This endpoint does not support the merchant facade"
}
It does work but the token architecture is a bit more complex.
Essentially there are 2 types of token:
'merchant'
)So in order to initiate a refund, you need 2 calls. For the adjustments/refunds call, you need to fetch first the resource token derived for a specific invoice when sending the POST request (see getInvoice()
function on /src/Bitpay/Client/Client.php)
It's the same approach with all resources. For instance if you want to get the report to do the reconciliation for a specific bank settlements (GET/settlements/:settlementId/reconciliationReport
) you need to fetch first the token created for the specific 'settlementId'.
According to REST API docs, we should be able to get a list of all the (eventual) refunds connected to an invoice using the following method:
Unfortunately, the request always returns the same error, even if properly configured (merchant token used, request properly signed, headers set correctly).
Request/Response dump (tokens cleared):
Response is:
Thanks in advance