From 124d53ee53cabc2df6f0549e4211eb338e380f27 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Mon, 3 Aug 2020 16:46:21 +0200 Subject: document HTML-handling endpoints --- core/api-merchant.rst | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/core/api-merchant.rst b/core/api-merchant.rst index 1262742f..6e6629c0 100644 --- a/core/api-merchant.rst +++ b/core/api-merchant.rst @@ -1375,6 +1375,11 @@ Payment processing Query the payment status of an order. This endpoint is for the wallet. When the wallet goes to this URL and it is unpaid, they will be prompted for payment. + This endpoint typically also supports requests with the "Accept" header + requesting "text/html". In this case, an HTML response suitable for + triggering the interaction with the wallet is returned. If the backend + installation does not include the required HTML templates, a 406 status + code is returned. **Request:** @@ -2204,12 +2209,22 @@ Giving Customer Tips Handle request from wallet to provide details about a tip. + This endpoint typically also supports requests with the "Accept" header + requesting "text/html". In this case, an HTML response suitable for + triggering the interaction with the wallet is returned. If the backend + installation does not include the required HTML templates, a 406 status + code is returned. + **Response:** :status 200 OK: - A tip is being returned. The backend responds with a `TipInformation` + A tip is being returned. The backend responds with a `TipInformation`. :status 404 Not Found: The tip identifier is unknown. + :status 406 Not Acceptable: + The merchant backend could not load the template required to generate a reply in the desired format. (Likely HTML templates were not properly installed.) + :status 410 Gone: + A tip has been fully claimed. The JSON reply still contains the `TipInformation`. .. ts:def:: TipInformation -- cgit v1.2.3