summaryrefslogtreecommitdiff
path: root/subplot/server.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'subplot/server.yaml')
-rw-r--r--subplot/server.yaml10
1 files changed, 10 insertions, 0 deletions
diff --git a/subplot/server.yaml b/subplot/server.yaml
index ac45cac..cf57931 100644
--- a/subplot/server.yaml
+++ b/subplot/server.yaml
@@ -17,6 +17,11 @@
- when: "I POST (?P<filename>\\S+) to (?P<path>\\S+), with (?P<header>\\S+): (?P<json>.*)"
regex: true
+ types:
+ filename: word
+ path: word
+ header: word
+ json: text
impl:
python:
function: post_file
@@ -63,12 +68,17 @@
function: header_is
- then: "the JSON body has a field {field}, henceforth {var}"
+ types:
+ field: word
+ var: word
impl:
python:
function: remember_json_field
- then: "the JSON body matches (?P<wanted>.*)"
regex: true
+ types:
+ wanted: text
impl:
python:
function: json_body_matches