From 610eb5c9076a7fa5495fb4b4ce7ff0aad11f5bee Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Fri, 4 Dec 2020 04:36:55 -0500 Subject: use ‘.. code-block:: python’ (six instances) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- taler-merchant-api-tutorial.rst | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'taler-merchant-api-tutorial.rst') diff --git a/taler-merchant-api-tutorial.rst b/taler-merchant-api-tutorial.rst index 33e0f8e5..2070a943 100644 --- a/taler-merchant-api-tutorial.rst +++ b/taler-merchant-api-tutorial.rst @@ -127,7 +127,7 @@ The public sandbox backend https://backend.demo.taler.net/ uses an API key in the ``Authorization`` header. The value of this header must be ``ApiKey sandbox`` for the public sandbox backend. -:: +.. code-block:: python >>> import requests >>> requests.get("https://backend.demo.taler.net", @@ -217,7 +217,7 @@ manual for details. A minimal Python snippet for creating an order would look like this: -:: +.. code-block:: python >>> import requests >>> body = dict(order=dict(amount="KUDOS:10", @@ -278,7 +278,7 @@ status of the payment, even if you know that the user did not pay yet. There are a few corner cases to consider when constructing this URL, so asking the backend to do it is the safest method. -:: +.. code-block:: python >>> import requests >>> r = requests.get("https://backend.demo.taler.net/private/orders/" + order_id, @@ -343,7 +343,7 @@ by the wallet. This code snipped illustrates giving a refund: -:: +.. code-block:: python >>> import requests >>> refund_req = dict(refund="KUDOS:10", @@ -435,7 +435,7 @@ Taler Merchant Operating Manual. To check if tipping is configured properly and if there are sufficient funds available for tipping, query the ``/tip-query`` endpoint: -:: +.. code-block:: python >>> import requests >>> requests.get("https://backend.demo.taler.net/tip-query?instance=default", @@ -463,7 +463,7 @@ up the tip. pick up tip This code snipped illustrates giving a tip: -:: +.. code-block:: python >>> import requests >>> tip_req = dict(amount="KUDOS:0.5", -- cgit v1.2.3