@friggframework/schemas 2.0.0--canary.686.821f8a3.0 → 2.0.0--canary.690.3fe2b27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@friggframework/schemas",
|
|
3
|
-
"version": "2.0.0--canary.
|
|
3
|
+
"version": "2.0.0--canary.690.3fe2b27.0",
|
|
4
4
|
"description": "Canonical JSON Schema definitions for Frigg Framework",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": "",
|
|
@@ -41,5 +41,5 @@
|
|
|
41
41
|
"middleware/",
|
|
42
42
|
"index.js"
|
|
43
43
|
],
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "3fe2b2703f10e48414396e7c9c1db8322693b4b1"
|
|
45
45
|
}
|
|
@@ -106,7 +106,12 @@
|
|
|
106
106
|
"required": ["method", "path"],
|
|
107
107
|
"properties": {
|
|
108
108
|
"method": { "type": "string", "enum": ["GET", "POST", "PUT", "PATCH", "DELETE"] },
|
|
109
|
-
"path": { "type": "string", "pattern": "^/" }
|
|
109
|
+
"path": { "type": "string", "pattern": "^/" },
|
|
110
|
+
"base": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
113
|
+
"description": "Which of the module's named bases (baseUrls) the rule applies to. Default 'default'. Must be declared by the module (checked at load)."
|
|
114
|
+
}
|
|
110
115
|
},
|
|
111
116
|
"additionalProperties": false
|
|
112
117
|
}
|
|
@@ -117,15 +122,23 @@
|
|
|
117
122
|
"items": { "type": "string" }
|
|
118
123
|
},
|
|
119
124
|
"baseUrl": {
|
|
120
|
-
"description": "Proxy base URL (https). A string, or a function of the Api instance for tenant hosts. Defaults to the Api's baseUrl.",
|
|
125
|
+
"description": "Proxy base URL (https). A string, or a function of the Api instance for tenant hosts. Means { default: baseUrl }. Defaults to the Api's baseUrl. Declare this or baseUrls, not both.",
|
|
121
126
|
"type": ["string", "object"]
|
|
122
127
|
},
|
|
128
|
+
"baseUrls": {
|
|
129
|
+
"type": "object",
|
|
130
|
+
"description": "Named proxy base URLs for a module whose API spans several hosts (ADR-052, amendment 1). The proxy request names one in `base`; omitted means 'default'. Strings only, absolute https URLs with no credentials, query or fragment (checked at load). Declare this or baseUrl, not both.",
|
|
131
|
+
"minProperties": 1,
|
|
132
|
+
"propertyNames": { "pattern": "^[a-z][a-z0-9-]*$" },
|
|
133
|
+
"additionalProperties": { "type": "string", "pattern": "^https://" }
|
|
134
|
+
},
|
|
123
135
|
"binary": {
|
|
124
136
|
"type": "boolean",
|
|
125
137
|
"default": false,
|
|
126
138
|
"description": "Return binary upstream bodies base64-encoded instead of refusing them (415)"
|
|
127
139
|
}
|
|
128
140
|
},
|
|
141
|
+
"not": { "required": ["baseUrl", "baseUrls"] },
|
|
129
142
|
"additionalProperties": false
|
|
130
143
|
},
|
|
131
144
|
"env": {
|
|
@@ -20,6 +20,11 @@
|
|
|
20
20
|
"pattern": "^/",
|
|
21
21
|
"minLength": 1
|
|
22
22
|
},
|
|
23
|
+
"base": {
|
|
24
|
+
"type": "string",
|
|
25
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
26
|
+
"description": "Name of one of the module's base URLs (ADR-052 amendment); 'default' when omitted. A name the module declares in proxy.baseUrls, never a URL or host. An unknown name is 400 PROXY_UNKNOWN_BASE; a value that is not shaped like a name is 400 INVALID_PROXY_REQUEST."
|
|
27
|
+
},
|
|
23
28
|
"query": {
|
|
24
29
|
"type": "object",
|
|
25
30
|
"description": "Query parameters to include in the request as key-value pairs",
|
|
@@ -177,6 +182,7 @@
|
|
|
177
182
|
"enum": [
|
|
178
183
|
"INVALID_PROXY_REQUEST",
|
|
179
184
|
"PROXY_NOT_ALLOWED",
|
|
185
|
+
"PROXY_UNKNOWN_BASE",
|
|
180
186
|
"PROXY_NOT_CONFIGURED",
|
|
181
187
|
"PAYLOAD_TOO_LARGE",
|
|
182
188
|
"UNSUPPORTED_MEDIA_TYPE",
|
|
@@ -883,6 +883,11 @@
|
|
|
883
883
|
"type": "string",
|
|
884
884
|
"pattern": "^/",
|
|
885
885
|
"description": "Path pattern relative to the module's base URL. `:param` matches one segment; a trailing `/**` matches a subtree."
|
|
886
|
+
},
|
|
887
|
+
"base": {
|
|
888
|
+
"type": "string",
|
|
889
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
890
|
+
"description": "Which of the module's named bases the rule applies to. Default 'default'. A base the module does not declare stops the app at load."
|
|
886
891
|
}
|
|
887
892
|
},
|
|
888
893
|
"additionalProperties": false
|