@gravitee/ui-policy-studio-angular 7.6.0 → 7.7.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/README.md +2 -3
- package/esm2020/lib/components/flow-details/gio-ps-flow-details.component.mjs +14 -7
- package/esm2020/lib/components/flow-details-info-bar/gio-ps-flow-details-info-bar.component.mjs +91 -0
- package/esm2020/lib/components/flow-details-phase/gio-ps-flow-details-phase.component.mjs +44 -0
- package/esm2020/lib/components/flow-details-phase-policy/gio-ps-flow-details-phase-policy.component.mjs +31 -0
- package/esm2020/lib/components/flow-form-dialog/flow-message-form-dialog/gio-ps-flow-message-form-dialog.component.mjs +3 -3
- package/esm2020/lib/components/flows-menu/gio-ps-flows-menu.component.mjs +9 -6
- package/esm2020/lib/gio-policy-studio.component.mjs +43 -28
- package/esm2020/lib/gio-policy-studio.model.mjs +1 -1
- package/esm2020/lib/gio-policy-studio.module.mjs +20 -4
- package/esm2020/lib/models/SaveOutput.mjs +2 -0
- package/esm2020/lib/models/index.mjs +2 -1
- package/esm2020/lib/models/plan/Plan.mjs +1 -1
- package/esm2020/testing/lib/components/flow-details/gio-ps-flow-details.harness.mjs +41 -0
- package/esm2020/testing/lib/components/flow-details-info-bar/gio-ps-flow-details-info-bar.harness.mjs +35 -0
- package/esm2020/testing/lib/components/flow-form-dialog/flow-message-form-dialog/gio-ps-flow-message-form-dialog.harness.mjs +87 -0
- package/esm2020/testing/lib/components/flow-form-dialog/flow-proxy-form-dialog/gio-ps-flow-proxy-form-dialog.harness.mjs +69 -0
- package/esm2020/testing/lib/components/flows-menu/gio-ps-flows-menu.harness.mjs +66 -0
- package/esm2020/testing/lib/gio-policy-studio.harness.mjs +105 -0
- package/esm2020/testing/lib/models/ConnectorsInfo.mjs +2 -0
- package/esm2020/testing/lib/models/SaveOutput.mjs +2 -0
- package/esm2020/testing/lib/models/flow/Flow.fixture.mjs +2 -2
- package/esm2020/testing/{testing → lib/models}/index.mjs +5 -3
- package/esm2020/testing/lib/models/plan/Plan.fixture.mjs +2 -1
- package/esm2020/testing/lib/models/plan/Plan.mjs +1 -1
- package/esm2020/testing/lib/models/plan/index.mjs +17 -0
- package/esm2020/testing/public-testing-api.mjs +2 -2
- package/fesm2015/gravitee-ui-policy-studio-angular-testing.mjs +329 -1312
- package/fesm2015/gravitee-ui-policy-studio-angular-testing.mjs.map +1 -1
- package/fesm2015/gravitee-ui-policy-studio-angular.mjs +240 -43
- package/fesm2015/gravitee-ui-policy-studio-angular.mjs.map +1 -1
- package/fesm2020/gravitee-ui-policy-studio-angular-testing.mjs +320 -1317
- package/fesm2020/gravitee-ui-policy-studio-angular-testing.mjs.map +1 -1
- package/fesm2020/gravitee-ui-policy-studio-angular.mjs +233 -43
- package/fesm2020/gravitee-ui-policy-studio-angular.mjs.map +1 -1
- package/lib/components/flow-details/gio-ps-flow-details.component.d.ts +4 -3
- package/lib/components/flow-details-info-bar/gio-ps-flow-details-info-bar.component.d.ts +16 -0
- package/lib/components/flow-details-phase/gio-ps-flow-details-phase.component.d.ts +11 -0
- package/lib/components/flow-details-phase-policy/gio-ps-flow-details-phase-policy.component.d.ts +7 -0
- package/lib/components/flows-menu/gio-ps-flows-menu.component.d.ts +1 -1
- package/lib/gio-policy-studio.component.d.ts +5 -8
- package/lib/gio-policy-studio.model.d.ts +1 -0
- package/lib/gio-policy-studio.module.d.ts +14 -10
- package/lib/models/SaveOutput.d.ts +6 -0
- package/lib/models/index.d.ts +1 -0
- package/lib/models/plan/Plan.d.ts +1 -0
- package/package.json +1 -1
- package/testing/lib/components/flow-details/gio-ps-flow-details.harness.d.ts +9 -0
- package/testing/lib/components/flow-details-info-bar/gio-ps-flow-details-info-bar.harness.d.ts +5 -0
- package/testing/lib/components/flow-form-dialog/flow-message-form-dialog/gio-ps-flow-message-form-dialog.harness.d.ts +16 -0
- package/testing/lib/components/flow-form-dialog/flow-proxy-form-dialog/gio-ps-flow-proxy-form-dialog.harness.d.ts +15 -0
- package/testing/lib/components/flows-menu/gio-ps-flows-menu.harness.d.ts +25 -0
- package/testing/lib/gio-policy-studio.harness.d.ts +34 -0
- package/testing/lib/models/ConnectorsInfo.d.ts +4 -0
- package/testing/lib/models/SaveOutput.d.ts +6 -0
- package/testing/lib/models/index.d.ts +4 -0
- package/testing/lib/models/plan/Plan.d.ts +1 -0
- package/testing/lib/models/plan/index.d.ts +1 -0
- package/testing/public-testing-api.d.ts +1 -1
- package/esm2020/testing/testing/harnesses/div.harness.mjs +0 -42
- package/esm2020/testing/testing/harnesses/index.mjs +0 -17
- package/esm2020/testing/testing/stories-resources/apim-definition.json +0 -405
- package/esm2020/testing/testing/stories-resources/apim-flow.json +0 -54
- package/esm2020/testing/testing/stories-resources/apim-policies.json +0 -486
- package/esm2020/testing/testing/stories-resources/apim-property-providers.json +0 -39
- package/esm2020/testing/testing/stories-resources/apim-resource-types.json +0 -187
- package/esm2020/testing/testing/stories-resources/index.mjs +0 -26
- package/testing/testing/harnesses/div.harness.d.ts +0 -20
- package/testing/testing/harnesses/index.d.ts +0 -1
- package/testing/testing/index.d.ts +0 -2
- package/testing/testing/stories-resources/index.d.ts +0 -592
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ComponentHarness } from '@angular/cdk/testing';
|
|
2
|
+
export declare class GioPolicyStudioFlowProxyFormDialogHarness extends ComponentHarness {
|
|
3
|
+
static hostSelector: string;
|
|
4
|
+
private getSaveBtn;
|
|
5
|
+
private getCancelBtn;
|
|
6
|
+
setFlowFormValues(flow: {
|
|
7
|
+
name?: string;
|
|
8
|
+
pathOperator?: string;
|
|
9
|
+
path?: string;
|
|
10
|
+
methods?: string[];
|
|
11
|
+
condition?: string;
|
|
12
|
+
}): Promise<void>;
|
|
13
|
+
save(): Promise<void>;
|
|
14
|
+
cancel(): Promise<void>;
|
|
15
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ComponentHarness } from '@angular/cdk/testing';
|
|
2
|
+
import { DivHarness } from '@gravitee/ui-particles-angular/testing';
|
|
3
|
+
export declare class GioPolicyStudioFlowsMenuHarness extends ComponentHarness {
|
|
4
|
+
static hostSelector: string;
|
|
5
|
+
private locateFlowsGroups;
|
|
6
|
+
private locateFlowByText;
|
|
7
|
+
locateGroupByText: (text: string | RegExp) => import("@angular/cdk/testing").AsyncFactoryFn<DivHarness | null>;
|
|
8
|
+
private locateSelectedFlow;
|
|
9
|
+
getAllFlowsGroups(): Promise<{
|
|
10
|
+
name: string | null;
|
|
11
|
+
flows: {
|
|
12
|
+
name: string | null;
|
|
13
|
+
isSelected: boolean;
|
|
14
|
+
infos: string | null;
|
|
15
|
+
}[];
|
|
16
|
+
}[]>;
|
|
17
|
+
getSelectedFlow(): Promise<{
|
|
18
|
+
name: string | null;
|
|
19
|
+
} | null>;
|
|
20
|
+
/**
|
|
21
|
+
* Select a flow by it's text content
|
|
22
|
+
*/
|
|
23
|
+
selectFlow(flowText: string | RegExp): Promise<void>;
|
|
24
|
+
addFlow(groupName: string | RegExp): Promise<void>;
|
|
25
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ComponentHarness } from '@angular/cdk/testing';
|
|
2
|
+
import { Flow } from './models';
|
|
3
|
+
export declare class GioPolicyStudioHarness extends ComponentHarness {
|
|
4
|
+
static hostSelector: string;
|
|
5
|
+
private menuHarness;
|
|
6
|
+
private detailsHarness;
|
|
7
|
+
/**
|
|
8
|
+
* Add a flow to a plan or to "Common flows"
|
|
9
|
+
*
|
|
10
|
+
* @param groupName Plan name where to add the flow. You also can define "Common flows" to add a flow to this group.
|
|
11
|
+
* @param flow Flow to add
|
|
12
|
+
*/
|
|
13
|
+
addFlow(groupName: string, flow: Flow): Promise<void>;
|
|
14
|
+
/**
|
|
15
|
+
* Edit a flow configuration
|
|
16
|
+
*
|
|
17
|
+
* @param flowName Flow name to edit
|
|
18
|
+
* @param flow
|
|
19
|
+
*/
|
|
20
|
+
editFlowConfig(flowName: string, flow: Partial<Flow>): Promise<void>;
|
|
21
|
+
deleteFlow(flowName: string): Promise<void>;
|
|
22
|
+
selectFlowInMenu(flowName: string): Promise<void>;
|
|
23
|
+
getFlowsMenu(): Promise<{
|
|
24
|
+
name: string | null;
|
|
25
|
+
flows: {
|
|
26
|
+
name: string | null;
|
|
27
|
+
isSelected: boolean;
|
|
28
|
+
infos: string | null;
|
|
29
|
+
}[];
|
|
30
|
+
}[]>;
|
|
31
|
+
getSelectedFlowInfos(): Promise<Record<string, (string | null)[]>>;
|
|
32
|
+
save(): Promise<void>;
|
|
33
|
+
private setFlowFormDialog;
|
|
34
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Plan';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export * from './lib/models/index-testing';
|
|
2
|
-
export * from './
|
|
2
|
+
export * from './lib/gio-policy-studio.harness';
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2023 The Gravitee team (http://gravitee.io)
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import { ComponentHarness, HarnessPredicate } from '@angular/cdk/testing';
|
|
17
|
-
export class DivHarness extends ComponentHarness {
|
|
18
|
-
/**
|
|
19
|
-
* Get Harness with the given filter.
|
|
20
|
-
*
|
|
21
|
-
* @param options Options for filtering which input instances are considered a match.
|
|
22
|
-
* @return a `HarnessPredicate` configured with the given options.
|
|
23
|
-
*/
|
|
24
|
-
static with(options = {}) {
|
|
25
|
-
return new HarnessPredicate(DivHarness, options).addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
|
|
26
|
-
}
|
|
27
|
-
childLocatorFor(query) {
|
|
28
|
-
return this.locatorFor(query);
|
|
29
|
-
}
|
|
30
|
-
childLocatorForAll(query) {
|
|
31
|
-
return this.locatorForAll(query);
|
|
32
|
-
}
|
|
33
|
-
async getText(option) {
|
|
34
|
-
let element = await this.host();
|
|
35
|
-
if (option?.childSelector) {
|
|
36
|
-
element = await this.locatorForOptional(option.childSelector)();
|
|
37
|
-
}
|
|
38
|
-
return element ? element.text() : null;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
DivHarness.hostSelector = 'div';
|
|
42
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGl2Lmhhcm5lc3MuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy91aS1wb2xpY3ktc3R1ZGlvLWFuZ3VsYXIvc3JjL3Rlc3RpbmcvaGFybmVzc2VzL2Rpdi5oYXJuZXNzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7Ozs7Ozs7Ozs7OztHQWNHO0FBQ0gsT0FBTyxFQUFzQyxnQkFBZ0IsRUFBRSxnQkFBZ0IsRUFBNkIsTUFBTSxzQkFBc0IsQ0FBQztBQU96SSxNQUFNLE9BQU8sVUFBVyxTQUFRLGdCQUFnQjtJQUc5Qzs7Ozs7T0FLRztJQUNJLE1BQU0sQ0FBQyxJQUFJLENBQUMsVUFBNkIsRUFBRTtRQUNoRCxPQUFPLElBQUksZ0JBQWdCLENBQUMsVUFBVSxFQUFFLE9BQU8sQ0FBQyxDQUFDLFNBQVMsQ0FBQyxNQUFNLEVBQUUsT0FBTyxDQUFDLElBQUksRUFBRSxDQUFDLE9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7XG4gIH1cblxuICBwdWJsaWMgYXN5bmMgZ2V0VGV4dChvcHRpb24/OiB7IGNoaWxkU2VsZWN0b3I/OiBzdHJpbmcgfSk6IFByb21pc2U8c3RyaW5nIHwgbnVsbD4ge1xuICAgIGxldCBlbGVtZW50OiBUZXN0RWxlbWVudCB8IG51bGwgPSBhd2FpdCB0aGlzLmhvc3QoKTtcbiAgICBpZiAob3B0aW9uPy5jaGlsZFNlbGVjdG9yKSB7XG4gICAgICBlbGVtZW50ID0gYXdhaXQgdGhpcy5sb2NhdG9yRm9yT3B0aW9uYWwob3B0aW9uLmNoaWxkU2VsZWN0b3IpKCk7XG4gICAgfVxuXG4gICAgcmV0dXJuIGVsZW1lbnQgPyBlbGVtZW50LnRleHQoKSA6IG51bGw7XG4gIH1cbn1cbiJdfQ==
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2023 The Gravitee team (http://gravitee.io)
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
export * from './div.harness';
|
|
17
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy91aS1wb2xpY3ktc3R1ZGlvLWFuZ3VsYXIvc3JjL3Rlc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0=
|
|
@@ -1,405 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "My API",
|
|
3
|
-
"version": "1",
|
|
4
|
-
"flow_mode": "BEST_MATCH",
|
|
5
|
-
"flows": [
|
|
6
|
-
{
|
|
7
|
-
"name": "All",
|
|
8
|
-
"condition": "",
|
|
9
|
-
"enabled": true,
|
|
10
|
-
"methods": ["GET", "HEAD", "POST", "PUT", "DELETE", "CONNECT", "OPTIONS", "TRACE", "PATCH"],
|
|
11
|
-
"path-operator": {
|
|
12
|
-
"path": "/",
|
|
13
|
-
"operator": "STARTS_WITH"
|
|
14
|
-
},
|
|
15
|
-
"pre": [
|
|
16
|
-
{
|
|
17
|
-
"policy": "rate-limit",
|
|
18
|
-
"name": "Rate Limit",
|
|
19
|
-
"enabled": true,
|
|
20
|
-
"description": "Step description",
|
|
21
|
-
"configuration": {
|
|
22
|
-
"rate": {
|
|
23
|
-
"limit": 10,
|
|
24
|
-
"periodTime": 1,
|
|
25
|
-
"periodTimeUnit": "MINUTES"
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
"policy": "api-key",
|
|
31
|
-
"name": "Check API Key",
|
|
32
|
-
"enabled": true,
|
|
33
|
-
"description": "Step description",
|
|
34
|
-
"configuration": {
|
|
35
|
-
"propagateApiKey": true
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
"policy": "policy-http-callout",
|
|
40
|
-
"name": "HTTP Callout",
|
|
41
|
-
"enabled": true,
|
|
42
|
-
"description": "Step description",
|
|
43
|
-
"configuration": {}
|
|
44
|
-
}
|
|
45
|
-
],
|
|
46
|
-
"post": [
|
|
47
|
-
{
|
|
48
|
-
"policy": "url-rewriting",
|
|
49
|
-
"name": "URL Rewriting",
|
|
50
|
-
"enabled": true,
|
|
51
|
-
"description": "Description of the URL Rewriting Gravitee Policy",
|
|
52
|
-
"configuration": {}
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
"policy": "xml-json",
|
|
56
|
-
"name": "XML to JSON",
|
|
57
|
-
"enabled": true,
|
|
58
|
-
"description": "Step description",
|
|
59
|
-
"configuration": {}
|
|
60
|
-
}
|
|
61
|
-
]
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
"name": "",
|
|
65
|
-
"path-operator": {
|
|
66
|
-
"path": "/products",
|
|
67
|
-
"operator": "EQUALS"
|
|
68
|
-
},
|
|
69
|
-
"enabled": false,
|
|
70
|
-
"methods": ["POST", "PUT"],
|
|
71
|
-
"condition": "",
|
|
72
|
-
"pre": [
|
|
73
|
-
{
|
|
74
|
-
"policy": "xml-json",
|
|
75
|
-
"name": "XML to JSON",
|
|
76
|
-
"enabled": true,
|
|
77
|
-
"description": "Step description",
|
|
78
|
-
"configuration": {}
|
|
79
|
-
}
|
|
80
|
-
],
|
|
81
|
-
"post": [
|
|
82
|
-
{
|
|
83
|
-
"policy": "json-to-xml",
|
|
84
|
-
"name": "JSON to XML",
|
|
85
|
-
"enabled": true,
|
|
86
|
-
"description": "Step description",
|
|
87
|
-
"configuration": {}
|
|
88
|
-
}
|
|
89
|
-
]
|
|
90
|
-
},
|
|
91
|
-
{
|
|
92
|
-
"name": "",
|
|
93
|
-
"path-operator": {
|
|
94
|
-
"path": "/products",
|
|
95
|
-
"operator": "STARTS_WITH"
|
|
96
|
-
},
|
|
97
|
-
"enabled": true,
|
|
98
|
-
"methods": ["GET"],
|
|
99
|
-
"condition": "",
|
|
100
|
-
"pre": [
|
|
101
|
-
{
|
|
102
|
-
"policy": "transform-queryparams",
|
|
103
|
-
"name": "Transform Query Parameters",
|
|
104
|
-
"description": "Description of the Transform Query Parameters Policy",
|
|
105
|
-
"enabled": true,
|
|
106
|
-
"configuration": {}
|
|
107
|
-
},
|
|
108
|
-
{
|
|
109
|
-
"policy": "url-rewriting",
|
|
110
|
-
"name": "URL Rewriting",
|
|
111
|
-
"enabled": true,
|
|
112
|
-
"description": "Description of the URL Rewriting Gravitee Policy",
|
|
113
|
-
"configuration": {}
|
|
114
|
-
}
|
|
115
|
-
],
|
|
116
|
-
"post": [
|
|
117
|
-
{
|
|
118
|
-
"policy": "json-to-xml",
|
|
119
|
-
"name": "JSON to XML",
|
|
120
|
-
"enabled": true,
|
|
121
|
-
"description": "Step description",
|
|
122
|
-
"configuration": {}
|
|
123
|
-
}
|
|
124
|
-
]
|
|
125
|
-
}
|
|
126
|
-
],
|
|
127
|
-
"plans": [
|
|
128
|
-
{
|
|
129
|
-
"id": "p-1",
|
|
130
|
-
"name": "Free plan",
|
|
131
|
-
"flows": [
|
|
132
|
-
{
|
|
133
|
-
"name": "All",
|
|
134
|
-
"enabled": true,
|
|
135
|
-
"methods": ["GET", "HEAD", "POST", "PUT", "DELETE", "CONNECT", "OPTIONS", "TRACE", "PATCH"],
|
|
136
|
-
"path-operator": {
|
|
137
|
-
"path": "/",
|
|
138
|
-
"operator": "STARTS_WITH"
|
|
139
|
-
},
|
|
140
|
-
"condition": "",
|
|
141
|
-
"pre": [
|
|
142
|
-
{
|
|
143
|
-
"policy": "rate-limit",
|
|
144
|
-
"name": "Rate Limit",
|
|
145
|
-
"enabled": true,
|
|
146
|
-
"description": "Step description",
|
|
147
|
-
"configuration": {
|
|
148
|
-
"rate": {
|
|
149
|
-
"limit": 10,
|
|
150
|
-
"periodTime": 1,
|
|
151
|
-
"periodTimeUnit": "MINUTES"
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
},
|
|
155
|
-
{
|
|
156
|
-
"policy": "api-key",
|
|
157
|
-
"name": "Check API Key",
|
|
158
|
-
"enabled": true,
|
|
159
|
-
"description": "Step description",
|
|
160
|
-
"configuration": {
|
|
161
|
-
"propagateApiKey": true
|
|
162
|
-
}
|
|
163
|
-
},
|
|
164
|
-
{
|
|
165
|
-
"policy": "transform-headers",
|
|
166
|
-
"name": "Add HTTP headers",
|
|
167
|
-
"enabled": true,
|
|
168
|
-
"description": "Step description",
|
|
169
|
-
"configuration": {
|
|
170
|
-
"add-headers": "...."
|
|
171
|
-
}
|
|
172
|
-
}
|
|
173
|
-
],
|
|
174
|
-
"post": [
|
|
175
|
-
{
|
|
176
|
-
"policy": "url-rewriting",
|
|
177
|
-
"name": "URL Rewriting",
|
|
178
|
-
"enabled": true,
|
|
179
|
-
"description": "Description of the URL Rewriting Gravitee Policy",
|
|
180
|
-
"configuration": {}
|
|
181
|
-
},
|
|
182
|
-
{
|
|
183
|
-
"policy": "xml-json",
|
|
184
|
-
"name": "XML to JSON",
|
|
185
|
-
"enabled": true,
|
|
186
|
-
"description": "Step description",
|
|
187
|
-
"configuration": {}
|
|
188
|
-
}
|
|
189
|
-
]
|
|
190
|
-
},
|
|
191
|
-
{
|
|
192
|
-
"name": "",
|
|
193
|
-
"path-operator": {
|
|
194
|
-
"path": "/free",
|
|
195
|
-
"operator": "STARTS_WITH"
|
|
196
|
-
},
|
|
197
|
-
"enabled": true,
|
|
198
|
-
"methods": ["POST", "PUT"],
|
|
199
|
-
"condition": "",
|
|
200
|
-
"pre": [
|
|
201
|
-
{
|
|
202
|
-
"policy": "xml-json",
|
|
203
|
-
"name": "XML to JSON",
|
|
204
|
-
"enabled": true,
|
|
205
|
-
"description": "Step description",
|
|
206
|
-
"configuration": {}
|
|
207
|
-
}
|
|
208
|
-
],
|
|
209
|
-
"post": [
|
|
210
|
-
{
|
|
211
|
-
"policy": "json-to-xml",
|
|
212
|
-
"name": "JSON to XML",
|
|
213
|
-
"enabled": true,
|
|
214
|
-
"description": "Step description",
|
|
215
|
-
"configuration": {}
|
|
216
|
-
}
|
|
217
|
-
]
|
|
218
|
-
},
|
|
219
|
-
{
|
|
220
|
-
"name": "",
|
|
221
|
-
"path-operator": {
|
|
222
|
-
"path": "/free",
|
|
223
|
-
"operator": "EQUALS"
|
|
224
|
-
},
|
|
225
|
-
"enabled": true,
|
|
226
|
-
"methods": ["GET"],
|
|
227
|
-
"condition": "",
|
|
228
|
-
"pre": [
|
|
229
|
-
{
|
|
230
|
-
"policy": "transform-queryparams",
|
|
231
|
-
"name": "Transform Query Parameters",
|
|
232
|
-
"enabled": true,
|
|
233
|
-
"description": "Description of the Transform Query Parameters Policy",
|
|
234
|
-
"configuration": {}
|
|
235
|
-
},
|
|
236
|
-
{
|
|
237
|
-
"policy": "url-rewriting",
|
|
238
|
-
"name": "URL Rewriting",
|
|
239
|
-
"enabled": true,
|
|
240
|
-
"description": "Description of the URL Rewriting Gravitee Policy",
|
|
241
|
-
"configuration": {}
|
|
242
|
-
}
|
|
243
|
-
],
|
|
244
|
-
"post": [
|
|
245
|
-
{
|
|
246
|
-
"policy": "json-to-xml",
|
|
247
|
-
"name": "JSON to XML",
|
|
248
|
-
"enabled": true,
|
|
249
|
-
"description": "Step description",
|
|
250
|
-
"configuration": {}
|
|
251
|
-
}
|
|
252
|
-
]
|
|
253
|
-
}
|
|
254
|
-
]
|
|
255
|
-
},
|
|
256
|
-
{
|
|
257
|
-
"id": "p-2",
|
|
258
|
-
"name": "Premium plan",
|
|
259
|
-
"flows": [
|
|
260
|
-
{
|
|
261
|
-
"name": "",
|
|
262
|
-
"path-operator": {
|
|
263
|
-
"path": "/premium",
|
|
264
|
-
"operator": "STARTS_WITH"
|
|
265
|
-
},
|
|
266
|
-
"methods": [],
|
|
267
|
-
"condition": "",
|
|
268
|
-
"enabled": true,
|
|
269
|
-
"pre": [
|
|
270
|
-
{
|
|
271
|
-
"policy": "rate-limit",
|
|
272
|
-
"name": "Rate Limit",
|
|
273
|
-
"enabled": true,
|
|
274
|
-
"description": "Step description",
|
|
275
|
-
"configuration": {
|
|
276
|
-
"rate": {
|
|
277
|
-
"limit": 10,
|
|
278
|
-
"periodTime": 1,
|
|
279
|
-
"periodTimeUnit": "MINUTES"
|
|
280
|
-
}
|
|
281
|
-
}
|
|
282
|
-
},
|
|
283
|
-
{
|
|
284
|
-
"policy": "api-key",
|
|
285
|
-
"name": "Check API Key",
|
|
286
|
-
"enabled": true,
|
|
287
|
-
"description": "Step description",
|
|
288
|
-
"configuration": {
|
|
289
|
-
"propagateApiKey": true
|
|
290
|
-
}
|
|
291
|
-
},
|
|
292
|
-
{
|
|
293
|
-
"policy": "transform-headers",
|
|
294
|
-
"name": "Add HTTP headers",
|
|
295
|
-
"enabled": true,
|
|
296
|
-
"description": "Step description",
|
|
297
|
-
"configuration": {
|
|
298
|
-
"add-headers": "...."
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
],
|
|
302
|
-
"post": [
|
|
303
|
-
{
|
|
304
|
-
"policy": "url-rewriting",
|
|
305
|
-
"name": "URL Rewriting",
|
|
306
|
-
"enabled": true,
|
|
307
|
-
"description": "Description of the URL Rewriting Gravitee Policy",
|
|
308
|
-
"configuration": {}
|
|
309
|
-
},
|
|
310
|
-
{
|
|
311
|
-
"policy": "xml-json",
|
|
312
|
-
"name": "XML to JSON",
|
|
313
|
-
"enabled": true,
|
|
314
|
-
"description": "Step description",
|
|
315
|
-
"configuration": {}
|
|
316
|
-
}
|
|
317
|
-
]
|
|
318
|
-
},
|
|
319
|
-
{
|
|
320
|
-
"name": "Api 1",
|
|
321
|
-
"enabled": true,
|
|
322
|
-
"methods": ["POST", "PUT"],
|
|
323
|
-
"condition": "",
|
|
324
|
-
"pre": [
|
|
325
|
-
{
|
|
326
|
-
"policy": "xml-json",
|
|
327
|
-
"name": "XML to JSON",
|
|
328
|
-
"enabled": true,
|
|
329
|
-
"description": "Step description",
|
|
330
|
-
"configuration": {}
|
|
331
|
-
}
|
|
332
|
-
],
|
|
333
|
-
"post": [
|
|
334
|
-
{
|
|
335
|
-
"policy": "json-to-xml",
|
|
336
|
-
"name": "JSON to XML",
|
|
337
|
-
"enabled": true,
|
|
338
|
-
"description": "Step description",
|
|
339
|
-
"configuration": {}
|
|
340
|
-
}
|
|
341
|
-
]
|
|
342
|
-
},
|
|
343
|
-
{
|
|
344
|
-
"name": "Api 2",
|
|
345
|
-
"enabled": true,
|
|
346
|
-
"methods": ["GET"],
|
|
347
|
-
"condition": "",
|
|
348
|
-
"pre": [
|
|
349
|
-
{
|
|
350
|
-
"policy": "transform-queryparams",
|
|
351
|
-
"name": "Transform Query Parameters",
|
|
352
|
-
"enabled": true,
|
|
353
|
-
"description": "Description of the Transform Query Parameters Policy",
|
|
354
|
-
"configuration": {}
|
|
355
|
-
},
|
|
356
|
-
{
|
|
357
|
-
"policy": "url-rewriting",
|
|
358
|
-
"name": "URL Rewriting",
|
|
359
|
-
"enabled": true,
|
|
360
|
-
"description": "Description of the URL Rewriting Gravitee Policy",
|
|
361
|
-
"configuration": {}
|
|
362
|
-
}
|
|
363
|
-
],
|
|
364
|
-
"post": [
|
|
365
|
-
{
|
|
366
|
-
"policy": "json-to-xml",
|
|
367
|
-
"name": "JSON to XML",
|
|
368
|
-
"enabled": true,
|
|
369
|
-
"description": "Step description",
|
|
370
|
-
"configuration": {}
|
|
371
|
-
}
|
|
372
|
-
]
|
|
373
|
-
}
|
|
374
|
-
]
|
|
375
|
-
}
|
|
376
|
-
],
|
|
377
|
-
"resources": [
|
|
378
|
-
{
|
|
379
|
-
"type": "cache",
|
|
380
|
-
"enabled": true,
|
|
381
|
-
"name": "my-cache",
|
|
382
|
-
"configuration": {
|
|
383
|
-
"timeToIdleSeconds": 0,
|
|
384
|
-
"timeToLiveSeconds": 0,
|
|
385
|
-
"maxEntriesLocalHeap": 1000
|
|
386
|
-
}
|
|
387
|
-
}
|
|
388
|
-
],
|
|
389
|
-
"properties": [
|
|
390
|
-
{
|
|
391
|
-
"key": "property.1",
|
|
392
|
-
"value": "Value 1"
|
|
393
|
-
},
|
|
394
|
-
{
|
|
395
|
-
"key": "property.2",
|
|
396
|
-
"value": "Value 2",
|
|
397
|
-
"encryptable": true,
|
|
398
|
-
"encrypted": true
|
|
399
|
-
},
|
|
400
|
-
{
|
|
401
|
-
"key": "property.3",
|
|
402
|
-
"value": "Value 3"
|
|
403
|
-
}
|
|
404
|
-
]
|
|
405
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"type": "object",
|
|
3
|
-
"id": "apim",
|
|
4
|
-
"properties": {
|
|
5
|
-
"name": {
|
|
6
|
-
"title": "Name",
|
|
7
|
-
"description": "The name of flow. If empty, the name will be generated with the path and methods",
|
|
8
|
-
"type": "string"
|
|
9
|
-
},
|
|
10
|
-
"path-operator": {
|
|
11
|
-
"type": "object",
|
|
12
|
-
"title": "Path",
|
|
13
|
-
"properties": {
|
|
14
|
-
"operator": {
|
|
15
|
-
"title": "Operator path",
|
|
16
|
-
"description": "The operator path",
|
|
17
|
-
"type": "string",
|
|
18
|
-
"enum": ["EQUALS", "STARTS_WITH"],
|
|
19
|
-
"default": "STARTS_WITH",
|
|
20
|
-
"x-schema-form": {
|
|
21
|
-
"titleMap": {
|
|
22
|
-
"EQUALS": "Equals",
|
|
23
|
-
"STARTS_WITH": "Starts with"
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
},
|
|
27
|
-
"path": {
|
|
28
|
-
"title": "Path",
|
|
29
|
-
"description": "The path of flow (must start by /)",
|
|
30
|
-
"type": "string",
|
|
31
|
-
"pattern": "^/",
|
|
32
|
-
"default": "/"
|
|
33
|
-
}
|
|
34
|
-
},
|
|
35
|
-
"required": ["path", "operator"]
|
|
36
|
-
},
|
|
37
|
-
"methods": {
|
|
38
|
-
"title": "Methods",
|
|
39
|
-
"description": "The HTTP methods of flow (ALL if empty)",
|
|
40
|
-
"type": "array",
|
|
41
|
-
"items": {
|
|
42
|
-
"type": "string",
|
|
43
|
-
"enum": ["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"]
|
|
44
|
-
}
|
|
45
|
-
},
|
|
46
|
-
"condition": {
|
|
47
|
-
"title": "Condition",
|
|
48
|
-
"description": "The extra condition of flow",
|
|
49
|
-
"type": "string"
|
|
50
|
-
}
|
|
51
|
-
},
|
|
52
|
-
"required": [],
|
|
53
|
-
"disabled": []
|
|
54
|
-
}
|