@forge/runtime 6.0.0-next.0 → 6.0.0-next.1
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/CHANGELOG.md +6 -0
- package/out/index.d.ts +1 -25
- package/out/index.d.ts.map +1 -1
- package/out/index.js +1 -37
- package/out/request.d.ts +91 -338
- package/out/request.d.ts.map +1 -1
- package/out/request.js +0 -130
- package/out/result.d.ts +1 -2
- package/out/result.d.ts.map +1 -1
- package/out/sandbox/index.d.ts +0 -2
- package/out/sandbox/index.d.ts.map +1 -1
- package/out/sandbox/index.js +0 -2
- package/out/sandbox/invocation-event.d.ts +7 -49
- package/out/sandbox/invocation-event.d.ts.map +1 -1
- package/out/sandbox/invocation-event.js +9 -50
- package/out/sandbox/sandbox.d.ts +2 -10
- package/out/sandbox/sandbox.d.ts.map +1 -1
- package/package.json +2 -34
- package/out/app-manifest.d.ts +0 -71
- package/out/app-manifest.d.ts.map +0 -1
- package/out/app-manifest.js +0 -83
- package/out/config.d.ts +0 -6
- package/out/config.d.ts.map +0 -1
- package/out/config.js +0 -2
- package/out/context.d.ts +0 -37
- package/out/context.d.ts.map +0 -1
- package/out/context.js +0 -48
- package/out/feature-flag.d.ts +0 -15
- package/out/feature-flag.d.ts.map +0 -1
- package/out/feature-flag.js +0 -23
- package/out/limits/index.d.ts +0 -2
- package/out/limits/index.d.ts.map +0 -1
- package/out/limits/index.js +0 -4
- package/out/limits/tracker.d.ts +0 -30
- package/out/limits/tracker.d.ts.map +0 -1
- package/out/limits/tracker.js +0 -34
- package/out/logger.d.ts +0 -65
- package/out/logger.d.ts.map +0 -1
- package/out/logger.js +0 -19
- package/out/metrics/index.d.ts +0 -2
- package/out/metrics/index.d.ts.map +0 -1
- package/out/metrics/index.js +0 -4
- package/out/metrics/metrics.d.ts +0 -29
- package/out/metrics/metrics.d.ts.map +0 -1
- package/out/metrics/metrics.js +0 -78
- package/out/sandbox/inspector.d.ts +0 -39
- package/out/sandbox/inspector.d.ts.map +0 -1
- package/out/sandbox/inspector.js +0 -258
- package/out/sandbox/invocation-request.d.ts +0 -114
- package/out/sandbox/invocation-request.d.ts.map +0 -1
- package/out/sandbox/invocation-request.js +0 -271
- package/out/snapshot.d.ts +0 -16
- package/out/snapshot.d.ts.map +0 -1
- package/out/snapshot.js +0 -6
package/CHANGELOG.md
CHANGED
package/out/index.d.ts
CHANGED
|
@@ -1,30 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { InvocationResult } from './result';
|
|
3
|
-
import { Sandbox } from './sandbox';
|
|
4
|
-
import { Inspector } from './sandbox/inspector';
|
|
5
|
-
import { LimitsTracker } from './limits';
|
|
6
|
-
import { XenInvocationRequest } from './sandbox/invocation-request';
|
|
7
|
-
export * from './app-manifest';
|
|
8
|
-
export * from './config';
|
|
9
|
-
export * from './context';
|
|
10
|
-
export * from './feature-flag';
|
|
11
|
-
export * from './metrics';
|
|
1
|
+
import { ExternalRequestVariable } from './request';
|
|
12
2
|
export * from './request';
|
|
13
3
|
export * from './result';
|
|
14
|
-
export * from './snapshot';
|
|
15
|
-
export * from './limits';
|
|
16
|
-
export * from './logger';
|
|
17
4
|
export * from './sandbox';
|
|
18
|
-
export declare function initializeInspector(): Inspector;
|
|
19
5
|
export declare function getUserVars(): ExternalRequestVariable[];
|
|
20
|
-
export interface InvocationConfig {
|
|
21
|
-
sandbox: Sandbox;
|
|
22
|
-
xenInvocationRequest: XenInvocationRequest;
|
|
23
|
-
invocationLimits: LimitsTracker;
|
|
24
|
-
inspector?: Inspector;
|
|
25
|
-
}
|
|
26
|
-
export declare class InvocationValidationError extends Error {
|
|
27
|
-
}
|
|
28
|
-
export declare function validateInvocation(invocation: unknown): ExternalRequestBody;
|
|
29
|
-
export declare function invoke(invocation: InvocationConfig): Promise<InvocationResult>;
|
|
30
6
|
//# sourceMappingURL=index.d.ts.map
|
package/out/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,WAAW,CAAC;AAEpD,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAE1B,wBAAgB,WAAW,IAAI,uBAAuB,EAAE,CAevD"}
|
package/out/index.js
CHANGED
|
@@ -1,26 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.getUserVars = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
|
-
const Either_1 = require("fp-ts/lib/Either");
|
|
6
|
-
const io_ts_reporters_1 = tslib_1.__importDefault(require("io-ts-reporters"));
|
|
7
|
-
const request_1 = require("./request");
|
|
8
|
-
const inspector_1 = require("./sandbox/inspector");
|
|
9
|
-
tslib_1.__exportStar(require("./app-manifest"), exports);
|
|
10
|
-
tslib_1.__exportStar(require("./config"), exports);
|
|
11
|
-
tslib_1.__exportStar(require("./context"), exports);
|
|
12
|
-
tslib_1.__exportStar(require("./feature-flag"), exports);
|
|
13
|
-
tslib_1.__exportStar(require("./metrics"), exports);
|
|
14
5
|
tslib_1.__exportStar(require("./request"), exports);
|
|
15
6
|
tslib_1.__exportStar(require("./result"), exports);
|
|
16
|
-
tslib_1.__exportStar(require("./snapshot"), exports);
|
|
17
|
-
tslib_1.__exportStar(require("./limits"), exports);
|
|
18
|
-
tslib_1.__exportStar(require("./logger"), exports);
|
|
19
7
|
tslib_1.__exportStar(require("./sandbox"), exports);
|
|
20
|
-
function initializeInspector() {
|
|
21
|
-
return new inspector_1.ChromeInspector();
|
|
22
|
-
}
|
|
23
|
-
exports.initializeInspector = initializeInspector;
|
|
24
8
|
function getUserVars() {
|
|
25
9
|
const prefix = 'FORGE_USER_VAR_';
|
|
26
10
|
const envKeys = Object.keys(process.env);
|
|
@@ -36,23 +20,3 @@ function getUserVars() {
|
|
|
36
20
|
}, []);
|
|
37
21
|
}
|
|
38
22
|
exports.getUserVars = getUserVars;
|
|
39
|
-
class InvocationValidationError extends Error {
|
|
40
|
-
}
|
|
41
|
-
exports.InvocationValidationError = InvocationValidationError;
|
|
42
|
-
function failedInvocationMessage(validationResult) {
|
|
43
|
-
return ['Invocation validation failed:', ...io_ts_reporters_1.default.report(validationResult)].join('\n');
|
|
44
|
-
}
|
|
45
|
-
function validateInvocation(invocation) {
|
|
46
|
-
const validationResult = request_1.ExternalRequestBodyType.decode(invocation);
|
|
47
|
-
if ((0, Either_1.isLeft)(validationResult)) {
|
|
48
|
-
throw new InvocationValidationError(failedInvocationMessage(validationResult));
|
|
49
|
-
}
|
|
50
|
-
else {
|
|
51
|
-
return validationResult.right;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
exports.validateInvocation = validateInvocation;
|
|
55
|
-
function invoke(invocation) {
|
|
56
|
-
return invocation.sandbox.execute(invocation.xenInvocationRequest, invocation.invocationLimits, invocation.inspector);
|
|
57
|
-
}
|
|
58
|
-
exports.invoke = invoke;
|
package/out/request.d.ts
CHANGED
|
@@ -1,340 +1,93 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
externalAccountId:
|
|
8
|
-
displayName:
|
|
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
|
-
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
ccpEntitlementId: t.UnionC<[t.StringC, t.NullC]>;
|
|
93
|
-
ccpEntitlementSlug: t.UnionC<[t.StringC, t.NullC]>;
|
|
94
|
-
isEvaluation: t.UnionC<[t.BooleanC, t.NullC]>;
|
|
95
|
-
subscriptionEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
96
|
-
supportEntitlementNumber: t.UnionC<[t.StringC, t.NullC]>;
|
|
97
|
-
trialEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
98
|
-
type: t.UnionC<[t.StringC, t.NullC]>;
|
|
99
|
-
}>]>;
|
|
100
|
-
fetchAllowList: t.ArrayC<t.StringC>;
|
|
101
|
-
externalAuth: t.ArrayC<t.TypeC<{
|
|
102
|
-
service: t.StringC;
|
|
103
|
-
remotes: t.ArrayC<t.TypeC<{
|
|
104
|
-
baseUrl: t.StringC;
|
|
105
|
-
key: t.StringC;
|
|
106
|
-
}>>;
|
|
107
|
-
accounts: t.ArrayC<t.IntersectionC<[t.TypeC<{
|
|
108
|
-
id: t.StringC;
|
|
109
|
-
externalAccountId: t.StringC;
|
|
110
|
-
displayName: t.StringC;
|
|
111
|
-
scopes: t.ArrayC<t.StringC>;
|
|
112
|
-
}>, t.PartialC<{
|
|
113
|
-
avatarUrl: t.StringC;
|
|
114
|
-
}>]>>;
|
|
115
|
-
}>>;
|
|
116
|
-
}>]>;
|
|
117
|
-
declare const VariableType: t.TypeC<{
|
|
118
|
-
secure: t.BooleanC;
|
|
119
|
-
key: t.StringC;
|
|
120
|
-
value: t.UnionC<[t.StringC, t.UndefinedC]>;
|
|
121
|
-
}>;
|
|
122
|
-
export declare const ExternalRequestBodyType: t.IntersectionC<[t.TypeC<{
|
|
123
|
-
_meta: t.IntersectionC<[t.TypeC<{
|
|
124
|
-
apiAuth: t.TypeC<{
|
|
125
|
-
env: t.StringC;
|
|
126
|
-
objects: t.StringC;
|
|
127
|
-
}>;
|
|
128
|
-
clientId: t.StringC;
|
|
129
|
-
contextAri: t.StringC;
|
|
130
|
-
tokens: t.ArrayC<t.IntersectionC<[t.TypeC<{
|
|
131
|
-
id: t.StringC;
|
|
132
|
-
service: t.StringC;
|
|
133
|
-
token: t.StringC;
|
|
134
|
-
}>, t.PartialC<{
|
|
135
|
-
externalAccountId: t.StringC;
|
|
136
|
-
displayName: t.StringC;
|
|
137
|
-
avatarUrl: t.UnionC<[t.StringC, t.UndefinedC]>;
|
|
138
|
-
scopes: t.ArrayC<t.StringC>;
|
|
139
|
-
}>]>>;
|
|
140
|
-
appContext: t.IntersectionC<[t.TypeC<{
|
|
141
|
-
appId: t.StringC;
|
|
142
|
-
appVersion: t.StringC;
|
|
143
|
-
environmentId: t.StringC;
|
|
144
|
-
environmentType: t.StringC;
|
|
145
|
-
invocationId: t.StringC;
|
|
146
|
-
installationId: t.StringC;
|
|
147
|
-
functionKey: t.StringC;
|
|
148
|
-
moduleType: t.StringC;
|
|
149
|
-
moduleKey: t.StringC;
|
|
150
|
-
}>, t.PartialC<{
|
|
151
|
-
license: t.IntersectionC<[t.TypeC<{
|
|
152
|
-
isActive: t.BooleanC;
|
|
153
|
-
}>, t.PartialC<{
|
|
154
|
-
billingPeriod: t.UnionC<[t.StringC, t.NullC]>;
|
|
155
|
-
capabilitySet: t.UnionC<[t.StringC, t.NullC]>;
|
|
156
|
-
ccpEntitlementId: t.UnionC<[t.StringC, t.NullC]>;
|
|
157
|
-
ccpEntitlementSlug: t.UnionC<[t.StringC, t.NullC]>;
|
|
158
|
-
isEvaluation: t.UnionC<[t.BooleanC, t.NullC]>;
|
|
159
|
-
subscriptionEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
160
|
-
supportEntitlementNumber: t.UnionC<[t.StringC, t.NullC]>;
|
|
161
|
-
trialEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
162
|
-
type: t.UnionC<[t.StringC, t.NullC]>;
|
|
163
|
-
}>]>;
|
|
164
|
-
}>]>;
|
|
165
|
-
tracing: t.TypeC<{
|
|
166
|
-
traceId: t.StringC;
|
|
167
|
-
spanId: t.StringC;
|
|
168
|
-
}>;
|
|
169
|
-
}>, t.PartialC<{
|
|
170
|
-
aaid: t.StringC;
|
|
171
|
-
featureFlags: t.ArrayC<t.StringC>;
|
|
172
|
-
appToken: t.StringC;
|
|
173
|
-
proxy: t.IntersectionC<[t.TypeC<{
|
|
174
|
-
token: t.StringC;
|
|
175
|
-
url: t.StringC;
|
|
176
|
-
}>, t.PartialC<{
|
|
177
|
-
host: t.StringC;
|
|
178
|
-
}>]>;
|
|
179
|
-
timeout: t.NumberC;
|
|
180
|
-
rms: t.TypeC<{
|
|
181
|
-
url: t.StringC;
|
|
182
|
-
host: t.StringC;
|
|
183
|
-
}>;
|
|
184
|
-
limits: t.RecordC<t.StringC, t.NumberC>;
|
|
185
|
-
license: t.IntersectionC<[t.TypeC<{
|
|
186
|
-
isActive: t.BooleanC;
|
|
187
|
-
}>, t.PartialC<{
|
|
188
|
-
billingPeriod: t.UnionC<[t.StringC, t.NullC]>;
|
|
189
|
-
capabilitySet: t.UnionC<[t.StringC, t.NullC]>;
|
|
190
|
-
ccpEntitlementId: t.UnionC<[t.StringC, t.NullC]>;
|
|
191
|
-
ccpEntitlementSlug: t.UnionC<[t.StringC, t.NullC]>;
|
|
192
|
-
isEvaluation: t.UnionC<[t.BooleanC, t.NullC]>;
|
|
193
|
-
subscriptionEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
194
|
-
supportEntitlementNumber: t.UnionC<[t.StringC, t.NullC]>;
|
|
195
|
-
trialEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
196
|
-
type: t.UnionC<[t.StringC, t.NullC]>;
|
|
197
|
-
}>]>;
|
|
198
|
-
fetchAllowList: t.ArrayC<t.StringC>;
|
|
199
|
-
externalAuth: t.ArrayC<t.TypeC<{
|
|
200
|
-
service: t.StringC;
|
|
201
|
-
remotes: t.ArrayC<t.TypeC<{
|
|
202
|
-
baseUrl: t.StringC;
|
|
203
|
-
key: t.StringC;
|
|
204
|
-
}>>;
|
|
205
|
-
accounts: t.ArrayC<t.IntersectionC<[t.TypeC<{
|
|
206
|
-
id: t.StringC;
|
|
207
|
-
externalAccountId: t.StringC;
|
|
208
|
-
displayName: t.StringC;
|
|
209
|
-
scopes: t.ArrayC<t.StringC>;
|
|
210
|
-
}>, t.PartialC<{
|
|
211
|
-
avatarUrl: t.StringC;
|
|
212
|
-
}>]>>;
|
|
213
|
-
}>>;
|
|
214
|
-
}>]>;
|
|
215
|
-
body: t.UnknownRecordC;
|
|
216
|
-
handler: t.StringC;
|
|
217
|
-
}>, t.PartialC<{
|
|
218
|
-
variables: t.ArrayC<t.TypeC<{
|
|
219
|
-
secure: t.BooleanC;
|
|
220
|
-
key: t.StringC;
|
|
221
|
-
value: t.UnionC<[t.StringC, t.UndefinedC]>;
|
|
222
|
-
}>>;
|
|
223
|
-
}>]>;
|
|
224
|
-
export declare const InvocationType: t.TypeC<{
|
|
225
|
-
request: t.IntersectionC<[t.TypeC<{
|
|
226
|
-
_meta: t.IntersectionC<[t.TypeC<{
|
|
227
|
-
apiAuth: t.TypeC<{
|
|
228
|
-
env: t.StringC;
|
|
229
|
-
objects: t.StringC;
|
|
230
|
-
}>;
|
|
231
|
-
clientId: t.StringC;
|
|
232
|
-
contextAri: t.StringC;
|
|
233
|
-
tokens: t.ArrayC<t.IntersectionC<[t.TypeC<{
|
|
234
|
-
id: t.StringC;
|
|
235
|
-
service: t.StringC;
|
|
236
|
-
token: t.StringC;
|
|
237
|
-
}>, t.PartialC<{
|
|
238
|
-
externalAccountId: t.StringC;
|
|
239
|
-
displayName: t.StringC;
|
|
240
|
-
avatarUrl: t.UnionC<[t.StringC, t.UndefinedC]>;
|
|
241
|
-
scopes: t.ArrayC<t.StringC>;
|
|
242
|
-
}>]>>;
|
|
243
|
-
appContext: t.IntersectionC<[t.TypeC<{
|
|
244
|
-
appId: t.StringC;
|
|
245
|
-
appVersion: t.StringC;
|
|
246
|
-
environmentId: t.StringC;
|
|
247
|
-
environmentType: t.StringC;
|
|
248
|
-
invocationId: t.StringC;
|
|
249
|
-
installationId: t.StringC;
|
|
250
|
-
functionKey: t.StringC;
|
|
251
|
-
moduleType: t.StringC;
|
|
252
|
-
moduleKey: t.StringC;
|
|
253
|
-
}>, t.PartialC<{
|
|
254
|
-
license: t.IntersectionC<[t.TypeC<{
|
|
255
|
-
isActive: t.BooleanC;
|
|
256
|
-
}>, t.PartialC<{
|
|
257
|
-
billingPeriod: t.UnionC<[t.StringC, t.NullC]>;
|
|
258
|
-
capabilitySet: t.UnionC<[t.StringC, t.NullC]>;
|
|
259
|
-
ccpEntitlementId: t.UnionC<[t.StringC, t.NullC]>;
|
|
260
|
-
ccpEntitlementSlug: t.UnionC<[t.StringC, t.NullC]>;
|
|
261
|
-
isEvaluation: t.UnionC<[t.BooleanC, t.NullC]>;
|
|
262
|
-
subscriptionEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
263
|
-
supportEntitlementNumber: t.UnionC<[t.StringC, t.NullC]>;
|
|
264
|
-
trialEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
265
|
-
type: t.UnionC<[t.StringC, t.NullC]>;
|
|
266
|
-
}>]>;
|
|
267
|
-
}>]>;
|
|
268
|
-
tracing: t.TypeC<{
|
|
269
|
-
traceId: t.StringC;
|
|
270
|
-
spanId: t.StringC;
|
|
271
|
-
}>;
|
|
272
|
-
}>, t.PartialC<{
|
|
273
|
-
aaid: t.StringC;
|
|
274
|
-
featureFlags: t.ArrayC<t.StringC>;
|
|
275
|
-
appToken: t.StringC;
|
|
276
|
-
proxy: t.IntersectionC<[t.TypeC<{
|
|
277
|
-
token: t.StringC;
|
|
278
|
-
url: t.StringC;
|
|
279
|
-
}>, t.PartialC<{
|
|
280
|
-
host: t.StringC;
|
|
281
|
-
}>]>;
|
|
282
|
-
timeout: t.NumberC;
|
|
283
|
-
rms: t.TypeC<{
|
|
284
|
-
url: t.StringC;
|
|
285
|
-
host: t.StringC;
|
|
286
|
-
}>;
|
|
287
|
-
limits: t.RecordC<t.StringC, t.NumberC>;
|
|
288
|
-
license: t.IntersectionC<[t.TypeC<{
|
|
289
|
-
isActive: t.BooleanC;
|
|
290
|
-
}>, t.PartialC<{
|
|
291
|
-
billingPeriod: t.UnionC<[t.StringC, t.NullC]>;
|
|
292
|
-
capabilitySet: t.UnionC<[t.StringC, t.NullC]>;
|
|
293
|
-
ccpEntitlementId: t.UnionC<[t.StringC, t.NullC]>;
|
|
294
|
-
ccpEntitlementSlug: t.UnionC<[t.StringC, t.NullC]>;
|
|
295
|
-
isEvaluation: t.UnionC<[t.BooleanC, t.NullC]>;
|
|
296
|
-
subscriptionEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
297
|
-
supportEntitlementNumber: t.UnionC<[t.StringC, t.NullC]>;
|
|
298
|
-
trialEndDate: t.UnionC<[t.StringC, t.NullC]>;
|
|
299
|
-
type: t.UnionC<[t.StringC, t.NullC]>;
|
|
300
|
-
}>]>;
|
|
301
|
-
fetchAllowList: t.ArrayC<t.StringC>;
|
|
302
|
-
externalAuth: t.ArrayC<t.TypeC<{
|
|
303
|
-
service: t.StringC;
|
|
304
|
-
remotes: t.ArrayC<t.TypeC<{
|
|
305
|
-
baseUrl: t.StringC;
|
|
306
|
-
key: t.StringC;
|
|
307
|
-
}>>;
|
|
308
|
-
accounts: t.ArrayC<t.IntersectionC<[t.TypeC<{
|
|
309
|
-
id: t.StringC;
|
|
310
|
-
externalAccountId: t.StringC;
|
|
311
|
-
displayName: t.StringC;
|
|
312
|
-
scopes: t.ArrayC<t.StringC>;
|
|
313
|
-
}>, t.PartialC<{
|
|
314
|
-
avatarUrl: t.StringC;
|
|
315
|
-
}>]>>;
|
|
316
|
-
}>>;
|
|
317
|
-
}>]>;
|
|
318
|
-
body: t.UnknownRecordC;
|
|
319
|
-
handler: t.StringC;
|
|
320
|
-
}>, t.PartialC<{
|
|
321
|
-
variables: t.ArrayC<t.TypeC<{
|
|
322
|
-
secure: t.BooleanC;
|
|
323
|
-
key: t.StringC;
|
|
324
|
-
value: t.UnionC<[t.StringC, t.UndefinedC]>;
|
|
325
|
-
}>>;
|
|
326
|
-
}>]>;
|
|
327
|
-
ctx: t.TypeC<{
|
|
328
|
-
requestId: t.StringC;
|
|
329
|
-
timeout: t.NumberC;
|
|
330
|
-
traceId: t.StringC;
|
|
331
|
-
}>;
|
|
332
|
-
}>;
|
|
333
|
-
export declare type ExternalRequestVariable = t.TypeOf<typeof VariableType>;
|
|
334
|
-
export declare type License = t.TypeOf<typeof LicenseType>;
|
|
335
|
-
export declare type Invocation = t.TypeOf<typeof InvocationType>;
|
|
336
|
-
export declare type Metadata = t.TypeOf<typeof MetadataType>;
|
|
337
|
-
export declare type XisRequestToken = t.TypeOf<typeof XisRequestTokenType>;
|
|
338
|
-
export declare type ExternalRequestBody = t.TypeOf<typeof ExternalRequestBodyType>;
|
|
1
|
+
interface Remote {
|
|
2
|
+
baseUrl: string;
|
|
3
|
+
key: string;
|
|
4
|
+
}
|
|
5
|
+
interface ExternalAuthMetaDataAccount {
|
|
6
|
+
id: string;
|
|
7
|
+
externalAccountId: string;
|
|
8
|
+
displayName: string;
|
|
9
|
+
scopes: string[];
|
|
10
|
+
avatarUrl?: string;
|
|
11
|
+
}
|
|
12
|
+
interface ExternalAuthMetaData {
|
|
13
|
+
service: string;
|
|
14
|
+
remotes: Remote[];
|
|
15
|
+
accounts: ExternalAuthMetaDataAccount[];
|
|
16
|
+
}
|
|
17
|
+
interface XisRequestTokenType {
|
|
18
|
+
id: string;
|
|
19
|
+
service: string;
|
|
20
|
+
token: string;
|
|
21
|
+
externalAccountId?: string;
|
|
22
|
+
displayName?: string;
|
|
23
|
+
avatarUrl?: string;
|
|
24
|
+
scopes?: string[];
|
|
25
|
+
}
|
|
26
|
+
export interface License {
|
|
27
|
+
isActive: boolean;
|
|
28
|
+
billingPeriod?: string | null;
|
|
29
|
+
capabilitySet?: string | null;
|
|
30
|
+
ccpEntitlementId?: string | null;
|
|
31
|
+
ccpEntitlementSlug?: string | null;
|
|
32
|
+
isEvaluation?: boolean | null;
|
|
33
|
+
subscriptionEndDate?: string | null;
|
|
34
|
+
supportEntitlementNumber?: string | null;
|
|
35
|
+
trialEndDate?: string | null;
|
|
36
|
+
type?: string | null;
|
|
37
|
+
}
|
|
38
|
+
interface AppContext {
|
|
39
|
+
appId: string;
|
|
40
|
+
appVersion: string;
|
|
41
|
+
environmentId: string;
|
|
42
|
+
environmentType: string;
|
|
43
|
+
invocationId: string;
|
|
44
|
+
installationId: string;
|
|
45
|
+
functionKey: string;
|
|
46
|
+
moduleType: string;
|
|
47
|
+
moduleKey: string;
|
|
48
|
+
license?: License;
|
|
49
|
+
}
|
|
50
|
+
export interface Metadata {
|
|
51
|
+
apiAuth: {
|
|
52
|
+
env: string;
|
|
53
|
+
objects: string;
|
|
54
|
+
};
|
|
55
|
+
clientId: string;
|
|
56
|
+
contextAri: string;
|
|
57
|
+
tokens: XisRequestTokenType[];
|
|
58
|
+
appContext: AppContext;
|
|
59
|
+
tracing: {
|
|
60
|
+
traceId: string;
|
|
61
|
+
spanId: string;
|
|
62
|
+
};
|
|
63
|
+
aaid?: string;
|
|
64
|
+
featureFlags?: string[];
|
|
65
|
+
appToken?: string;
|
|
66
|
+
proxy?: {
|
|
67
|
+
token: string;
|
|
68
|
+
url: string;
|
|
69
|
+
host?: string;
|
|
70
|
+
};
|
|
71
|
+
timeout?: number;
|
|
72
|
+
rms?: {
|
|
73
|
+
url: string;
|
|
74
|
+
host: string;
|
|
75
|
+
};
|
|
76
|
+
limits?: Record<string, number>;
|
|
77
|
+
license?: License;
|
|
78
|
+
fetchAllowList?: string[];
|
|
79
|
+
externalAuth?: ExternalAuthMetaData[];
|
|
80
|
+
}
|
|
81
|
+
export interface ExternalRequestVariable {
|
|
82
|
+
secure: boolean;
|
|
83
|
+
key: string;
|
|
84
|
+
value: string | undefined;
|
|
85
|
+
}
|
|
86
|
+
export interface ExternalRequestBody {
|
|
87
|
+
_meta: Metadata;
|
|
88
|
+
body: Record<string, unknown>;
|
|
89
|
+
handler: string;
|
|
90
|
+
variables?: ExternalRequestVariable[];
|
|
91
|
+
}
|
|
339
92
|
export {};
|
|
340
93
|
//# sourceMappingURL=request.d.ts.map
|
package/out/request.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"AAAA,UAAU,MAAM;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,UAAU,2BAA2B;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,iBAAiB,EAAE,MAAM,CAAC;IAC1B,WAAW,EAAE,MAAM,CAAC;IACpB,M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