@polymorfa/sdk 0.1.0-dev.20260922093854
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/LICENSE +21 -0
- package/README.md +1881 -0
- package/dist/bridge.d.ts +31 -0
- package/dist/bridge.d.ts.map +1 -0
- package/dist/bridge.js +39 -0
- package/dist/bridge.js.map +1 -0
- package/dist/calls/api.d.ts +109 -0
- package/dist/calls/api.d.ts.map +1 -0
- package/dist/calls/api.js +179 -0
- package/dist/calls/api.js.map +1 -0
- package/dist/calls/call.d.ts +286 -0
- package/dist/calls/call.d.ts.map +1 -0
- package/dist/calls/call.js +860 -0
- package/dist/calls/call.js.map +1 -0
- package/dist/calls/client.d.ts +124 -0
- package/dist/calls/client.d.ts.map +1 -0
- package/dist/calls/client.js +447 -0
- package/dist/calls/client.js.map +1 -0
- package/dist/calls/diagnostics.d.ts +74 -0
- package/dist/calls/diagnostics.d.ts.map +1 -0
- package/dist/calls/diagnostics.js +133 -0
- package/dist/calls/diagnostics.js.map +1 -0
- package/dist/calls/errors.d.ts +37 -0
- package/dist/calls/errors.d.ts.map +1 -0
- package/dist/calls/errors.js +52 -0
- package/dist/calls/errors.js.map +1 -0
- package/dist/calls/events.d.ts +15 -0
- package/dist/calls/events.d.ts.map +1 -0
- package/dist/calls/events.js +34 -0
- package/dist/calls/events.js.map +1 -0
- package/dist/calls/index.d.ts +6 -0
- package/dist/calls/index.d.ts.map +1 -0
- package/dist/calls/index.js +7 -0
- package/dist/calls/index.js.map +1 -0
- package/dist/calls/internal.d.ts +18 -0
- package/dist/calls/internal.d.ts.map +1 -0
- package/dist/calls/internal.js +18 -0
- package/dist/calls/internal.js.map +1 -0
- package/dist/calls/lifecycle.d.ts +111 -0
- package/dist/calls/lifecycle.d.ts.map +1 -0
- package/dist/calls/lifecycle.js +490 -0
- package/dist/calls/lifecycle.js.map +1 -0
- package/dist/calls/media.d.ts +102 -0
- package/dist/calls/media.d.ts.map +1 -0
- package/dist/calls/media.js +414 -0
- package/dist/calls/media.js.map +1 -0
- package/dist/calls/protocol.d.ts +216 -0
- package/dist/calls/protocol.d.ts.map +1 -0
- package/dist/calls/protocol.js +268 -0
- package/dist/calls/protocol.js.map +1 -0
- package/dist/calls/token.d.ts +43 -0
- package/dist/calls/token.d.ts.map +1 -0
- package/dist/calls/token.js +146 -0
- package/dist/calls/token.js.map +1 -0
- package/dist/client.d.ts +65 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +119 -0
- package/dist/client.js.map +1 -0
- package/dist/credentials.d.ts +50 -0
- package/dist/credentials.d.ts.map +1 -0
- package/dist/credentials.js +73 -0
- package/dist/credentials.js.map +1 -0
- package/dist/errors.d.ts +71 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +129 -0
- package/dist/errors.js.map +1 -0
- package/dist/index.d.ts +70 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +61 -0
- package/dist/index.js.map +1 -0
- package/dist/media/whatsapp.d.ts +105 -0
- package/dist/media/whatsapp.d.ts.map +1 -0
- package/dist/media/whatsapp.js +624 -0
- package/dist/media/whatsapp.js.map +1 -0
- package/dist/messaging/bansafe.d.ts +30 -0
- package/dist/messaging/bansafe.d.ts.map +1 -0
- package/dist/messaging/bansafe.js +86 -0
- package/dist/messaging/bansafe.js.map +1 -0
- package/dist/messaging/business.d.ts +35 -0
- package/dist/messaging/business.d.ts.map +1 -0
- package/dist/messaging/business.js +145 -0
- package/dist/messaging/business.js.map +1 -0
- package/dist/messaging/calls.d.ts +9 -0
- package/dist/messaging/calls.d.ts.map +1 -0
- package/dist/messaging/calls.js +16 -0
- package/dist/messaging/calls.js.map +1 -0
- package/dist/messaging/campaigns.d.ts +19 -0
- package/dist/messaging/campaigns.d.ts.map +1 -0
- package/dist/messaging/campaigns.js +77 -0
- package/dist/messaging/campaigns.js.map +1 -0
- package/dist/messaging/channels.d.ts +23 -0
- package/dist/messaging/channels.d.ts.map +1 -0
- package/dist/messaging/channels.js +104 -0
- package/dist/messaging/channels.js.map +1 -0
- package/dist/messaging/chats.d.ts +14 -0
- package/dist/messaging/chats.d.ts.map +1 -0
- package/dist/messaging/chats.js +51 -0
- package/dist/messaging/chats.js.map +1 -0
- package/dist/messaging/client-tokens.d.ts +15 -0
- package/dist/messaging/client-tokens.d.ts.map +1 -0
- package/dist/messaging/client-tokens.js +64 -0
- package/dist/messaging/client-tokens.js.map +1 -0
- package/dist/messaging/client.d.ts +58 -0
- package/dist/messaging/client.d.ts.map +1 -0
- package/dist/messaging/client.js +100 -0
- package/dist/messaging/client.js.map +1 -0
- package/dist/messaging/contacts.d.ts +20 -0
- package/dist/messaging/contacts.d.ts.map +1 -0
- package/dist/messaging/contacts.js +75 -0
- package/dist/messaging/contacts.js.map +1 -0
- package/dist/messaging/groups.d.ts +34 -0
- package/dist/messaging/groups.d.ts.map +1 -0
- package/dist/messaging/groups.js +97 -0
- package/dist/messaging/groups.js.map +1 -0
- package/dist/messaging/identities.d.ts +9 -0
- package/dist/messaging/identities.d.ts.map +1 -0
- package/dist/messaging/identities.js +21 -0
- package/dist/messaging/identities.js.map +1 -0
- package/dist/messaging/labels.d.ts +16 -0
- package/dist/messaging/labels.d.ts.map +1 -0
- package/dist/messaging/labels.js +65 -0
- package/dist/messaging/labels.js.map +1 -0
- package/dist/messaging/media.d.ts +72 -0
- package/dist/messaging/media.d.ts.map +1 -0
- package/dist/messaging/media.js +142 -0
- package/dist/messaging/media.js.map +1 -0
- package/dist/messaging/messages.d.ts +18 -0
- package/dist/messaging/messages.d.ts.map +1 -0
- package/dist/messaging/messages.js +32 -0
- package/dist/messaging/messages.js.map +1 -0
- package/dist/messaging/observation-policies.d.ts +10 -0
- package/dist/messaging/observation-policies.d.ts.map +1 -0
- package/dist/messaging/observation-policies.js +28 -0
- package/dist/messaging/observation-policies.js.map +1 -0
- package/dist/messaging/onboarding.d.ts +53 -0
- package/dist/messaging/onboarding.d.ts.map +1 -0
- package/dist/messaging/onboarding.js +69 -0
- package/dist/messaging/onboarding.js.map +1 -0
- package/dist/messaging/presence.d.ts +12 -0
- package/dist/messaging/presence.d.ts.map +1 -0
- package/dist/messaging/presence.js +43 -0
- package/dist/messaging/presence.js.map +1 -0
- package/dist/messaging/privacy.d.ts +11 -0
- package/dist/messaging/privacy.d.ts.map +1 -0
- package/dist/messaging/privacy.js +34 -0
- package/dist/messaging/privacy.js.map +1 -0
- package/dist/messaging/profile.d.ts +13 -0
- package/dist/messaging/profile.d.ts.map +1 -0
- package/dist/messaging/profile.js +49 -0
- package/dist/messaging/profile.js.map +1 -0
- package/dist/messaging/quick-replies.d.ts +13 -0
- package/dist/messaging/quick-replies.d.ts.map +1 -0
- package/dist/messaging/quick-replies.js +45 -0
- package/dist/messaging/quick-replies.js.map +1 -0
- package/dist/messaging/quicklinks.d.ts +69 -0
- package/dist/messaging/quicklinks.d.ts.map +1 -0
- package/dist/messaging/quicklinks.js +45 -0
- package/dist/messaging/quicklinks.js.map +1 -0
- package/dist/messaging/session-configuration.d.ts +67 -0
- package/dist/messaging/session-configuration.d.ts.map +1 -0
- package/dist/messaging/session-configuration.js +2 -0
- package/dist/messaging/session-configuration.js.map +1 -0
- package/dist/messaging/sessions.d.ts +26 -0
- package/dist/messaging/sessions.d.ts.map +1 -0
- package/dist/messaging/sessions.js +108 -0
- package/dist/messaging/sessions.js.map +1 -0
- package/dist/messaging/templates.d.ts +15 -0
- package/dist/messaging/templates.d.ts.map +1 -0
- package/dist/messaging/templates.js +67 -0
- package/dist/messaging/templates.js.map +1 -0
- package/dist/messaging/testing-configuration.d.ts +89 -0
- package/dist/messaging/testing-configuration.d.ts.map +1 -0
- package/dist/messaging/testing-configuration.js +14 -0
- package/dist/messaging/testing-configuration.js.map +1 -0
- package/dist/messaging/types.d.ts +1793 -0
- package/dist/messaging/types.d.ts.map +1 -0
- package/dist/messaging/types.js +25 -0
- package/dist/messaging/types.js.map +1 -0
- package/dist/messaging/users.d.ts +9 -0
- package/dist/messaging/users.d.ts.map +1 -0
- package/dist/messaging/users.js +15 -0
- package/dist/messaging/users.js.map +1 -0
- package/dist/messaging/voip.d.ts +51 -0
- package/dist/messaging/voip.d.ts.map +1 -0
- package/dist/messaging/voip.js +293 -0
- package/dist/messaging/voip.js.map +1 -0
- package/dist/messaging/webhooks.d.ts +13 -0
- package/dist/messaging/webhooks.d.ts.map +1 -0
- package/dist/messaging/webhooks.js +48 -0
- package/dist/messaging/webhooks.js.map +1 -0
- package/dist/node.d.ts +55 -0
- package/dist/node.d.ts.map +1 -0
- package/dist/node.js +237 -0
- package/dist/node.js.map +1 -0
- package/dist/pagination.d.ts +24 -0
- package/dist/pagination.d.ts.map +1 -0
- package/dist/pagination.js +28 -0
- package/dist/pagination.js.map +1 -0
- package/dist/platform/api-keys.d.ts +10 -0
- package/dist/platform/api-keys.d.ts.map +1 -0
- package/dist/platform/api-keys.js +22 -0
- package/dist/platform/api-keys.js.map +1 -0
- package/dist/platform/audiences.d.ts +16 -0
- package/dist/platform/audiences.d.ts.map +1 -0
- package/dist/platform/audiences.js +46 -0
- package/dist/platform/audiences.js.map +1 -0
- package/dist/platform/audit-logs.d.ts +9 -0
- package/dist/platform/audit-logs.d.ts.map +1 -0
- package/dist/platform/audit-logs.js +20 -0
- package/dist/platform/audit-logs.js.map +1 -0
- package/dist/platform/bansafe.d.ts +24 -0
- package/dist/platform/bansafe.d.ts.map +1 -0
- package/dist/platform/bansafe.js +70 -0
- package/dist/platform/bansafe.js.map +1 -0
- package/dist/platform/billing.d.ts +13 -0
- package/dist/platform/billing.d.ts.map +1 -0
- package/dist/platform/billing.js +27 -0
- package/dist/platform/billing.js.map +1 -0
- package/dist/platform/campaigns.d.ts +28 -0
- package/dist/platform/campaigns.d.ts.map +1 -0
- package/dist/platform/campaigns.js +92 -0
- package/dist/platform/campaigns.js.map +1 -0
- package/dist/platform/customers.d.ts +23 -0
- package/dist/platform/customers.d.ts.map +1 -0
- package/dist/platform/customers.js +140 -0
- package/dist/platform/customers.js.map +1 -0
- package/dist/platform/developer-resources.d.ts +101 -0
- package/dist/platform/developer-resources.d.ts.map +1 -0
- package/dist/platform/developer-resources.js +250 -0
- package/dist/platform/developer-resources.js.map +1 -0
- package/dist/platform/developer-types.d.ts +378 -0
- package/dist/platform/developer-types.d.ts.map +1 -0
- package/dist/platform/developer-types.js +2 -0
- package/dist/platform/developer-types.js.map +1 -0
- package/dist/platform/event-stream.d.ts +114 -0
- package/dist/platform/event-stream.d.ts.map +1 -0
- package/dist/platform/event-stream.js +308 -0
- package/dist/platform/event-stream.js.map +1 -0
- package/dist/platform/media.d.ts +13 -0
- package/dist/platform/media.d.ts.map +1 -0
- package/dist/platform/media.js +33 -0
- package/dist/platform/media.js.map +1 -0
- package/dist/platform/members.d.ts +9 -0
- package/dist/platform/members.d.ts.map +1 -0
- package/dist/platform/members.js +15 -0
- package/dist/platform/members.js.map +1 -0
- package/dist/platform/opt-outs.d.ts +15 -0
- package/dist/platform/opt-outs.d.ts.map +1 -0
- package/dist/platform/opt-outs.js +36 -0
- package/dist/platform/opt-outs.js.map +1 -0
- package/dist/platform/organizations.d.ts +9 -0
- package/dist/platform/organizations.d.ts.map +1 -0
- package/dist/platform/organizations.js +15 -0
- package/dist/platform/organizations.js.map +1 -0
- package/dist/platform/project-tokens.d.ts +9 -0
- package/dist/platform/project-tokens.d.ts.map +1 -0
- package/dist/platform/project-tokens.js +16 -0
- package/dist/platform/project-tokens.js.map +1 -0
- package/dist/platform/projects.d.ts +24 -0
- package/dist/platform/projects.d.ts.map +1 -0
- package/dist/platform/projects.js +83 -0
- package/dist/platform/projects.js.map +1 -0
- package/dist/platform/quicklink-settings.d.ts +85 -0
- package/dist/platform/quicklink-settings.d.ts.map +1 -0
- package/dist/platform/quicklink-settings.js +35 -0
- package/dist/platform/quicklink-settings.js.map +1 -0
- package/dist/platform/response.d.ts +10 -0
- package/dist/platform/response.d.ts.map +1 -0
- package/dist/platform/response.js +41 -0
- package/dist/platform/response.js.map +1 -0
- package/dist/platform/security-incidents.d.ts +10 -0
- package/dist/platform/security-incidents.d.ts.map +1 -0
- package/dist/platform/security-incidents.js +22 -0
- package/dist/platform/security-incidents.js.map +1 -0
- package/dist/platform/session-bans.d.ts +13 -0
- package/dist/platform/session-bans.d.ts.map +1 -0
- package/dist/platform/session-bans.js +21 -0
- package/dist/platform/session-bans.js.map +1 -0
- package/dist/platform/session-configuration.d.ts +15 -0
- package/dist/platform/session-configuration.d.ts.map +1 -0
- package/dist/platform/session-configuration.js +36 -0
- package/dist/platform/session-configuration.js.map +1 -0
- package/dist/platform/sessions.d.ts +26 -0
- package/dist/platform/sessions.d.ts.map +1 -0
- package/dist/platform/sessions.js +121 -0
- package/dist/platform/sessions.js.map +1 -0
- package/dist/platform/sip-trunks.d.ts +141 -0
- package/dist/platform/sip-trunks.d.ts.map +1 -0
- package/dist/platform/sip-trunks.js +140 -0
- package/dist/platform/sip-trunks.js.map +1 -0
- package/dist/platform/types.d.ts +897 -0
- package/dist/platform/types.d.ts.map +1 -0
- package/dist/platform/types.js +2 -0
- package/dist/platform/types.js.map +1 -0
- package/dist/raw.d.ts +26 -0
- package/dist/raw.d.ts.map +1 -0
- package/dist/raw.js +79 -0
- package/dist/raw.js.map +1 -0
- package/dist/system.d.ts +37 -0
- package/dist/system.d.ts.map +1 -0
- package/dist/system.js +45 -0
- package/dist/system.js.map +1 -0
- package/dist/transport/body.d.ts +6 -0
- package/dist/transport/body.d.ts.map +1 -0
- package/dist/transport/body.js +33 -0
- package/dist/transport/body.js.map +1 -0
- package/dist/transport/content-disposition.d.ts +9 -0
- package/dist/transport/content-disposition.d.ts.map +1 -0
- package/dist/transport/content-disposition.js +107 -0
- package/dist/transport/content-disposition.js.map +1 -0
- package/dist/transport/http.d.ts +35 -0
- package/dist/transport/http.d.ts.map +1 -0
- package/dist/transport/http.js +660 -0
- package/dist/transport/http.js.map +1 -0
- package/dist/transport/idempotency.d.ts +10 -0
- package/dist/transport/idempotency.d.ts.map +1 -0
- package/dist/transport/idempotency.js +13 -0
- package/dist/transport/idempotency.js.map +1 -0
- package/dist/transport/retry.d.ts +11 -0
- package/dist/transport/retry.d.ts.map +1 -0
- package/dist/transport/retry.js +45 -0
- package/dist/transport/retry.js.map +1 -0
- package/dist/transport/types.d.ts +58 -0
- package/dist/transport/types.d.ts.map +1 -0
- package/dist/transport/types.js +2 -0
- package/dist/transport/types.js.map +1 -0
- package/dist/version.d.ts +2 -0
- package/dist/version.d.ts.map +1 -0
- package/dist/version.js +2 -0
- package/dist/version.js.map +1 -0
- package/dist/webhooks/events.d.ts +741 -0
- package/dist/webhooks/events.d.ts.map +1 -0
- package/dist/webhooks/events.js +80 -0
- package/dist/webhooks/events.js.map +1 -0
- package/dist/webhooks/index.d.ts +4 -0
- package/dist/webhooks/index.d.ts.map +1 -0
- package/dist/webhooks/index.js +4 -0
- package/dist/webhooks/index.js.map +1 -0
- package/dist/webhooks/utilities.d.ts +33 -0
- package/dist/webhooks/utilities.d.ts.map +1 -0
- package/dist/webhooks/utilities.js +67 -0
- package/dist/webhooks/utilities.js.map +1 -0
- package/dist/webhooks/verify.d.ts +9 -0
- package/dist/webhooks/verify.d.ts.map +1 -0
- package/dist/webhooks/verify.js +77 -0
- package/dist/webhooks/verify.js.map +1 -0
- package/package.json +58 -0
|
@@ -0,0 +1,250 @@
|
|
|
1
|
+
import { PolymorfaConfigurationError } from "../errors.js";
|
|
2
|
+
import { CursorPage } from "../pagination.js";
|
|
3
|
+
import { RawClient } from "../raw.js";
|
|
4
|
+
import { HttpTransport } from "../transport/http.js";
|
|
5
|
+
import { withIdempotencyKey } from "../transport/idempotency.js";
|
|
6
|
+
import { EventStream, eventStreamSource, } from "./event-stream.js";
|
|
7
|
+
import { decodeCursorPage, unwrapResponse, } from "./response.js";
|
|
8
|
+
class ResourceBase {
|
|
9
|
+
transport;
|
|
10
|
+
prefix;
|
|
11
|
+
raw;
|
|
12
|
+
constructor(transport, prefix) {
|
|
13
|
+
this.transport = transport;
|
|
14
|
+
this.prefix = prefix;
|
|
15
|
+
this.raw = new RawClient(transport);
|
|
16
|
+
}
|
|
17
|
+
path(suffix) {
|
|
18
|
+
return `${this.prefix}${suffix}`;
|
|
19
|
+
}
|
|
20
|
+
async fetchResource(path, options) {
|
|
21
|
+
return unwrapResponse(await this.transport.request({
|
|
22
|
+
method: "GET",
|
|
23
|
+
path,
|
|
24
|
+
...options,
|
|
25
|
+
}));
|
|
26
|
+
}
|
|
27
|
+
async mutate(method, path, body, options) {
|
|
28
|
+
return unwrapResponse(await this.transport.request({
|
|
29
|
+
method,
|
|
30
|
+
path,
|
|
31
|
+
...(body === undefined ? {} : { body }),
|
|
32
|
+
...options,
|
|
33
|
+
}));
|
|
34
|
+
}
|
|
35
|
+
page(path, query, options) {
|
|
36
|
+
return this.raw.paginate({ method: "GET", path, query: query, ...options }, (decodeCursorPage));
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
export class EventsResource extends ResourceBase {
|
|
40
|
+
list(params = {}, options = {}) {
|
|
41
|
+
return this.page(this.path("/events"), { ...params }, options);
|
|
42
|
+
}
|
|
43
|
+
retrieve(eventId, params = {}, options = {}) {
|
|
44
|
+
return this.transport
|
|
45
|
+
.request({
|
|
46
|
+
method: "GET",
|
|
47
|
+
path: this.path(`/events/${encodeURIComponent(eventId)}`),
|
|
48
|
+
query: params,
|
|
49
|
+
...options,
|
|
50
|
+
})
|
|
51
|
+
.then(unwrapResponse);
|
|
52
|
+
}
|
|
53
|
+
replay(eventId, input, options = {}) {
|
|
54
|
+
return this.mutate("POST", this.path(`/events/${encodeURIComponent(eventId)}/replays`), input, options);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Streams a project's events over server-sent events with automatic
|
|
58
|
+
* reconnect and resume. Requires `events:listen` and the Event streams
|
|
59
|
+
* beta. Organization clients pass `projectId`.
|
|
60
|
+
*/
|
|
61
|
+
stream(params = {}) {
|
|
62
|
+
return new EventStream(this.transport, this.streamPath(params), params);
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* Acknowledges every event up to `sequence` on a stream opened with
|
|
66
|
+
* `ack: "manual"`. Use the same credential that opened the stream.
|
|
67
|
+
*/
|
|
68
|
+
acknowledgeStream(streamId, input, options = {}) {
|
|
69
|
+
const body = { cursor: input.cursor, sequence: input.sequence };
|
|
70
|
+
const base = this.streamPath(input);
|
|
71
|
+
return this.transport
|
|
72
|
+
.request({
|
|
73
|
+
method: "POST",
|
|
74
|
+
path: `${base}/${encodeURIComponent(streamId)}/ack`,
|
|
75
|
+
body,
|
|
76
|
+
...options,
|
|
77
|
+
})
|
|
78
|
+
.then(unwrapResponse);
|
|
79
|
+
}
|
|
80
|
+
/** A `@polymorfa/store` live source over `stream()`; see `eventStreamSource`. */
|
|
81
|
+
liveSource(params = {}) {
|
|
82
|
+
return eventStreamSource((next) => this.stream({ ...params, ...next }), params);
|
|
83
|
+
}
|
|
84
|
+
streamPath(params) {
|
|
85
|
+
if (this.prefix.startsWith("/platform/projects/"))
|
|
86
|
+
return this.path("/events/stream");
|
|
87
|
+
const projectId = params
|
|
88
|
+
.projectId;
|
|
89
|
+
if (typeof projectId !== "string" || projectId.trim() === "") {
|
|
90
|
+
throw new PolymorfaConfigurationError("Organization clients must pass projectId to stream events.", "projectId");
|
|
91
|
+
}
|
|
92
|
+
return `/platform/projects/${encodeURIComponent(projectId)}/events/stream`;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
export class WebhooksResource extends ResourceBase {
|
|
96
|
+
list(params = {}, options = {}) {
|
|
97
|
+
return this.page(this.path("/webhooks"), { ...params }, options);
|
|
98
|
+
}
|
|
99
|
+
create(input, options = {}) {
|
|
100
|
+
return this.mutate("POST", this.path("/webhooks"), input, options);
|
|
101
|
+
}
|
|
102
|
+
retrieve(webhookId, options = {}) {
|
|
103
|
+
return this.fetchResource(this.path(`/webhooks/${encodeURIComponent(webhookId)}`), options);
|
|
104
|
+
}
|
|
105
|
+
update(webhookId, input, options = {}) {
|
|
106
|
+
return this.mutate("PATCH", this.path(`/webhooks/${encodeURIComponent(webhookId)}`), input, options);
|
|
107
|
+
}
|
|
108
|
+
delete(webhookId, options = {}) {
|
|
109
|
+
return this.mutate("DELETE", this.path(`/webhooks/${encodeURIComponent(webhookId)}`), undefined, options);
|
|
110
|
+
}
|
|
111
|
+
test(webhookId, input = {}, options = {}) {
|
|
112
|
+
return this.mutate("POST", this.path(`/webhooks/${encodeURIComponent(webhookId)}/tests`), input, options);
|
|
113
|
+
}
|
|
114
|
+
rotateSecret(webhookId, input = {}, options = {}) {
|
|
115
|
+
return this.mutate("POST", this.path(`/webhooks/${encodeURIComponent(webhookId)}/secret-rotations`), input, options);
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
export class WebhookDeliveriesResource extends ResourceBase {
|
|
119
|
+
list(params = {}, options = {}) {
|
|
120
|
+
return this.page(this.path("/webhook-deliveries"), { ...params }, options);
|
|
121
|
+
}
|
|
122
|
+
retrieve(deliveryId, options = {}) {
|
|
123
|
+
return this.fetchResource(this.path(`/webhook-deliveries/${encodeURIComponent(deliveryId)}`), options);
|
|
124
|
+
}
|
|
125
|
+
listAttempts(deliveryId, params = {}, options = {}) {
|
|
126
|
+
return this.page(this.path(`/webhook-deliveries/${encodeURIComponent(deliveryId)}/attempts`), { ...params }, options);
|
|
127
|
+
}
|
|
128
|
+
retrieveAttempt(deliveryId, attemptId, options = {}) {
|
|
129
|
+
return this.fetchResource(this.path(`/webhook-deliveries/${encodeURIComponent(deliveryId)}/attempts/${encodeURIComponent(attemptId)}`), options);
|
|
130
|
+
}
|
|
131
|
+
retry(deliveryId, input = {}, options = {}) {
|
|
132
|
+
return this.mutate("POST", this.path(`/webhook-deliveries/${encodeURIComponent(deliveryId)}/retry`), input, options);
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
const TERMINAL_OPERATION_STATUSES = new Set([
|
|
136
|
+
"succeeded",
|
|
137
|
+
"failed",
|
|
138
|
+
"cancelled",
|
|
139
|
+
]);
|
|
140
|
+
/** Longest server-side wait for one request, in seconds. */
|
|
141
|
+
export const OPERATION_WAIT_MAX_SECONDS = 30;
|
|
142
|
+
/**
|
|
143
|
+
* Asynchronous operations (campaign sends, production enrollments, and other
|
|
144
|
+
* durable work). Organization clients see team and project operations;
|
|
145
|
+
* project clients see only their project. Requires `operations:read`;
|
|
146
|
+
* `cancel` requires `operations:cancel`.
|
|
147
|
+
*/
|
|
148
|
+
export class OperationsResource extends ResourceBase {
|
|
149
|
+
list(params = {}, options = {}) {
|
|
150
|
+
return this.page(this.path("/operations"), { ...params }, options);
|
|
151
|
+
}
|
|
152
|
+
/** Gets one operation. `params.wait` long-polls for up to 30 seconds. */
|
|
153
|
+
get(operationId, params = {}, options = {}) {
|
|
154
|
+
if (params.wait !== undefined &&
|
|
155
|
+
(!Number.isInteger(params.wait) ||
|
|
156
|
+
params.wait < 0 ||
|
|
157
|
+
params.wait > OPERATION_WAIT_MAX_SECONDS)) {
|
|
158
|
+
throw new PolymorfaConfigurationError(`wait must be an integer between 0 and ${OPERATION_WAIT_MAX_SECONDS}.`, "wait");
|
|
159
|
+
}
|
|
160
|
+
const wait = params.wait ?? 0;
|
|
161
|
+
return this.transport
|
|
162
|
+
.request({
|
|
163
|
+
method: "GET",
|
|
164
|
+
path: this.path(`/operations/${encodeURIComponent(operationId)}`),
|
|
165
|
+
query: { ...params },
|
|
166
|
+
...options,
|
|
167
|
+
// The request stays open for the wait; leave headroom for the response.
|
|
168
|
+
...(wait > 0 && options.timeoutMs === undefined
|
|
169
|
+
? { timeoutMs: (wait + 15) * 1000 }
|
|
170
|
+
: {}),
|
|
171
|
+
})
|
|
172
|
+
.then(unwrapResponse);
|
|
173
|
+
}
|
|
174
|
+
listTransitions(operationId, params = {}, options = {}) {
|
|
175
|
+
return this.page(this.path(`/operations/${encodeURIComponent(operationId)}/transitions`), { ...params }, options);
|
|
176
|
+
}
|
|
177
|
+
/**
|
|
178
|
+
* Requests cancellation. Only operations whose `capabilities.cancellable`
|
|
179
|
+
* is true accept it; others fail with 409 `operation_conflict`. An
|
|
180
|
+
* Idempotency-Key is generated when `options.idempotencyKey` is omitted.
|
|
181
|
+
*/
|
|
182
|
+
cancel(operationId, options = {}) {
|
|
183
|
+
return this.mutate("POST", this.path(`/operations/${encodeURIComponent(operationId)}/cancel`), undefined, withIdempotencyKey(options));
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* Waits until the operation is terminal (`succeeded`, `failed`,
|
|
187
|
+
* `cancelled`), its sequence passes `afterSequence`, or `maxWaitMs`
|
|
188
|
+
* (default 5 minutes) elapses, using server long-polls. Returns the latest
|
|
189
|
+
* state; check `status`, because the wait can end first.
|
|
190
|
+
*/
|
|
191
|
+
async wait(operationId, options = {}) {
|
|
192
|
+
const maxWaitMs = options.maxWaitMs ?? 5 * 60_000;
|
|
193
|
+
if (!Number.isFinite(maxWaitMs) || maxWaitMs < 0) {
|
|
194
|
+
throw new PolymorfaConfigurationError("maxWaitMs must be a finite, non-negative number of milliseconds.", "maxWaitMs");
|
|
195
|
+
}
|
|
196
|
+
const deadline = Date.now() + maxWaitMs;
|
|
197
|
+
let latest;
|
|
198
|
+
for (;;) {
|
|
199
|
+
options.signal?.throwIfAborted();
|
|
200
|
+
const remaining = Math.max(0, deadline - Date.now());
|
|
201
|
+
const wait = Math.min(OPERATION_WAIT_MAX_SECONDS, Math.floor(remaining / 1000));
|
|
202
|
+
// Bound the request itself by what is left of the budget, so a server
|
|
203
|
+
// that holds the connection open cannot extend the wait. The last read
|
|
204
|
+
// still gets a second to answer, so a spent budget returns real state
|
|
205
|
+
// instead of an abort.
|
|
206
|
+
const budget = new AbortController();
|
|
207
|
+
const timer = setTimeout(() => budget.abort(), Math.max(remaining, 1_000));
|
|
208
|
+
const abortBudget = () => budget.abort(options.signal?.reason);
|
|
209
|
+
options.signal?.addEventListener("abort", abortBudget, { once: true });
|
|
210
|
+
let response;
|
|
211
|
+
try {
|
|
212
|
+
response = await this.get(operationId, {
|
|
213
|
+
wait,
|
|
214
|
+
...(options.projectId ===
|
|
215
|
+
undefined
|
|
216
|
+
? {}
|
|
217
|
+
: {
|
|
218
|
+
projectId: options
|
|
219
|
+
.projectId,
|
|
220
|
+
}),
|
|
221
|
+
...(options.afterSequence === undefined
|
|
222
|
+
? {}
|
|
223
|
+
: { afterSequence: options.afterSequence }),
|
|
224
|
+
}, { ...options.requestOptions, signal: budget.signal });
|
|
225
|
+
}
|
|
226
|
+
catch (error) {
|
|
227
|
+
// The caller's own abort always propagates. A budget abort returns the
|
|
228
|
+
// last state this wait observed, and only fails when it has none.
|
|
229
|
+
options.signal?.throwIfAborted();
|
|
230
|
+
if (!budget.signal.aborted || latest === undefined)
|
|
231
|
+
throw error;
|
|
232
|
+
return latest;
|
|
233
|
+
}
|
|
234
|
+
finally {
|
|
235
|
+
clearTimeout(timer);
|
|
236
|
+
options.signal?.removeEventListener("abort", abortBudget);
|
|
237
|
+
}
|
|
238
|
+
latest = response;
|
|
239
|
+
const operation = response.data;
|
|
240
|
+
if (TERMINAL_OPERATION_STATUSES.has(operation.status) ||
|
|
241
|
+
(options.afterSequence !== undefined &&
|
|
242
|
+
operation.sequence > options.afterSequence) ||
|
|
243
|
+
wait === 0 ||
|
|
244
|
+
Date.now() >= deadline) {
|
|
245
|
+
return response;
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
//# sourceMappingURL=developer-resources.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"developer-resources.js","sourceRoot":"","sources":["../../src/platform/developer-resources.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAC3D,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAErD,OAAO,EAAE,kBAAkB,EAAE,MAAM,6B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AG,CAAC,SAAS,CAAC,MAAM,CAAC;gBACjD,CAAC,OAAO,CAAC,aAAa,KAAK,SAAS;oBAClC,SAAS,CAAC,QAAQ,GAAG,OAAO,CAAC,aAAa,CAAC;gBAC7C,IAAI,KAAK,CAAC;gBACV,IAAI,CAAC,GAAG,EAAE,IAAI,QAAQ,EACtB,CAAC;gBACD,OAAO,QAAQ,CAAC;YAClB,CAAC;QACH,CAAC;IACH,CAAC;CACF"}
|
|
@@ -0,0 +1,378 @@
|
|
|
1
|
+
import type { RequestOptions } from "../transport/types.js";
|
|
2
|
+
export type ClientOwner = "organization" | "project";
|
|
3
|
+
export type JsonValue = null | boolean | number | string | readonly JsonValue[] | {
|
|
4
|
+
readonly [key: string]: JsonValue;
|
|
5
|
+
};
|
|
6
|
+
export interface EncodedEventPayload {
|
|
7
|
+
readonly encoding: "base64";
|
|
8
|
+
readonly contentType: "application/json";
|
|
9
|
+
readonly data: string;
|
|
10
|
+
}
|
|
11
|
+
export type PayloadAvailability = "available" | "not_retained" | "expired" | "redacted" | "unavailable";
|
|
12
|
+
interface EventBase {
|
|
13
|
+
readonly id: string;
|
|
14
|
+
readonly organizationId: string;
|
|
15
|
+
readonly type: string;
|
|
16
|
+
readonly source: "runtime" | "platform" | "test";
|
|
17
|
+
readonly environment: "development" | "production";
|
|
18
|
+
readonly createdAt: string;
|
|
19
|
+
readonly payloadAvailability: PayloadAvailability;
|
|
20
|
+
readonly payload: EncodedEventPayload | null;
|
|
21
|
+
readonly replayableUntil: string | null;
|
|
22
|
+
readonly metadataExpiresAt: string;
|
|
23
|
+
}
|
|
24
|
+
export interface OrganizationEvent extends EventBase {
|
|
25
|
+
readonly projectId: null;
|
|
26
|
+
}
|
|
27
|
+
export interface ProjectEvent extends EventBase {
|
|
28
|
+
readonly projectId: string;
|
|
29
|
+
}
|
|
30
|
+
export interface ListEventsParams {
|
|
31
|
+
readonly type?: string;
|
|
32
|
+
readonly since?: string;
|
|
33
|
+
readonly until?: string;
|
|
34
|
+
readonly limit?: number;
|
|
35
|
+
readonly cursor?: string;
|
|
36
|
+
}
|
|
37
|
+
export type ListOrganizationEventsParams = ListEventsParams;
|
|
38
|
+
export interface RetrieveEventParams {
|
|
39
|
+
readonly includePayload?: boolean;
|
|
40
|
+
}
|
|
41
|
+
export interface ReplayEventInput {
|
|
42
|
+
readonly webhookId: string;
|
|
43
|
+
}
|
|
44
|
+
export type ReplayOrganizationEventInput = ReplayEventInput;
|
|
45
|
+
export interface IdempotencyReceipt {
|
|
46
|
+
readonly id: string;
|
|
47
|
+
readonly key: string;
|
|
48
|
+
readonly replayed: boolean;
|
|
49
|
+
readonly createdAt: string;
|
|
50
|
+
readonly expiresAt: string;
|
|
51
|
+
}
|
|
52
|
+
interface ReplayReceipt {
|
|
53
|
+
readonly eventId: string;
|
|
54
|
+
readonly deliveryId: string;
|
|
55
|
+
readonly operationId: string;
|
|
56
|
+
readonly idempotency: IdempotencyReceipt;
|
|
57
|
+
}
|
|
58
|
+
export type ProjectEventReplayReceipt = ReplayReceipt;
|
|
59
|
+
export type OrganizationEventReplayReceipt = ReplayReceipt;
|
|
60
|
+
export interface WebhookRetryPolicyInput {
|
|
61
|
+
readonly maximumAttempts: number;
|
|
62
|
+
readonly backoff: "constant" | "linear" | "exponential";
|
|
63
|
+
readonly initialDelaySeconds: number;
|
|
64
|
+
}
|
|
65
|
+
export type WebhookRetryPolicy = WebhookRetryPolicyInput;
|
|
66
|
+
export interface WebhookHeaderInput {
|
|
67
|
+
readonly name: string;
|
|
68
|
+
readonly value: string;
|
|
69
|
+
}
|
|
70
|
+
export interface WebhookHeaderMetadata {
|
|
71
|
+
readonly name: string;
|
|
72
|
+
}
|
|
73
|
+
export interface WebhookSigningSecretMetadata {
|
|
74
|
+
readonly version: number;
|
|
75
|
+
readonly createdAt: string;
|
|
76
|
+
readonly previousValidUntil: string | null;
|
|
77
|
+
}
|
|
78
|
+
interface WebhookBase {
|
|
79
|
+
readonly id: string;
|
|
80
|
+
readonly organizationId: string;
|
|
81
|
+
readonly url: string;
|
|
82
|
+
readonly eventTypes: readonly string[];
|
|
83
|
+
readonly enabled: boolean;
|
|
84
|
+
readonly format: "native" | "meta";
|
|
85
|
+
readonly retryPolicy: WebhookRetryPolicy;
|
|
86
|
+
readonly headers: readonly WebhookHeaderMetadata[];
|
|
87
|
+
readonly secret: WebhookSigningSecretMetadata;
|
|
88
|
+
readonly createdAt: string;
|
|
89
|
+
readonly updatedAt: string;
|
|
90
|
+
}
|
|
91
|
+
export interface OrganizationWebhook extends WebhookBase {
|
|
92
|
+
readonly owner: "organization";
|
|
93
|
+
readonly projectId: null;
|
|
94
|
+
}
|
|
95
|
+
export interface ProjectWebhook extends WebhookBase {
|
|
96
|
+
readonly owner: "project";
|
|
97
|
+
readonly projectId: string;
|
|
98
|
+
}
|
|
99
|
+
interface CreateWebhookInputBase {
|
|
100
|
+
readonly url: string;
|
|
101
|
+
readonly eventTypes: readonly string[];
|
|
102
|
+
readonly enabled?: boolean;
|
|
103
|
+
readonly format?: "native" | "meta";
|
|
104
|
+
readonly retryPolicy?: WebhookRetryPolicyInput;
|
|
105
|
+
readonly headers?: readonly WebhookHeaderInput[];
|
|
106
|
+
}
|
|
107
|
+
export type CreateOrganizationWebhookInput = CreateWebhookInputBase;
|
|
108
|
+
export type CreateProjectWebhookInput = CreateWebhookInputBase;
|
|
109
|
+
interface UpdateWebhookInputBase {
|
|
110
|
+
readonly url?: string;
|
|
111
|
+
readonly eventTypes?: readonly string[];
|
|
112
|
+
readonly enabled?: boolean;
|
|
113
|
+
readonly format?: "native" | "meta";
|
|
114
|
+
readonly retryPolicy?: WebhookRetryPolicyInput;
|
|
115
|
+
readonly headers?: readonly WebhookHeaderInput[];
|
|
116
|
+
}
|
|
117
|
+
export type UpdateOrganizationWebhookInput = UpdateWebhookInputBase;
|
|
118
|
+
export type UpdateProjectWebhookInput = UpdateWebhookInputBase;
|
|
119
|
+
export interface ListWebhooksParams {
|
|
120
|
+
readonly eventType?: string;
|
|
121
|
+
readonly enabled?: boolean;
|
|
122
|
+
readonly limit?: number;
|
|
123
|
+
readonly cursor?: string;
|
|
124
|
+
}
|
|
125
|
+
export type ListOrganizationWebhooksParams = ListWebhooksParams;
|
|
126
|
+
export interface RotateWebhookSecretInput {
|
|
127
|
+
readonly overlapSeconds?: number;
|
|
128
|
+
}
|
|
129
|
+
export type RetryWebhookDeliveryInput = Readonly<Record<string, never>>;
|
|
130
|
+
export type TestWebhookInput = {
|
|
131
|
+
readonly eventType?: string;
|
|
132
|
+
readonly body?: never;
|
|
133
|
+
readonly sessionId?: never;
|
|
134
|
+
} | {
|
|
135
|
+
readonly eventType?: string;
|
|
136
|
+
readonly body: EncodedEventPayload;
|
|
137
|
+
readonly sessionId: string;
|
|
138
|
+
};
|
|
139
|
+
interface WebhookCreationReceipt<T> {
|
|
140
|
+
readonly webhook: T;
|
|
141
|
+
readonly operationId: null;
|
|
142
|
+
readonly idempotency: IdempotencyReceipt;
|
|
143
|
+
readonly secret: string | null;
|
|
144
|
+
readonly secretAvailable: boolean;
|
|
145
|
+
}
|
|
146
|
+
export type OrganizationWebhookCreationReceipt = WebhookCreationReceipt<OrganizationWebhook>;
|
|
147
|
+
export type ProjectWebhookCreationReceipt = WebhookCreationReceipt<ProjectWebhook>;
|
|
148
|
+
interface WebhookMutationReceipt<T> {
|
|
149
|
+
readonly webhook: T;
|
|
150
|
+
readonly operationId: null;
|
|
151
|
+
readonly idempotency: IdempotencyReceipt;
|
|
152
|
+
}
|
|
153
|
+
export type OrganizationWebhookMutationReceipt = WebhookMutationReceipt<OrganizationWebhook>;
|
|
154
|
+
export type ProjectWebhookMutationReceipt = WebhookMutationReceipt<ProjectWebhook>;
|
|
155
|
+
interface WebhookDeletionReceipt {
|
|
156
|
+
readonly webhookId: string;
|
|
157
|
+
readonly deleted: true;
|
|
158
|
+
readonly operationId: null;
|
|
159
|
+
readonly idempotency: IdempotencyReceipt;
|
|
160
|
+
}
|
|
161
|
+
export type OrganizationWebhookDeletionReceipt = WebhookDeletionReceipt;
|
|
162
|
+
export type ProjectWebhookDeletionReceipt = WebhookDeletionReceipt;
|
|
163
|
+
interface WebhookSecretRotationReceipt {
|
|
164
|
+
readonly webhookId: string;
|
|
165
|
+
readonly operationId: null;
|
|
166
|
+
readonly secret: string | null;
|
|
167
|
+
readonly secretAvailable: boolean;
|
|
168
|
+
readonly secretMetadata: WebhookSigningSecretMetadata;
|
|
169
|
+
readonly idempotency: IdempotencyReceipt;
|
|
170
|
+
}
|
|
171
|
+
export type OrganizationWebhookSecretRotationReceipt = WebhookSecretRotationReceipt;
|
|
172
|
+
export type ProjectWebhookSecretRotationReceipt = WebhookSecretRotationReceipt;
|
|
173
|
+
export type OrganizationWebhookTestReceipt = ReplayReceipt;
|
|
174
|
+
export type ProjectWebhookTestReceipt = ReplayReceipt;
|
|
175
|
+
export type WebhookDeliveryStatus = "pending" | "delivering" | "retrying" | "succeeded" | "failed";
|
|
176
|
+
interface WebhookDeliveryBase {
|
|
177
|
+
readonly id: string;
|
|
178
|
+
readonly organizationId: string;
|
|
179
|
+
readonly eventId: string;
|
|
180
|
+
readonly webhookId: string;
|
|
181
|
+
readonly status: WebhookDeliveryStatus;
|
|
182
|
+
readonly attemptCount: number;
|
|
183
|
+
readonly capabilities: {
|
|
184
|
+
readonly retryable: boolean;
|
|
185
|
+
};
|
|
186
|
+
readonly payloadAvailability: PayloadAvailability;
|
|
187
|
+
readonly replayableUntil: string | null;
|
|
188
|
+
readonly metadataExpiresAt: string;
|
|
189
|
+
readonly nextAttemptAt: string | null;
|
|
190
|
+
readonly lastAttemptAt: string | null;
|
|
191
|
+
readonly completedAt: string | null;
|
|
192
|
+
readonly createdAt: string;
|
|
193
|
+
readonly updatedAt: string;
|
|
194
|
+
readonly lastOutcome: {
|
|
195
|
+
readonly statusCode: number | null;
|
|
196
|
+
readonly errorCode: string | null;
|
|
197
|
+
} | null;
|
|
198
|
+
}
|
|
199
|
+
export interface OrganizationWebhookDelivery extends WebhookDeliveryBase {
|
|
200
|
+
readonly projectId: null;
|
|
201
|
+
}
|
|
202
|
+
export interface ProjectWebhookDelivery extends WebhookDeliveryBase {
|
|
203
|
+
readonly projectId: string;
|
|
204
|
+
}
|
|
205
|
+
export interface ListWebhookDeliveriesParams {
|
|
206
|
+
readonly webhookId?: string;
|
|
207
|
+
readonly eventId?: string;
|
|
208
|
+
readonly status?: WebhookDeliveryStatus;
|
|
209
|
+
readonly since?: string;
|
|
210
|
+
readonly until?: string;
|
|
211
|
+
readonly limit?: number;
|
|
212
|
+
readonly cursor?: string;
|
|
213
|
+
}
|
|
214
|
+
export type ListOrganizationWebhookDeliveriesParams = ListWebhookDeliveriesParams;
|
|
215
|
+
export interface ListDeliveryAttemptsParams {
|
|
216
|
+
readonly limit?: number;
|
|
217
|
+
readonly cursor?: string;
|
|
218
|
+
}
|
|
219
|
+
interface WebhookDeliveryAttemptBase {
|
|
220
|
+
readonly id: string;
|
|
221
|
+
readonly organizationId: string;
|
|
222
|
+
readonly deliveryId: string;
|
|
223
|
+
readonly number: number;
|
|
224
|
+
readonly status: "pending" | "delivering" | "succeeded" | "failed";
|
|
225
|
+
readonly startedAt: string | null;
|
|
226
|
+
readonly completedAt: string | null;
|
|
227
|
+
readonly nextRetryAt: string | null;
|
|
228
|
+
readonly durationMs: number | null;
|
|
229
|
+
readonly statusCode: number | null;
|
|
230
|
+
readonly errorCode: string | null;
|
|
231
|
+
/** Redacted excerpt from a failed HTTP response; null for successes and network errors. */
|
|
232
|
+
readonly response: WebhookDeliveryAttemptResponse | null;
|
|
233
|
+
readonly metadataExpiresAt: string;
|
|
234
|
+
}
|
|
235
|
+
export interface WebhookDeliveryAttemptResponse {
|
|
236
|
+
readonly contentType: string;
|
|
237
|
+
/** Redacted response text, limited to 8192 UTF-8 bytes. */
|
|
238
|
+
readonly excerpt: string;
|
|
239
|
+
readonly truncated: boolean;
|
|
240
|
+
}
|
|
241
|
+
export interface OrganizationWebhookDeliveryAttempt extends WebhookDeliveryAttemptBase {
|
|
242
|
+
readonly projectId: null;
|
|
243
|
+
}
|
|
244
|
+
export interface ProjectWebhookDeliveryAttempt extends WebhookDeliveryAttemptBase {
|
|
245
|
+
readonly projectId: string;
|
|
246
|
+
}
|
|
247
|
+
interface WebhookDeliveryRetryReceipt {
|
|
248
|
+
readonly deliveryId: string;
|
|
249
|
+
readonly attemptId: string;
|
|
250
|
+
readonly operationId: string;
|
|
251
|
+
readonly idempotency: IdempotencyReceipt;
|
|
252
|
+
}
|
|
253
|
+
export type OrganizationWebhookDeliveryRetryReceipt = WebhookDeliveryRetryReceipt;
|
|
254
|
+
export type ProjectWebhookDeliveryRetryReceipt = WebhookDeliveryRetryReceipt;
|
|
255
|
+
export type OperationStatus = "pending" | "running" | "action_required" | "cancelling" | "succeeded" | "failed" | "cancelled";
|
|
256
|
+
export type OperationKind = "auth_projection_repair" | "session_lifecycle" | "auth_session_purge" | "label_projection_purge" | "billing_reconciliation" | "auto_top_up" | "campaign" | "production_enrollment" | "retention_sweep" | "webhook_redrive";
|
|
257
|
+
export interface OperationProgress {
|
|
258
|
+
readonly code: string;
|
|
259
|
+
readonly current: number | null;
|
|
260
|
+
readonly total: number | null;
|
|
261
|
+
}
|
|
262
|
+
export interface OperationError {
|
|
263
|
+
readonly code: string;
|
|
264
|
+
readonly retryable: boolean;
|
|
265
|
+
readonly details: Readonly<Record<string, JsonValue>> | null;
|
|
266
|
+
}
|
|
267
|
+
export interface OperationActionRequired {
|
|
268
|
+
readonly code: string;
|
|
269
|
+
readonly details: Readonly<Record<string, JsonValue>> | null;
|
|
270
|
+
}
|
|
271
|
+
interface OperationBase {
|
|
272
|
+
readonly id: string;
|
|
273
|
+
readonly organizationId: string;
|
|
274
|
+
readonly kind: OperationKind;
|
|
275
|
+
readonly resource: {
|
|
276
|
+
readonly type: string;
|
|
277
|
+
readonly id: string;
|
|
278
|
+
};
|
|
279
|
+
readonly status: OperationStatus;
|
|
280
|
+
readonly sequence: number;
|
|
281
|
+
readonly capabilities: {
|
|
282
|
+
readonly cancellable: boolean;
|
|
283
|
+
readonly watchable: boolean;
|
|
284
|
+
};
|
|
285
|
+
readonly progress: OperationProgress | null;
|
|
286
|
+
readonly result: JsonValue;
|
|
287
|
+
readonly error: OperationError | null;
|
|
288
|
+
readonly actionRequired: OperationActionRequired | null;
|
|
289
|
+
readonly createdAt: string;
|
|
290
|
+
readonly updatedAt: string;
|
|
291
|
+
readonly completedAt: string | null;
|
|
292
|
+
}
|
|
293
|
+
export interface OrganizationOperation extends OperationBase {
|
|
294
|
+
readonly projectId: null;
|
|
295
|
+
}
|
|
296
|
+
export interface ProjectOperation extends OperationBase {
|
|
297
|
+
readonly projectId: string;
|
|
298
|
+
}
|
|
299
|
+
export type ManagementOperation = OrganizationOperation | ProjectOperation;
|
|
300
|
+
export type ManagementOperationStatus = OperationStatus;
|
|
301
|
+
export type ManagementOperationKind = OperationKind;
|
|
302
|
+
export type ManagementOperationProgress = OperationProgress;
|
|
303
|
+
export type ManagementOperationError = OperationError;
|
|
304
|
+
export type ManagementOperationActionRequired = OperationActionRequired;
|
|
305
|
+
export interface ListOperationsParams {
|
|
306
|
+
readonly status?: OperationStatus;
|
|
307
|
+
readonly kind?: OperationKind;
|
|
308
|
+
readonly resourceType?: string;
|
|
309
|
+
readonly resourceId?: string;
|
|
310
|
+
readonly since?: string;
|
|
311
|
+
readonly until?: string;
|
|
312
|
+
readonly limit?: number;
|
|
313
|
+
readonly cursor?: string;
|
|
314
|
+
}
|
|
315
|
+
/** Organization clients may narrow the list to one project. */
|
|
316
|
+
export interface ListOrganizationOperationsParams extends ListOperationsParams {
|
|
317
|
+
readonly projectId?: string;
|
|
318
|
+
}
|
|
319
|
+
export interface RetrieveOperationParams {
|
|
320
|
+
/** Hold the request up to this many seconds (0-30) while the operation is not terminal. */
|
|
321
|
+
readonly wait?: number;
|
|
322
|
+
/** With `wait`, return as soon as the operation's sequence exceeds this value. */
|
|
323
|
+
readonly afterSequence?: number;
|
|
324
|
+
}
|
|
325
|
+
/**
|
|
326
|
+
* Organization clients may narrow the read to one project. The project route
|
|
327
|
+
* takes its project from the path, so it has no such parameter.
|
|
328
|
+
*/
|
|
329
|
+
export interface RetrieveOrganizationOperationParams extends RetrieveOperationParams {
|
|
330
|
+
readonly projectId?: string;
|
|
331
|
+
}
|
|
332
|
+
export type ListOperationTransitionsParams = {
|
|
333
|
+
readonly afterSequence?: number;
|
|
334
|
+
readonly cursor?: never;
|
|
335
|
+
readonly limit?: number;
|
|
336
|
+
} | {
|
|
337
|
+
readonly cursor: string;
|
|
338
|
+
readonly afterSequence?: never;
|
|
339
|
+
readonly limit?: number;
|
|
340
|
+
};
|
|
341
|
+
export interface OperationTransition {
|
|
342
|
+
readonly operationId: string;
|
|
343
|
+
readonly sequence: number;
|
|
344
|
+
readonly fromStatus: OperationStatus | null;
|
|
345
|
+
readonly toStatus: OperationStatus;
|
|
346
|
+
readonly reasonCode: string | null;
|
|
347
|
+
readonly occurredAt: string;
|
|
348
|
+
readonly snapshot: {
|
|
349
|
+
readonly progress: OperationProgress | null;
|
|
350
|
+
readonly error: OperationError | null;
|
|
351
|
+
readonly actionRequired: OperationActionRequired | null;
|
|
352
|
+
};
|
|
353
|
+
}
|
|
354
|
+
export type OrganizationOperationTransition = OperationTransition;
|
|
355
|
+
export type ProjectOperationTransition = OperationTransition;
|
|
356
|
+
interface OperationCancellationReceipt<T> {
|
|
357
|
+
readonly operation: T;
|
|
358
|
+
readonly operationId: string;
|
|
359
|
+
readonly idempotency: IdempotencyReceipt;
|
|
360
|
+
}
|
|
361
|
+
export type OrganizationOperationCancellationReceipt = OperationCancellationReceipt<ManagementOperation>;
|
|
362
|
+
export type ProjectOperationCancellationReceipt = OperationCancellationReceipt<ProjectOperation>;
|
|
363
|
+
export interface WaitForOperationOptions {
|
|
364
|
+
/** Total time to wait before returning the current state. Default 5 minutes. */
|
|
365
|
+
readonly maxWaitMs?: number;
|
|
366
|
+
/** Return as soon as the operation's sequence exceeds this value. */
|
|
367
|
+
readonly afterSequence?: number;
|
|
368
|
+
/** Deprecated: the API long-polls, so polling intervals are ignored. */
|
|
369
|
+
readonly pollIntervalMs?: number;
|
|
370
|
+
readonly requestOptions?: Omit<RequestOptions, "signal">;
|
|
371
|
+
readonly signal?: AbortSignal;
|
|
372
|
+
}
|
|
373
|
+
/** Organization clients may narrow the wait to one project. */
|
|
374
|
+
export interface WaitForOrganizationOperationOptions extends WaitForOperationOptions {
|
|
375
|
+
readonly projectId?: string;
|
|
376
|
+
}
|
|
377
|
+
export {};
|
|
378
|
+
//# sourceMappingURL=developer-types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"developer-types.d.ts","sourceRoot":"","sources":["../../src/platform/developer-types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,MAAM,MAAM,WAAW,GAAG,cAAc,GAAG,SAAS,CAAC;AACrD,MAAM,MAAM,SAAS,GACjB,IAAI,GACJ,OAAO,GACP,MAAM,GACN,MAAM,GACN,SAAS,SAAS,EAAE,GACpB;IAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,CAAC;AAE1C,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAC5B,QAAQ,CAAC,WAAW,EAAE,kBAAkB,CAAC;IACzC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,MAAM,mBAAmB,GAC7B,WAAW,GAAG,cAAc,GAAG,SAAS,GAAG,UAAU,GAAG,aAAa,CAAC;AAExE,UAAU,SAAS;IACjB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,SAAS,GAAG,UAAU,GAAG,MAAM,CAAC;IACjD,QAAQ,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