From 002eea95b8fd5b6acdcccc9d5b93cdafde3d7075 Mon Sep 17 00:00:00 2001 From: Jonathan Buchanan Date: Sat, 15 Aug 2020 18:22:28 -0400 Subject: change wallet refund spec --- core/api-merchant.rst | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/core/api-merchant.rst b/core/api-merchant.rst index cff71d04..f576e106 100644 --- a/core/api-merchant.rst +++ b/core/api-merchant.rst @@ -1428,9 +1428,6 @@ Payment processing // Amount that was refunded in total. refund_amount: Amount; - // Public key of the merchant. - merchant_pub: EddsaPublicKey; - } .. ts:def:: StatusUnpaidResponse @@ -1527,23 +1524,31 @@ Giving Refunds **Request:** - :query h_contract=HASH: hash of the order's contract terms (this is used to authenticate the wallet/customer in case $ORDER_ID is guessable). Required. + The request body is a `WalletRefundRequest` object. **Response:** :status 200 OK: The response is a `WalletRefundResponse`. + :status 204 No content: + There are no refunds for the order. :status 403 Forbidden: The ``h_contract`` does not match the order. :status 404 Not found: The merchant backend is unaware of the order. + .. ts:def:: WalletRefundRequest + + interface WalletRefundRequest { + // hash of the order's contract terms (this is used to authenticate the + // wallet/customer). + h_contract: HashCode; + + } + .. ts:def:: WalletRefundResponse interface WalletRefundResponse { - // Was the payment refunded (even partially, via refund or abort)? - refunded: boolean; - // Amount that was refunded in total. refund_amount: Amount; -- cgit v1.2.3