summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2022-09-24 17:20:04 +0200
committerChristian Grothoff <christian@grothoff.org>2022-09-24 17:25:26 +0200
commite9d5f9c669acb4c480bdf5a0575374a693fb011b (patch)
tree29e75de0c26d59b5d6584b1f3fd72c0dbf2afad6
parent00609057f29f4335f3028e057c1425a4ef003db7 (diff)
downloaddocs-e9d5f9c669acb4c480bdf5a0575374a693fb011b.tar.gz
docs-e9d5f9c669acb4c480bdf5a0575374a693fb011b.tar.bz2
docs-e9d5f9c669acb4c480bdf5a0575374a693fb011b.zip
fix secret-token
-rw-r--r--taler-merchant-api-tutorial.rst12
1 files changed, 6 insertions, 6 deletions
diff --git a/taler-merchant-api-tutorial.rst b/taler-merchant-api-tutorial.rst
index c66e701b..d45ed4fa 100644
--- a/taler-merchant-api-tutorial.rst
+++ b/taler-merchant-api-tutorial.rst
@@ -131,7 +131,7 @@ key in the ``Authorization`` header. The value of this header must be
>>> import requests
>>> requests.get("https://backend.demo.taler.net",
- ... headers={"Authorization": "ApiKey sandbox"})
+ ... headers={"Authorization": "secret-token:secret"})
<Response [200]>
If an HTTP status code other than 200 is returned, something went wrong.
@@ -226,7 +226,7 @@ A minimal Python snippet for creating an order would look like this:
... create_token=false)
>>> response = requests.post("https://backend.demo.taler.net/private/orders",
... json=body,
- ... headers={"Authorization": "ApiKey sandbox"})
+ ... headers={"Authorization": "secret-token:secret"})
<Response [200]>
@@ -282,7 +282,7 @@ backend to do it is the safest method.
>>> import requests
>>> r = requests.get("https://backend.demo.taler.net/private/orders/" + order_id,
- ... headers={"Authorization": "ApiKey sandbox"})
+ ... headers={"Authorization": "secret-token:secret"})
>>> print(r.json())
If the ``order_status`` field in the response is ``paid``, you will not
@@ -350,7 +350,7 @@ This code snipped illustrates giving a refund:
... reason="Customer did not like the product")
>>> requests.post("https://backend.demo.taler.net/private/orders/"
... + order_id + "/refund", json=refund_req,
- ... headers={"Authorization": "ApiKey sandbox"})
+ ... headers={"Authorization": "secret-token:secret"})
<Response [200]>
.. Note::
@@ -439,7 +439,7 @@ funds available for tipping, query the ``/tip-query`` endpoint:
>>> import requests
>>> requests.get("https://backend.demo.taler.net/tip-query?instance=default",
- ... headers={"Authorization": "ApiKey sandbox"})
+ ... headers={"Authorization": "secret-token:secret"})
<Response [200]>
.. _authorize-tip:
@@ -474,7 +474,7 @@ This code snipped illustrates giving a tip:
... justification="User filled out survey",
... next_url="https://merchant.com/thanks.html")
>>> requests.post("https://backend.demo.taler.net/tip-authorize", json=tip_req,
- ... headers={"Authorization": "ApiKey sandbox"})
+ ... headers={"Authorization": "secret-token:secret"})
<Response [200]>
.. _Advanced-topics: