-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathpolicies.json
68 lines (68 loc) · 1.62 KB
/
policies.json
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
{
"policies": [
{
"handler": {
"export": "RequestValidationInboundPolicy",
"module": "$import(@zuplo/runtime)",
"options": {
"logLevel": "info",
"validateBody": "reject-and-log",
"includeRequestInLogs": false
}
},
"name": "request-validation-inbound",
"policyType": "request-validation-inbound"
},
{
"handler": {
"export": "CachingInboundPolicy",
"module": "$import(@zuplo/runtime)",
"options": {
"expirationSecondsTtl": 60,
"headers": [
"accept"
]
}
},
"name": "caching-inbound",
"policyType": "caching-inbound"
},
{
"handler": {
"export": "RateLimitInboundPolicy",
"module": "$import(@zuplo/runtime)",
"options": {
"rateLimitBy": "ip",
"requestsAllowed": 500,
"timeWindowMinutes": 0.02
}
},
"name": "rate-limit-inbound",
"policyType": "rate-limit-inbound"
},
{
"handler": {
"export": "default",
"module": "$import(./modules/log-request)"
},
"name": "log-request",
"policyType": "custom-code-inbound"
},
{
"handler": {
"export": "default",
"module": "$import(./modules/blocked)"
},
"name": "block-bad-bins",
"policyType": "custom-code-inbound"
},
{
"handler": {
"export": "default",
"module": "$import(./modules/add-server-to-openapi)"
},
"name": "custom-code-outbound",
"policyType": "custom-code-outbound"
}
]
}