forked from wikimedia/restbase
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest_module.yaml
49 lines (46 loc) · 1.12 KB
/
test_module.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
openapi: 3.0.1
info:
version: 1.0.0-beta
title: Wikimedia testing APIs
x-is-api-root: true
paths:
/post_data/:
post:
x-route-filters:
- type: 'default'
name: 'header_match'
options:
whitelist:
x-client-ip:
- /^(?:::ffff:)?(?:10|127)\./
x-request-handler:
- put_to_storage:
request:
method: put
uri: /{domain}/sys/post_data/post.test/
headers: '{{request.headers}}'
body: '{{request.body}}'
x-monitor: false
/post_data/{hash}:
get:
x-setup-handler:
- init_storage:
uri: /{domain}/sys/post_data/post.test
x-request-handler:
- get_from_storage:
request:
uri: /{domain}/sys/post_data/post.test/{hash}
x-monitor: false
/events_no_config:
x-modules:
- path: sys/events.js
/events:
x-modules:
- path: sys/events.js
options: '{{options.events}}'
/http/{uri}:
get:
x-request-handler:
- request_url:
request:
uri: '{{uri}}'