doc: drop mentions to .pow files ($deity REST their soul)

Co-authored-by: Roberto Abdelkader Martínez Pérez <robertomartinezp@gmail.com>
This commit is contained in:
pancho horrillo
2020-12-24 13:30:23 +01:00
parent e72c65c859
commit 26fa12c871
31 changed files with 159 additions and 146 deletions
+5 -3
View File
@@ -16,12 +16,13 @@ Example #1
++++++++++
In this example our *Kapow!* service will receive a `JSON` value with an incorrect
date, then our ``pow`` file will fix it and return the correct value to the user.
date, then our init program will fix it and return the correct value to the user.
.. code-block:: console
:linenos:
$ cat fix_date.pow
$ cat fix_date
#!/usr/bin/env sh
kapow route add -X POST /fix-date - <<-'EOF'
kapow set /response/headers/Content-Type application/json
kapow get /request/body | jq --arg newdate "$(date +'%Y-%m-%d_%H-%M-%S')" '.incorrectDate=$newdate' | kapow set /response/body
@@ -46,7 +47,8 @@ order to generate a two-attribute `JSON` response.
.. code-block:: console
$ cat echo-attribute.pow
$ cat echo-attribute
#!/usr/bin/env sh
kapow route add -X POST /echo-attribute - <<-'EOF'
JSON_WHO=$(kapow get /request/body | jq -r .name)