@mountaya/client 0.0.0-stage → 0.2.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/CHANGELOG.md +149 -0
- package/LICENCE.fr.txt +280 -0
- package/LICENSE.txt +262 -0
- package/README.md +1260 -2
- package/dist/admin/index.cjs +2895 -0
- package/dist/admin/index.cjs.map +1 -0
- package/dist/admin/index.d.cts +889 -0
- package/dist/admin/index.d.ts +889 -0
- package/dist/admin/index.js +204 -0
- package/dist/admin/index.js.map +1 -0
- package/dist/browser.cjs +5993 -0
- package/dist/browser.cjs.map +1 -0
- package/dist/browser.d.cts +70 -0
- package/dist/browser.d.ts +70 -0
- package/dist/browser.js +22 -0
- package/dist/browser.js.map +1 -0
- package/dist/chunk-CeEX7ayk.d.cts +75531 -0
- package/dist/chunk-CeEX7ayk.d.ts +75531 -0
- package/dist/chunk-Cg7Dtcb4.js +2987 -0
- package/dist/chunk-Cg7Dtcb4.js.map +1 -0
- package/dist/chunk-DJqUsgsy.d.ts +1463 -0
- package/dist/chunk-DNc8T5K1.js +241 -0
- package/dist/chunk-DNc8T5K1.js.map +1 -0
- package/dist/chunk-DTxzw3hu.d.cts +1463 -0
- package/dist/chunk-DmxQID5X.js +2289 -0
- package/dist/chunk-DmxQID5X.js.map +1 -0
- package/dist/chunk-DoZt_oIV.d.ts +3991 -0
- package/dist/chunk-DpJrqANO.js +11 -0
- package/dist/chunk-Dx8mPAdC.d.cts +3991 -0
- package/dist/chunk-X2ukY3ho.js +419 -0
- package/dist/chunk-X2ukY3ho.js.map +1 -0
- package/dist/events/index.cjs +1436 -0
- package/dist/events/index.cjs.map +1 -0
- package/dist/events/index.d.cts +772 -0
- package/dist/events/index.d.ts +772 -0
- package/dist/events/index.js +543 -0
- package/dist/events/index.js.map +1 -0
- package/dist/index.cjs +5992 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +44 -0
- package/dist/index.d.ts +44 -0
- package/dist/index.js +21 -0
- package/dist/index.js.map +1 -0
- package/package.json +126 -4
- package/src/admin/index.ts +47 -0
- package/src/admin/rules/mountayaAdmin.ts +102 -0
- package/src/browser.ts +233 -0
- package/src/core/engines/sessionToken.ts +870 -0
- package/src/core/rules/auth.ts +1017 -0
- package/src/core/rules/clientHeader.ts +28 -0
- package/src/core/rules/dates.ts +200 -0
- package/src/core/rules/decode.ts +154 -0
- package/src/core/rules/envelope.ts +41 -0
- package/src/core/rules/errors.ts +1486 -0
- package/src/core/rules/graphql.ts +576 -0
- package/src/core/rules/headerValue.ts +42 -0
- package/src/core/rules/idempotencyKey.ts +64 -0
- package/src/core/rules/nullMask.ts +127 -0
- package/src/core/rules/nullMasks.gen.ts +428 -0
- package/src/core/rules/paginate.ts +316 -0
- package/src/core/rules/rateLimit.ts +507 -0
- package/src/core/rules/redaction.ts +219 -0
- package/src/core/rules/resourceRef.ts +110 -0
- package/src/core/rules/responseBody.ts +492 -0
- package/src/core/rules/retry.ts +386 -0
- package/src/core/rules/selection.ts +416 -0
- package/src/core/rules/sessionAnswer.ts +90 -0
- package/src/core/rules/sessionSchedule.ts +131 -0
- package/src/core/rules/sessionWait.ts +112 -0
- package/src/core/rules/transport.ts +2386 -0
- package/src/core/rules/version.gen.ts +16 -0
- package/src/core/rules/webAddress.ts +165 -0
- package/src/core/rules/webAddresses.gen.ts +30 -0
- package/src/data/operations.gen.ts +603 -0
- package/src/data/schema.gen.ts +8078 -0
- package/src/data/selection.gen.ts +472 -0
- package/src/events/index.ts +63 -0
- package/src/events/rules/agent.ts +439 -0
- package/src/events/rules/collab.ts +554 -0
- package/src/events/rules/collabNulls.gen.ts +17 -0
- package/src/events/rules/eventStream.ts +94 -0
- package/src/events/rules/openSseStream.ts +594 -0
- package/src/events/rules/sse.ts +349 -0
- package/src/index.ts +231 -0
- package/src/rest/adminOperations.gen.ts +70 -0
- package/src/rest/adminResources.gen.ts +138 -0
- package/src/rest/coreOperations.gen.ts +74 -0
- package/src/rest/coreResources.gen.ts +244 -0
- package/src/rest/dates.gen.ts +217 -0
- package/src/rest/operations.gen.ts +4341 -0
- package/src/rest/resources.gen.ts +371 -0
- package/src/rest/schema.gen.ts +57027 -0
- package/src/tiles/operations.gen.ts +206 -0
- package/src/tiles/schema.gen.ts +8406 -0
- package/src/webhooks/rules/constructWebhookEvent.ts +482 -0
- package/src/webhooks/rules/webhookEvent.ts +38 -0
- package/src/webhooks/rules/webhookEvents.gen.ts +732 -0
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
import { t as __exportAll } from "../chunk-DpJrqANO.js";
|
|
2
|
+
import { $ as getOrganizationPublishableKey, $t as postMyInvitationAccept, B as getMyOrganizations, Ct as patchOrganization, Dt as patchOrganizationPublishableKey, Et as patchOrganizationMember, G as getOrganizationBillingInvoices, H as getOrganization, J as getOrganizationBillingSubscription, K as getOrganizationBillingPaymentMethods, Mn as MountayaError, On as MountayaConfigurationError, Ot as patchOrganizationSettings, Q as getOrganizationMembers, R as getMyInvitations, St as patchMyPreferences, T as getBillingProducts, Tt as patchOrganizationBillingInfo, U as getOrganizationAiProviderConfig, V as getMyPreferences, W as getOrganizationBillingInfo, Wn as describeType, X as getOrganizationInvitation, Z as getOrganizationInvitations, _ as deleteOrganizationMember, an as postOrganizationBillingProvision, at as getOrganizationWebhookDelivery, ct as getOrganizationWebhookEvent, dn as postOrganizationWebhookEndpoint, dt as getWebhookEventTypes, en as postOrganization, er as refuseOption, et as getOrganizationPublishableKeys, f as deleteMyInvitation, fn as postSession, g as deleteOrganizationInvitation, h as deleteOrganizationBillingSubscription, in as postOrganizationBillingPaymentMethodSetup, it as getOrganizationWebhookDeliveries, kt as patchOrganizationWebhookEndpoint, ln as postOrganizationPublishableKey, lt as getOrganizationWebhookEvents, m as deleteOrganizationBillingPaymentMethod, nn as postOrganizationBillingPaymentMethod, nt as getOrganizationUsageData, on as postOrganizationBillingSubscription, ot as getOrganizationWebhookEndpoint, p as deleteOrganizationAiProviderConfig, q as getOrganizationBillingPromotionCode, rn as postOrganizationBillingPaymentMethodSetDefault, rt as getOrganizationUsageTiles, sn as postOrganizationInvitation, st as getOrganizationWebhookEndpoints, t as bind, tn as postOrganizationAiProviderConfig, tt as getOrganizationSettings, un as postOrganizationWebhookDelivery, ut as getOrganizationWebhookHealth, v as deleteOrganizationPublishableKey, w as getAiProviders, wt as patchOrganizationAiProviderConfig, xt as patchMyOrganizationNotificationPreferences, y as deleteOrganizationWebhookEndpoint, z as getMyOrganizationNotificationPreferences } from "../chunk-Cg7Dtcb4.js";
|
|
3
|
+
import { n as decodeSchemaInstants, t as decodeRestSchema } from "../chunk-X2ukY3ho.js";
|
|
4
|
+
var adminOperations_gen_exports = /* @__PURE__ */ __exportAll({
|
|
5
|
+
deleteMyInvitation: () => deleteMyInvitation,
|
|
6
|
+
deleteOrganizationAiProviderConfig: () => deleteOrganizationAiProviderConfig,
|
|
7
|
+
deleteOrganizationBillingPaymentMethod: () => deleteOrganizationBillingPaymentMethod,
|
|
8
|
+
deleteOrganizationBillingSubscription: () => deleteOrganizationBillingSubscription,
|
|
9
|
+
deleteOrganizationInvitation: () => deleteOrganizationInvitation,
|
|
10
|
+
deleteOrganizationMember: () => deleteOrganizationMember,
|
|
11
|
+
deleteOrganizationPublishableKey: () => deleteOrganizationPublishableKey,
|
|
12
|
+
deleteOrganizationWebhookEndpoint: () => deleteOrganizationWebhookEndpoint,
|
|
13
|
+
getAiProviders: () => getAiProviders,
|
|
14
|
+
getBillingProducts: () => getBillingProducts,
|
|
15
|
+
getMyInvitations: () => getMyInvitations,
|
|
16
|
+
getMyOrganizationNotificationPreferences: () => getMyOrganizationNotificationPreferences,
|
|
17
|
+
getMyOrganizations: () => getMyOrganizations,
|
|
18
|
+
getMyPreferences: () => getMyPreferences,
|
|
19
|
+
getOrganization: () => getOrganization,
|
|
20
|
+
getOrganizationAiProviderConfig: () => getOrganizationAiProviderConfig,
|
|
21
|
+
getOrganizationBillingInfo: () => getOrganizationBillingInfo,
|
|
22
|
+
getOrganizationBillingInvoices: () => getOrganizationBillingInvoices,
|
|
23
|
+
getOrganizationBillingPaymentMethods: () => getOrganizationBillingPaymentMethods,
|
|
24
|
+
getOrganizationBillingPromotionCode: () => getOrganizationBillingPromotionCode,
|
|
25
|
+
getOrganizationBillingSubscription: () => getOrganizationBillingSubscription,
|
|
26
|
+
getOrganizationInvitation: () => getOrganizationInvitation,
|
|
27
|
+
getOrganizationInvitations: () => getOrganizationInvitations,
|
|
28
|
+
getOrganizationMembers: () => getOrganizationMembers,
|
|
29
|
+
getOrganizationPublishableKey: () => getOrganizationPublishableKey,
|
|
30
|
+
getOrganizationPublishableKeys: () => getOrganizationPublishableKeys,
|
|
31
|
+
getOrganizationSettings: () => getOrganizationSettings,
|
|
32
|
+
getOrganizationUsageData: () => getOrganizationUsageData,
|
|
33
|
+
getOrganizationUsageTiles: () => getOrganizationUsageTiles,
|
|
34
|
+
getOrganizationWebhookDeliveries: () => getOrganizationWebhookDeliveries,
|
|
35
|
+
getOrganizationWebhookDelivery: () => getOrganizationWebhookDelivery,
|
|
36
|
+
getOrganizationWebhookEndpoint: () => getOrganizationWebhookEndpoint,
|
|
37
|
+
getOrganizationWebhookEndpoints: () => getOrganizationWebhookEndpoints,
|
|
38
|
+
getOrganizationWebhookEvent: () => getOrganizationWebhookEvent,
|
|
39
|
+
getOrganizationWebhookEvents: () => getOrganizationWebhookEvents,
|
|
40
|
+
getOrganizationWebhookHealth: () => getOrganizationWebhookHealth,
|
|
41
|
+
getWebhookEventTypes: () => getWebhookEventTypes,
|
|
42
|
+
patchMyOrganizationNotificationPreferences: () => patchMyOrganizationNotificationPreferences,
|
|
43
|
+
patchMyPreferences: () => patchMyPreferences,
|
|
44
|
+
patchOrganization: () => patchOrganization,
|
|
45
|
+
patchOrganizationAiProviderConfig: () => patchOrganizationAiProviderConfig,
|
|
46
|
+
patchOrganizationBillingInfo: () => patchOrganizationBillingInfo,
|
|
47
|
+
patchOrganizationMember: () => patchOrganizationMember,
|
|
48
|
+
patchOrganizationPublishableKey: () => patchOrganizationPublishableKey,
|
|
49
|
+
patchOrganizationSettings: () => patchOrganizationSettings,
|
|
50
|
+
patchOrganizationWebhookEndpoint: () => patchOrganizationWebhookEndpoint,
|
|
51
|
+
postMyInvitationAccept: () => postMyInvitationAccept,
|
|
52
|
+
postOrganization: () => postOrganization,
|
|
53
|
+
postOrganizationAiProviderConfig: () => postOrganizationAiProviderConfig,
|
|
54
|
+
postOrganizationBillingPaymentMethod: () => postOrganizationBillingPaymentMethod,
|
|
55
|
+
postOrganizationBillingPaymentMethodSetDefault: () => postOrganizationBillingPaymentMethodSetDefault,
|
|
56
|
+
postOrganizationBillingPaymentMethodSetup: () => postOrganizationBillingPaymentMethodSetup,
|
|
57
|
+
postOrganizationBillingProvision: () => postOrganizationBillingProvision,
|
|
58
|
+
postOrganizationBillingSubscription: () => postOrganizationBillingSubscription,
|
|
59
|
+
postOrganizationInvitation: () => postOrganizationInvitation,
|
|
60
|
+
postOrganizationPublishableKey: () => postOrganizationPublishableKey,
|
|
61
|
+
postOrganizationWebhookDelivery: () => postOrganizationWebhookDelivery,
|
|
62
|
+
postOrganizationWebhookEndpoint: () => postOrganizationWebhookEndpoint,
|
|
63
|
+
postSession: () => postSession
|
|
64
|
+
});
|
|
65
|
+
const CONTEXT = "constructWebhookEvent";
|
|
66
|
+
const DEFAULT_TOLERANCE_SECONDS = 300;
|
|
67
|
+
const SECRET_PREFIX = "whsk_";
|
|
68
|
+
const wholeSeconds = /^\d+$/;
|
|
69
|
+
const LATEST_WRITTEN_SECONDS = 253402300799;
|
|
70
|
+
const signedAt = (timestamp) => timestamp <= LATEST_WRITTEN_SECONDS ? (/* @__PURE__ */ new Date(timestamp * 1e3)).toISOString() : `t=${timestamp}`;
|
|
71
|
+
var MountayaWebhookSignatureError = class extends MountayaError {
|
|
72
|
+
name = "MountayaWebhookSignatureError";
|
|
73
|
+
reason;
|
|
74
|
+
constructor(message, reason) {
|
|
75
|
+
super(message);
|
|
76
|
+
this.reason = reason;
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
const parseSignatureHeader = (header) => {
|
|
80
|
+
const signatures = [];
|
|
81
|
+
const timestamps = [];
|
|
82
|
+
for (const element of header.split(",")) {
|
|
83
|
+
const separator = element.indexOf("=");
|
|
84
|
+
if (separator === -1) return;
|
|
85
|
+
const key = element.slice(0, separator).trim();
|
|
86
|
+
const value = element.slice(separator + 1).trim();
|
|
87
|
+
if (key === "t") timestamps.push(value);
|
|
88
|
+
else if (key === "v1") signatures.push(value);
|
|
89
|
+
}
|
|
90
|
+
const [stated] = timestamps;
|
|
91
|
+
if (timestamps.length !== 1 || stated === void 0 || !wholeSeconds.test(stated)) return;
|
|
92
|
+
const timestamp = Number(stated);
|
|
93
|
+
if (!Number.isSafeInteger(timestamp) || signatures.length === 0) return;
|
|
94
|
+
return {
|
|
95
|
+
signatures,
|
|
96
|
+
stated,
|
|
97
|
+
timestamp
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
const subtleCrypto = () => {
|
|
101
|
+
return globalThis.crypto?.subtle;
|
|
102
|
+
};
|
|
103
|
+
const hexOf = (bytes) => Array.from(new Uint8Array(bytes), (byte) => byte.toString(16).padStart(2, "0")).join("");
|
|
104
|
+
const equalInConstantTime = (candidate, expected) => {
|
|
105
|
+
if (candidate.length !== expected.length) return false;
|
|
106
|
+
let difference = 0;
|
|
107
|
+
for (let index = 0; index < expected.length; index += 1) difference |= candidate.charCodeAt(index) ^ expected.charCodeAt(index);
|
|
108
|
+
return difference === 0;
|
|
109
|
+
};
|
|
110
|
+
const signedBytes = (stated, body) => {
|
|
111
|
+
const prefix = new TextEncoder().encode(`${stated}.`);
|
|
112
|
+
const signed = new Uint8Array(prefix.length + body.length);
|
|
113
|
+
signed.set(prefix);
|
|
114
|
+
signed.set(body, prefix.length);
|
|
115
|
+
return signed;
|
|
116
|
+
};
|
|
117
|
+
const isRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
118
|
+
const envelopeOf = (body) => {
|
|
119
|
+
const refusal = `${CONTEXT}: the delivery verified and its body holds no webhook event, not even the envelope every event is delivered in. Answer the request with a 400 and act on nothing it asks.`;
|
|
120
|
+
let parsed;
|
|
121
|
+
try {
|
|
122
|
+
parsed = JSON.parse(new TextDecoder().decode(body));
|
|
123
|
+
} catch (cause) {
|
|
124
|
+
throw new MountayaConfigurationError(refusal, { cause });
|
|
125
|
+
}
|
|
126
|
+
if (!isRecord(parsed)) throw new MountayaConfigurationError(refusal);
|
|
127
|
+
return parsed;
|
|
128
|
+
};
|
|
129
|
+
const withPreviousAttributes = (event) => {
|
|
130
|
+
if (!isRecord(event) || !isRecord(event.data) || !isRecord(event.data.previous_attributes)) return event;
|
|
131
|
+
const held = event.data.previous_attributes;
|
|
132
|
+
const decoded = decodeSchemaInstants("WebhookEventObject", held);
|
|
133
|
+
return decoded === held ? event : {
|
|
134
|
+
...event,
|
|
135
|
+
data: {
|
|
136
|
+
...event.data,
|
|
137
|
+
previous_attributes: decoded
|
|
138
|
+
}
|
|
139
|
+
};
|
|
140
|
+
};
|
|
141
|
+
const millisecondsOf = (value) => {
|
|
142
|
+
try {
|
|
143
|
+
return Date.prototype.getTime.call(value);
|
|
144
|
+
} catch {
|
|
145
|
+
return;
|
|
146
|
+
}
|
|
147
|
+
};
|
|
148
|
+
const constructWebhookEvent = async (rawBody, signatureHeader, secret, options) => {
|
|
149
|
+
if (typeof rawBody !== "string" && !(rawBody instanceof Uint8Array)) throw new MountayaConfigurationError(`${CONTEXT}: rawBody is ${describeType(rawBody)}; pass the body exactly as it arrived, as a string or a Uint8Array, before any JSON parser reads it.`);
|
|
150
|
+
if (typeof secret !== "string" || !secret.startsWith(SECRET_PREFIX)) throw new MountayaConfigurationError(`${CONTEXT}: secret is ${typeof secret === "string" ? "a string that does not start with whsk_" : describeType(secret)}; pass the signing secret of the endpoint the delivery was sent to, whsk_ included.`);
|
|
151
|
+
if (options !== void 0 && (typeof options !== "object" || options === null)) throw refuseOption("options", options, "pass an object such as { toleranceSeconds: 600 }, or leave it out for the defaults.", CONTEXT);
|
|
152
|
+
const toleranceSeconds = options?.toleranceSeconds ?? DEFAULT_TOLERANCE_SECONDS;
|
|
153
|
+
if (typeof toleranceSeconds !== "number" || !Number.isFinite(toleranceSeconds) || toleranceSeconds < 0) throw refuseOption("toleranceSeconds", toleranceSeconds, `pass a finite number of seconds from 0, or leave it out for ${DEFAULT_TOLERANCE_SECONDS}.`, CONTEXT);
|
|
154
|
+
const stated = options?.now;
|
|
155
|
+
const statedMilliseconds = stated === void 0 ? void 0 : millisecondsOf(stated);
|
|
156
|
+
if (stated !== void 0 && (statedMilliseconds === void 0 || !Number.isFinite(statedMilliseconds))) throw refuseOption("now", stated, "pass a Date that names an instant, or leave it out for the machine's wall clock.", CONTEXT);
|
|
157
|
+
const subtle = subtleCrypto();
|
|
158
|
+
if (subtle === void 0) throw new MountayaConfigurationError(`${CONTEXT}: this runtime provides no Web Crypto (crypto.subtle) to compute the signature with. Verify the delivery on a server, in Node 22.18 or later, a worker or an edge runtime.`);
|
|
159
|
+
if (signatureHeader === null || signatureHeader === void 0 || signatureHeader.trim() === "") throw new MountayaWebhookSignatureError(`${CONTEXT}: the request carries no Mountaya-Signature header. Pass the header the request carries, such as request.headers.get("Mountaya-Signature"), and answer a request without one with a 400.`, "missing-header");
|
|
160
|
+
const header = parseSignatureHeader(signatureHeader);
|
|
161
|
+
if (header === void 0) throw new MountayaWebhookSignatureError(`${CONTEXT}: the Mountaya-Signature header ${JSON.stringify(signatureHeader)} is not t=<unix seconds>,v1=<signature>. Pass the header exactly as the request carries it.`, "malformed-header");
|
|
162
|
+
const body = typeof rawBody === "string" ? new TextEncoder().encode(rawBody) : rawBody;
|
|
163
|
+
const key = await subtle.importKey("raw", new TextEncoder().encode(secret), {
|
|
164
|
+
hash: "SHA-256",
|
|
165
|
+
name: "HMAC"
|
|
166
|
+
}, false, ["sign"]);
|
|
167
|
+
const expected = hexOf(await subtle.sign("HMAC", key, signedBytes(header.stated, body)));
|
|
168
|
+
if (!header.signatures.reduce((found, candidate) => equalInConstantTime(candidate, expected) || found, false)) throw new MountayaWebhookSignatureError(`${CONTEXT}: no v1 of the Mountaya-Signature header is the signature of this body under this secret. Pass the body exactly as it arrived, before any JSON parser reads it, and the secret of the endpoint the delivery was sent to.`, "signature");
|
|
169
|
+
const skew = Math.abs((statedMilliseconds ?? Date.now()) / 1e3 - header.timestamp);
|
|
170
|
+
if (skew > toleranceSeconds) throw new MountayaWebhookSignatureError(`${CONTEXT}: the delivery was signed at ${signedAt(header.timestamp)}, ${Math.round(skew)} seconds from this clock, past the tolerance of ${toleranceSeconds} seconds. A delivery replayed later is refused this way; where the clock is wrong, set it right.`, "timestamp");
|
|
171
|
+
return withPreviousAttributes(decodeRestSchema("WebhookEvent", envelopeOf(body)));
|
|
172
|
+
};
|
|
173
|
+
const bound = /* @__PURE__ */ new WeakMap();
|
|
174
|
+
const adminOperationsOf = (transport) => {
|
|
175
|
+
const held = bound.get(transport);
|
|
176
|
+
if (held !== void 0) return held;
|
|
177
|
+
const table = bind(transport).admin;
|
|
178
|
+
bound.set(transport, table);
|
|
179
|
+
return table;
|
|
180
|
+
};
|
|
181
|
+
var MountayaAdmin = class {
|
|
182
|
+
billing;
|
|
183
|
+
invitations;
|
|
184
|
+
keys;
|
|
185
|
+
members;
|
|
186
|
+
organizations;
|
|
187
|
+
sessions;
|
|
188
|
+
users;
|
|
189
|
+
webhooks;
|
|
190
|
+
constructor(mountaya) {
|
|
191
|
+
const operations = adminOperationsOf(mountaya.transport);
|
|
192
|
+
this.billing = operations.billing;
|
|
193
|
+
this.invitations = operations.invitations;
|
|
194
|
+
this.keys = operations.keys;
|
|
195
|
+
this.members = operations.members;
|
|
196
|
+
this.organizations = operations.organizations;
|
|
197
|
+
this.sessions = operations.sessions;
|
|
198
|
+
this.users = operations.users;
|
|
199
|
+
this.webhooks = operations.webhooks;
|
|
200
|
+
}
|
|
201
|
+
};
|
|
202
|
+
export { MountayaAdmin, MountayaWebhookSignatureError, constructWebhookEvent, adminOperations_gen_exports as rest };
|
|
203
|
+
|
|
204
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["runtime"],"sources":["../../src/rest/adminOperations.gen.ts","../../src/webhooks/rules/constructWebhookEvent.ts","../../src/admin/rules/mountayaAdmin.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACoCA,MAAM,UAAU;AAGhB,MAAM,4BAA4B;AAGlC,MAAM,gBAAgB;AAGtB,MAAM,eAAe;AAGrB,MAAM,yBAAyB;AAM/B,MAAM,YAAY,cAChB,aAAa,0CAAyB,IAAI,KAAK,YAAY,GAAI,EAAA,CAAE,YAAY,IAAI,KAAK;AA8BxF,IAAa,gCAAb,cAAmD,cAAc;CAC/D,OAAyB;CAGzB;CAMA,YAAY,SAAiB,QAAiC;EAC5D,MAAM,OAAO;EACb,KAAK,SAAS;CAChB;AACF;AAyCA,MAAM,wBAAwB,WAAgD;CAC5E,MAAM,aAAuB,CAAC;CAC9B,MAAM,aAAuB,CAAC;CAE9B,KAAK,MAAM,WAAW,OAAO,MAAM,GAAG,GAAG;EACvC,MAAM,YAAY,QAAQ,QAAQ,GAAG;EACrC,IAAI,cAAc,IAChB;EAGF,MAAM,MAAM,QAAQ,MAAM,GAAG,SAAS,CAAC,CAAC,KAAK;EAC7C,MAAM,QAAQ,QAAQ,MAAM,YAAY,CAAC,CAAC,CAAC,KAAK;EAEhD,IAAI,QAAQ,KACV,WAAW,KAAK,KAAK;OAChB,IAAI,QAAQ,MACjB,WAAW,KAAK,KAAK;CAEzB;CAEA,MAAM,CAAC,UAAU;CACjB,IAAI,WAAW,WAAW,KAAK,WAAW,KAAA,KAAa,CAAC,aAAa,KAAK,MAAM,GAC9E;CAGF,MAAM,YAAY,OAAO,MAAM;CAC/B,IAAI,CAAC,OAAO,cAAc,SAAS,KA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