@superdurable/connector-zoom 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/LICENSE +21 -0
- package/README.md +45 -2
- package/dex-connector.json +418 -0
- package/dist/chunk-RBP47TKQ.js +383 -0
- package/dist/connection-Cq-pg7cw.d.ts +417 -0
- package/dist/index.d.ts +481 -0
- package/dist/index.js +1434 -0
- package/dist/mock.d.ts +151 -0
- package/dist/mock.js +365 -0
- package/package.json +64 -4
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,481 @@
|
|
|
1
|
+
import { C as CreateMeetingInput, M as Meeting, a as Connection, G as GetMeetingInput, L as ListMeetingsInput, b as MeetingPage, c as ListPastMeetingParticipantsInput, P as ParticipantPage, U as UpdateMeetingInput, d as UpdatedMeeting, e as CredentialSource, f as Credentials, g as Config, O as Operations } from './connection-Cq-pg7cw.js';
|
|
2
|
+
export { h as ConfigSchema, i as CreateMeetingInputSchema, j as GetMeetingInputSchema, k as ListMeetingsInputSchema, l as ListPastMeetingParticipantsInputSchema, m as MeetingPageSchema, n as MeetingParticipant, o as MeetingParticipantSchema, p as MeetingSchema, q as MeetingSettings, r as MeetingSettingsInput, s as MeetingSettingsInputSchema, t as MeetingSettingsSchema, u as MeetingSummary, v as MeetingSummarySchema, w as ParticipantPageSchema, x as UpdateMeetingInputSchema, y as UpdatedMeetingSchema, z as decodeCredentials, A as decodeSharedCredentials, B as newConnection, D as newConnectionWithOperations } from './connection-Cq-pg7cw.js';
|
|
3
|
+
import * as _superdurable_connectors_sdk from '@superdurable/connectors-sdk';
|
|
4
|
+
import { MutationDefinition, QueryDefinition, MutationStepConfig, Mutation, MutationResult, QueryStepConfig, Query, QueryResult, MutationStep, QueryStep, Call, QueryAttempt, MutationAttempt, Failure, ReceiptDraft, ConnectorConfigurationUI, TriggerTarget, TriggerLogger, TriggerDefinition, TriggerBindingDefinition, TriggerRunner } from '@superdurable/connectors-sdk';
|
|
5
|
+
import { StepTarget } from '@superdurable/dex';
|
|
6
|
+
import { LoadedProject } from '@superdurable/connectors-sdk/projectconfig';
|
|
7
|
+
import { ProviderRequest, ProviderResponse } from '@superdurable/connectors-sdk/providerhttp';
|
|
8
|
+
import { ManifestCredentialRefreshDriver } from '@superdurable/connectors-sdk/oauthtoken';
|
|
9
|
+
import { z } from 'zod';
|
|
10
|
+
import { CursorStore, Runner } from '@superdurable/connectors-sdk/pollingtrigger';
|
|
11
|
+
|
|
12
|
+
/** Stable connector identity. */
|
|
13
|
+
declare const ConnectorID = "zoom";
|
|
14
|
+
/** Provider identity for named connections. */
|
|
15
|
+
declare const ProviderID = "zoom";
|
|
16
|
+
/** Branch IDs for listMeetings. */
|
|
17
|
+
declare const ListMeetingsBranch: {
|
|
18
|
+
readonly Listed: "listed";
|
|
19
|
+
readonly ProviderRejected: "providerRejected";
|
|
20
|
+
readonly InvalidResponse: "invalidResponse";
|
|
21
|
+
readonly Defect: "defect";
|
|
22
|
+
};
|
|
23
|
+
/** One page of the user's meetings was listed. */
|
|
24
|
+
declare const ListMeetingsBranchListed: "listed";
|
|
25
|
+
/** Zoom conclusively rejected the listing, including a documented daily-limit 429 or a user without meeting hosting capability. */
|
|
26
|
+
declare const ListMeetingsBranchProviderRejected: "providerRejected";
|
|
27
|
+
/** Zoom returned an invalid or oversized meeting page. */
|
|
28
|
+
declare const ListMeetingsBranchInvalidResponse: "invalidResponse";
|
|
29
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
30
|
+
declare const ListMeetingsBranchDefect: "defect";
|
|
31
|
+
/** Manifest definition for listMeetings. */
|
|
32
|
+
declare const ListMeetingsDefinition: QueryDefinition;
|
|
33
|
+
/** Manifest metadata for listMeetings. */
|
|
34
|
+
declare const ListMeetingsMetadata: {
|
|
35
|
+
readonly kind: "query";
|
|
36
|
+
readonly idempotency: "none";
|
|
37
|
+
readonly authorization: "required";
|
|
38
|
+
};
|
|
39
|
+
/** Branch IDs for getMeeting. */
|
|
40
|
+
declare const GetMeetingBranch: {
|
|
41
|
+
readonly Found: "found";
|
|
42
|
+
readonly NotFound: "notFound";
|
|
43
|
+
readonly ProviderRejected: "providerRejected";
|
|
44
|
+
readonly InvalidResponse: "invalidResponse";
|
|
45
|
+
readonly Defect: "defect";
|
|
46
|
+
};
|
|
47
|
+
/** The meeting was read. */
|
|
48
|
+
declare const GetMeetingBranchFound: "found";
|
|
49
|
+
/** The meeting does not exist or was deleted. */
|
|
50
|
+
declare const GetMeetingBranchNotFound: "notFound";
|
|
51
|
+
/** Zoom conclusively rejected the meeting read, including a documented daily-limit 429. */
|
|
52
|
+
declare const GetMeetingBranchProviderRejected: "providerRejected";
|
|
53
|
+
/** Zoom returned an invalid or oversized meeting. */
|
|
54
|
+
declare const GetMeetingBranchInvalidResponse: "invalidResponse";
|
|
55
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
56
|
+
declare const GetMeetingBranchDefect: "defect";
|
|
57
|
+
/** Manifest definition for getMeeting. */
|
|
58
|
+
declare const GetMeetingDefinition: QueryDefinition;
|
|
59
|
+
/** Manifest metadata for getMeeting. */
|
|
60
|
+
declare const GetMeetingMetadata: {
|
|
61
|
+
readonly kind: "query";
|
|
62
|
+
readonly idempotency: "none";
|
|
63
|
+
readonly authorization: "required";
|
|
64
|
+
};
|
|
65
|
+
/** Branch IDs for createMeeting. */
|
|
66
|
+
declare const CreateMeetingBranch: {
|
|
67
|
+
readonly Created: "created";
|
|
68
|
+
readonly ProviderRejected: "providerRejected";
|
|
69
|
+
readonly Uncertain: "uncertain";
|
|
70
|
+
readonly Defect: "defect";
|
|
71
|
+
};
|
|
72
|
+
/** Zoom created the meeting and returned its ID and join URL. */
|
|
73
|
+
declare const CreateMeetingBranchCreated: "created";
|
|
74
|
+
/** Zoom conclusively rejected the meeting, including a documented daily-limit 429 or a user who cannot host; nothing was created. */
|
|
75
|
+
declare const CreateMeetingBranchProviderRejected: "providerRejected";
|
|
76
|
+
/** The request was dispatched but its outcome cannot be confirmed; the meeting may exist and must not be created again automatically. */
|
|
77
|
+
declare const CreateMeetingBranchUncertain: "uncertain";
|
|
78
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
79
|
+
declare const CreateMeetingBranchDefect: "defect";
|
|
80
|
+
/** Manifest definition for createMeeting. */
|
|
81
|
+
declare const CreateMeetingDefinition: MutationDefinition;
|
|
82
|
+
/** Manifest metadata for createMeeting. */
|
|
83
|
+
declare const CreateMeetingMetadata: {
|
|
84
|
+
readonly kind: "mutation";
|
|
85
|
+
readonly idempotency: "required";
|
|
86
|
+
readonly authorization: "required";
|
|
87
|
+
};
|
|
88
|
+
/** Branch IDs for updateMeeting. */
|
|
89
|
+
declare const UpdateMeetingBranch: {
|
|
90
|
+
readonly Updated: "updated";
|
|
91
|
+
readonly NotFound: "notFound";
|
|
92
|
+
readonly ProviderRejected: "providerRejected";
|
|
93
|
+
readonly Defect: "defect";
|
|
94
|
+
};
|
|
95
|
+
/** Zoom accepted the patch. */
|
|
96
|
+
declare const UpdateMeetingBranchUpdated: "updated";
|
|
97
|
+
/** The meeting does not exist or was deleted. */
|
|
98
|
+
declare const UpdateMeetingBranchNotFound: "notFound";
|
|
99
|
+
/** Zoom conclusively rejected the patch, including a documented daily-limit 429 or an invalid field value. */
|
|
100
|
+
declare const UpdateMeetingBranchProviderRejected: "providerRejected";
|
|
101
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
102
|
+
declare const UpdateMeetingBranchDefect: "defect";
|
|
103
|
+
/** Manifest definition for updateMeeting. */
|
|
104
|
+
declare const UpdateMeetingDefinition: MutationDefinition;
|
|
105
|
+
/** Manifest metadata for updateMeeting. */
|
|
106
|
+
declare const UpdateMeetingMetadata: {
|
|
107
|
+
readonly kind: "mutation";
|
|
108
|
+
readonly idempotency: "required";
|
|
109
|
+
readonly authorization: "required";
|
|
110
|
+
};
|
|
111
|
+
/** Branch IDs for listPastMeetingParticipants. */
|
|
112
|
+
declare const ListPastMeetingParticipantsBranch: {
|
|
113
|
+
readonly Listed: "listed";
|
|
114
|
+
readonly NotFound: "notFound";
|
|
115
|
+
readonly ProviderRejected: "providerRejected";
|
|
116
|
+
readonly InvalidResponse: "invalidResponse";
|
|
117
|
+
readonly Defect: "defect";
|
|
118
|
+
};
|
|
119
|
+
/** One page of participants was listed. */
|
|
120
|
+
declare const ListPastMeetingParticipantsBranchListed: "listed";
|
|
121
|
+
/** Zoom has no ended instance of the meeting. */
|
|
122
|
+
declare const ListPastMeetingParticipantsBranchNotFound: "notFound";
|
|
123
|
+
/** Zoom conclusively rejected the listing, including a documented daily-limit 429, a free account, or a meeting older than Zoom keeps. */
|
|
124
|
+
declare const ListPastMeetingParticipantsBranchProviderRejected: "providerRejected";
|
|
125
|
+
/** Zoom returned an invalid or oversized participant page. */
|
|
126
|
+
declare const ListPastMeetingParticipantsBranchInvalidResponse: "invalidResponse";
|
|
127
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
128
|
+
declare const ListPastMeetingParticipantsBranchDefect: "defect";
|
|
129
|
+
/** Manifest definition for listPastMeetingParticipants. */
|
|
130
|
+
declare const ListPastMeetingParticipantsDefinition: QueryDefinition;
|
|
131
|
+
/** Manifest metadata for listPastMeetingParticipants. */
|
|
132
|
+
declare const ListPastMeetingParticipantsMetadata: {
|
|
133
|
+
readonly kind: "query";
|
|
134
|
+
readonly idempotency: "none";
|
|
135
|
+
readonly authorization: "required";
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
/** Configuration for the listMeetings connector Step. */
|
|
139
|
+
interface ListMeetingsStepConfig<StepInput, OperationInput = ListMeetingsInput, OperationOutput = MeetingPage> extends Omit<QueryStepConfig<StepInput, OperationInput, OperationOutput>, 'operation' | 'connection' | 'branches'> {
|
|
140
|
+
/** Named connection supplying this operation. */
|
|
141
|
+
connection: Connection<{
|
|
142
|
+
listMeetings(): Query<OperationInput, OperationOutput>;
|
|
143
|
+
}>;
|
|
144
|
+
/** Name matching the bound connection. */
|
|
145
|
+
connectionName: string;
|
|
146
|
+
/** One page of the user's meetings was listed. */
|
|
147
|
+
listed: StepTarget<QueryResult<OperationOutput>>;
|
|
148
|
+
/** Zoom conclusively rejected the listing, including a documented daily-limit 429 or a user without meeting hosting capability. */
|
|
149
|
+
providerRejected?: StepTarget<QueryResult<OperationOutput>>;
|
|
150
|
+
/** Zoom returned an invalid or oversized meeting page. */
|
|
151
|
+
invalidResponse?: StepTarget<QueryResult<OperationOutput>>;
|
|
152
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
153
|
+
defect?: StepTarget<QueryResult<OperationOutput>>;
|
|
154
|
+
}
|
|
155
|
+
/** Build the listMeetings Step from a named connection. */
|
|
156
|
+
declare function newListMeetingsStep<StepInput, OperationInput = ListMeetingsInput, OperationOutput = MeetingPage>(configuration: ListMeetingsStepConfig<StepInput, OperationInput, OperationOutput>): QueryStep<StepInput, OperationInput, OperationOutput>;
|
|
157
|
+
/** Configuration for the getMeeting connector Step. */
|
|
158
|
+
interface GetMeetingStepConfig<StepInput, OperationInput = GetMeetingInput, OperationOutput = Meeting> extends Omit<QueryStepConfig<StepInput, OperationInput, OperationOutput>, 'operation' | 'connection' | 'branches'> {
|
|
159
|
+
/** Named connection supplying this operation. */
|
|
160
|
+
connection: Connection<{
|
|
161
|
+
getMeeting(): Query<OperationInput, OperationOutput>;
|
|
162
|
+
}>;
|
|
163
|
+
/** Name matching the bound connection. */
|
|
164
|
+
connectionName: string;
|
|
165
|
+
/** The meeting was read. */
|
|
166
|
+
found: StepTarget<QueryResult<OperationOutput>>;
|
|
167
|
+
/** The meeting does not exist or was deleted. */
|
|
168
|
+
notFound?: StepTarget<QueryResult<OperationOutput>>;
|
|
169
|
+
/** Zoom conclusively rejected the meeting read, including a documented daily-limit 429. */
|
|
170
|
+
providerRejected?: StepTarget<QueryResult<OperationOutput>>;
|
|
171
|
+
/** Zoom returned an invalid or oversized meeting. */
|
|
172
|
+
invalidResponse?: StepTarget<QueryResult<OperationOutput>>;
|
|
173
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
174
|
+
defect?: StepTarget<QueryResult<OperationOutput>>;
|
|
175
|
+
}
|
|
176
|
+
/** Build the getMeeting Step from a named connection. */
|
|
177
|
+
declare function newGetMeetingStep<StepInput, OperationInput = GetMeetingInput, OperationOutput = Meeting>(configuration: GetMeetingStepConfig<StepInput, OperationInput, OperationOutput>): QueryStep<StepInput, OperationInput, OperationOutput>;
|
|
178
|
+
/** Configuration for the createMeeting connector Step. */
|
|
179
|
+
interface CreateMeetingStepConfig<StepInput, OperationInput = CreateMeetingInput, OperationOutput = Meeting> extends Omit<MutationStepConfig<StepInput, OperationInput, OperationOutput>, 'operation' | 'connection' | 'branches'> {
|
|
180
|
+
/** Named connection supplying this operation. */
|
|
181
|
+
connection: Connection<{
|
|
182
|
+
createMeeting(): Mutation<OperationInput, OperationOutput>;
|
|
183
|
+
}>;
|
|
184
|
+
/** Name matching the bound connection. */
|
|
185
|
+
connectionName: string;
|
|
186
|
+
/** Zoom created the meeting and returned its ID and join URL. */
|
|
187
|
+
created: StepTarget<MutationResult<OperationOutput>>;
|
|
188
|
+
/** Zoom conclusively rejected the meeting, including a documented daily-limit 429 or a user who cannot host; nothing was created. */
|
|
189
|
+
providerRejected?: StepTarget<MutationResult<OperationOutput>>;
|
|
190
|
+
/** The request was dispatched but its outcome cannot be confirmed; the meeting may exist and must not be created again automatically. */
|
|
191
|
+
uncertain?: StepTarget<MutationResult<OperationOutput>>;
|
|
192
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
193
|
+
defect?: StepTarget<MutationResult<OperationOutput>>;
|
|
194
|
+
}
|
|
195
|
+
/** Build the createMeeting Step from a named connection. */
|
|
196
|
+
declare function newCreateMeetingStep<StepInput, OperationInput = CreateMeetingInput, OperationOutput = Meeting>(configuration: CreateMeetingStepConfig<StepInput, OperationInput, OperationOutput>): MutationStep<StepInput, OperationInput, OperationOutput>;
|
|
197
|
+
/** Configuration for the updateMeeting connector Step. */
|
|
198
|
+
interface UpdateMeetingStepConfig<StepInput, OperationInput = UpdateMeetingInput, OperationOutput = UpdatedMeeting> extends Omit<MutationStepConfig<StepInput, OperationInput, OperationOutput>, 'operation' | 'connection' | 'branches'> {
|
|
199
|
+
/** Named connection supplying this operation. */
|
|
200
|
+
connection: Connection<{
|
|
201
|
+
updateMeeting(): Mutation<OperationInput, OperationOutput>;
|
|
202
|
+
}>;
|
|
203
|
+
/** Name matching the bound connection. */
|
|
204
|
+
connectionName: string;
|
|
205
|
+
/** Zoom accepted the patch. */
|
|
206
|
+
updated: StepTarget<MutationResult<OperationOutput>>;
|
|
207
|
+
/** The meeting does not exist or was deleted. */
|
|
208
|
+
notFound?: StepTarget<MutationResult<OperationOutput>>;
|
|
209
|
+
/** Zoom conclusively rejected the patch, including a documented daily-limit 429 or an invalid field value. */
|
|
210
|
+
providerRejected?: StepTarget<MutationResult<OperationOutput>>;
|
|
211
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
212
|
+
defect?: StepTarget<MutationResult<OperationOutput>>;
|
|
213
|
+
}
|
|
214
|
+
/** Build the updateMeeting Step from a named connection. */
|
|
215
|
+
declare function newUpdateMeetingStep<StepInput, OperationInput = UpdateMeetingInput, OperationOutput = UpdatedMeeting>(configuration: UpdateMeetingStepConfig<StepInput, OperationInput, OperationOutput>): MutationStep<StepInput, OperationInput, OperationOutput>;
|
|
216
|
+
/** Configuration for the listPastMeetingParticipants connector Step. */
|
|
217
|
+
interface ListPastMeetingParticipantsStepConfig<StepInput, OperationInput = ListPastMeetingParticipantsInput, OperationOutput = ParticipantPage> extends Omit<QueryStepConfig<StepInput, OperationInput, OperationOutput>, 'operation' | 'connection' | 'branches'> {
|
|
218
|
+
/** Named connection supplying this operation. */
|
|
219
|
+
connection: Connection<{
|
|
220
|
+
listPastMeetingParticipants(): Query<OperationInput, OperationOutput>;
|
|
221
|
+
}>;
|
|
222
|
+
/** Name matching the bound connection. */
|
|
223
|
+
connectionName: string;
|
|
224
|
+
/** One page of participants was listed. */
|
|
225
|
+
listed: StepTarget<QueryResult<OperationOutput>>;
|
|
226
|
+
/** Zoom has no ended instance of the meeting. */
|
|
227
|
+
notFound?: StepTarget<QueryResult<OperationOutput>>;
|
|
228
|
+
/** Zoom conclusively rejected the listing, including a documented daily-limit 429, a free account, or a meeting older than Zoom keeps. */
|
|
229
|
+
providerRejected?: StepTarget<QueryResult<OperationOutput>>;
|
|
230
|
+
/** Zoom returned an invalid or oversized participant page. */
|
|
231
|
+
invalidResponse?: StepTarget<QueryResult<OperationOutput>>;
|
|
232
|
+
/** Local input, connection configuration, or connector definition is invalid. */
|
|
233
|
+
defect?: StepTarget<QueryResult<OperationOutput>>;
|
|
234
|
+
}
|
|
235
|
+
/** Build the listPastMeetingParticipants Step from a named connection. */
|
|
236
|
+
declare function newListPastMeetingParticipantsStep<StepInput, OperationInput = ListPastMeetingParticipantsInput, OperationOutput = ParticipantPage>(configuration: ListPastMeetingParticipantsStepConfig<StepInput, OperationInput, OperationOutput>): QueryStep<StepInput, OperationInput, OperationOutput>;
|
|
237
|
+
|
|
238
|
+
/** List one page of the authorized user's meetings. */
|
|
239
|
+
declare class ListMeetingsOperation implements Query<ListMeetingsInput, MeetingPage> {
|
|
240
|
+
private readonly client;
|
|
241
|
+
/** Bind one Zoom client. */ constructor(client: ZoomClient);
|
|
242
|
+
/** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
|
|
243
|
+
/** Invoke one bounded meeting-list request. */
|
|
244
|
+
invoke(call: Call, input: ListMeetingsInput): Promise<QueryAttempt<MeetingPage>>;
|
|
245
|
+
}
|
|
246
|
+
/** Read one meeting by numeric ID. */
|
|
247
|
+
declare class GetMeetingOperation implements Query<GetMeetingInput, Meeting> {
|
|
248
|
+
private readonly client;
|
|
249
|
+
/** Bind one Zoom client. */ constructor(client: ZoomClient);
|
|
250
|
+
/** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
|
|
251
|
+
/** Invoke one bounded meeting read. */
|
|
252
|
+
invoke(call: Call, input: GetMeetingInput): Promise<QueryAttempt<Meeting>>;
|
|
253
|
+
}
|
|
254
|
+
/** Set absolute values on one meeting. */
|
|
255
|
+
declare class UpdateMeetingOperation implements Mutation<UpdateMeetingInput, UpdatedMeeting> {
|
|
256
|
+
private readonly client;
|
|
257
|
+
/** Bind one Zoom client. */ constructor(client: ZoomClient);
|
|
258
|
+
/** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.MutationDefinition;
|
|
259
|
+
/** Derive the receipt key from Dex's Call ID. */ idempotencyKey(callId: string): string;
|
|
260
|
+
/** Invoke one repeat-safe meeting patch. */
|
|
261
|
+
invoke(call: Call, input: UpdateMeetingInput): Promise<MutationAttempt<UpdatedMeeting>>;
|
|
262
|
+
}
|
|
263
|
+
/** List one page of joins from the latest ended meeting instance. */
|
|
264
|
+
declare class ListPastMeetingParticipantsOperation implements Query<ListPastMeetingParticipantsInput, ParticipantPage> {
|
|
265
|
+
private readonly client;
|
|
266
|
+
/** Bind one Zoom client. */ constructor(client: ZoomClient);
|
|
267
|
+
/** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
|
|
268
|
+
/** Invoke one bounded participant-list request. */
|
|
269
|
+
invoke(call: Call, input: ListPastMeetingParticipantsInput): Promise<QueryAttempt<ParticipantPage>>;
|
|
270
|
+
}
|
|
271
|
+
/** Create one meeting behind Dex's durable single-dispatch fence. */
|
|
272
|
+
declare class CreateMeetingOperation implements Mutation<CreateMeetingInput, Meeting> {
|
|
273
|
+
private readonly client;
|
|
274
|
+
/** Bind one Zoom client. */ constructor(client: ZoomClient);
|
|
275
|
+
/** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.MutationDefinition;
|
|
276
|
+
/** Derive the receipt key from Dex's Call ID. */ idempotencyKey(callId: string): string;
|
|
277
|
+
/** Invoke one fenced create attempt. */
|
|
278
|
+
invoke(call: Call, input: CreateMeetingInput): Promise<MutationAttempt<Meeting>>;
|
|
279
|
+
private readBack;
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
/** Keeps one meetingChanged binding under Zoom's Free-plan Medium daily limit. */
|
|
283
|
+
declare const MinimumPollIntervalMs = 30000;
|
|
284
|
+
/** Replace the provider transport or clock for deterministic tests. */
|
|
285
|
+
interface ZoomClientOptions {
|
|
286
|
+
/** Sends one provider request. */ send?: (request: ProviderRequest) => Promise<ProviderResponse>;
|
|
287
|
+
/** Supplies receipt and Retry-After time. */ now?: () => Date;
|
|
288
|
+
}
|
|
289
|
+
/** One provider exchange, retaining whether a failed write could have reached Zoom. */
|
|
290
|
+
type ZoomExchange = {
|
|
291
|
+
response: ProviderResponse;
|
|
292
|
+
isTooLarge: boolean;
|
|
293
|
+
reflectsCredential: boolean;
|
|
294
|
+
} | {
|
|
295
|
+
error: 'beforeSend' | 'afterSend' | 'notBuilt';
|
|
296
|
+
};
|
|
297
|
+
/** Zoom Meetings client with generated OAuth refresh policy. */
|
|
298
|
+
declare class ZoomClient {
|
|
299
|
+
readonly credentials: CredentialSource;
|
|
300
|
+
readonly endpoint: string;
|
|
301
|
+
readonly maxResponseBytes: number;
|
|
302
|
+
/** The meetingChanged Trigger's delay between polls in milliseconds; at least MinimumPollIntervalMs. */
|
|
303
|
+
readonly pollIntervalMs: number;
|
|
304
|
+
private readonly send;
|
|
305
|
+
private readonly now;
|
|
306
|
+
/** The generated OAuth refresh policy every credential resolution uses, including Trigger polls. */
|
|
307
|
+
readonly refreshDriver: ManifestCredentialRefreshDriver<Credentials>;
|
|
308
|
+
/**
|
|
309
|
+
* Validate connection settings before a Step resolves credentials. An omitted or zero pollIntervalMs uses
|
|
310
|
+
* the manifest's two minutes; one under 30 seconds throws, as Go's New does.
|
|
311
|
+
*/
|
|
312
|
+
constructor(config: Config, credentials: CredentialSource, options?: ZoomClientOptions);
|
|
313
|
+
/** The client clock, used for receipts, Retry-After, and Trigger observation times. */
|
|
314
|
+
currentTime(): Date;
|
|
315
|
+
/** Bind the meeting list query. */ listMeetings(): ListMeetingsOperation;
|
|
316
|
+
/** Bind the meeting detail query. */ getMeeting(): GetMeetingOperation;
|
|
317
|
+
/** Bind the fenced meeting create mutation. */ createMeeting(): CreateMeetingOperation;
|
|
318
|
+
/** Bind the meeting patch mutation. */ updateMeeting(): UpdateMeetingOperation;
|
|
319
|
+
/** Bind the participant list query. */ listPastMeetingParticipants(): ListPastMeetingParticipantsOperation;
|
|
320
|
+
/** Resolve generated renewable credentials and preserve terminal versus retryable failures. */
|
|
321
|
+
resolveCredentials(call: Call, operation: string): Promise<{
|
|
322
|
+
credentials: Credentials;
|
|
323
|
+
} | {
|
|
324
|
+
failure: Failure;
|
|
325
|
+
retry: boolean;
|
|
326
|
+
}>;
|
|
327
|
+
/** Force one generated refresh after Zoom rejects a fenced create credential. */
|
|
328
|
+
refreshAfterRejection(call: Call, previousAccessToken: string): Promise<'replaced' | 'retryable' | 'reauthorize' | 'unsupported'>;
|
|
329
|
+
/** Send one bounded request and refresh once after a rejected credential when allowed. */
|
|
330
|
+
exchange(call: Call, credentials: Credentials, method: string, path: string, query?: URLSearchParams, payload?: unknown, isFencedWrite?: boolean, signal?: AbortSignal): Promise<ZoomExchange>;
|
|
331
|
+
/** Build a secret-free receipt containing only the provider meeting ID and numeric error code. */
|
|
332
|
+
receipt(call: Call, objectId?: string, errorCode?: string): ReceiptDraft;
|
|
333
|
+
/** Parse Retry-After with the SDK's bounded rules. */
|
|
334
|
+
retryAfter(headers: ProviderResponse['headers']): number;
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
/** Open a named Zoom project connection with generated renewable credential decoders. */
|
|
338
|
+
declare function newProjectConnection(project: LoadedProject, connectionName: string, options?: ZoomClientOptions): Connection<Operations>;
|
|
339
|
+
|
|
340
|
+
/** A meeting the previous poll did not list, such as a newly scheduled meeting. */
|
|
341
|
+
declare const MeetingChangeScheduled = "scheduled";
|
|
342
|
+
/**
|
|
343
|
+
* A listed meeting whose topic, type, start, duration, time zone, or listed agenda changed, such as a
|
|
344
|
+
* reschedule. A recurring meeting whose listed start moves to its next occurrence also arrives as updated.
|
|
345
|
+
*/
|
|
346
|
+
declare const MeetingChangeUpdated = "updated";
|
|
347
|
+
/** A meeting the list no longer contains: it was deleted, or it expired after its scheduled time. */
|
|
348
|
+
declare const MeetingChangeRemoved = "removed";
|
|
349
|
+
/**
|
|
350
|
+
* The kind of one meetingChanged delivery. Zoom's meeting list reports no change type or modification time,
|
|
351
|
+
* so the kind comes from comparing two polls of the list.
|
|
352
|
+
*/
|
|
353
|
+
declare const MeetingChangeKindSchema: z.ZodEnum<{
|
|
354
|
+
scheduled: "scheduled";
|
|
355
|
+
updated: "updated";
|
|
356
|
+
removed: "removed";
|
|
357
|
+
}>;
|
|
358
|
+
/** scheduled, updated, or removed. */
|
|
359
|
+
type MeetingChangeKind = z.infer<typeof MeetingChangeKindSchema>;
|
|
360
|
+
/**
|
|
361
|
+
* The meetingChanged binding configuration. The binding always watches the authorized user's own scheduled
|
|
362
|
+
* meetings, so Dex Web shows no field for it; an application may narrow the delivered kinds in code.
|
|
363
|
+
*/
|
|
364
|
+
declare const MeetingChangedTriggerConfigurationSchema: z.ZodObject<{
|
|
365
|
+
changeKinds: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
|
|
366
|
+
}, z.core.$strict>;
|
|
367
|
+
/** The meetingChanged binding configuration; the empty object delivers every kind. */
|
|
368
|
+
type MeetingChangedTriggerConfiguration = z.infer<typeof MeetingChangedTriggerConfigurationSchema>;
|
|
369
|
+
/**
|
|
370
|
+
* One meeting scheduled, updated, or removed between two polls of the authorized user's scheduled meetings;
|
|
371
|
+
* field names match the Go connector, so Go and TypeScript replicas share a binding's inbox.
|
|
372
|
+
*/
|
|
373
|
+
declare const MeetingChangedEventSchema: z.ZodObject<{
|
|
374
|
+
changeKind: z.ZodEnum<{
|
|
375
|
+
scheduled: "scheduled";
|
|
376
|
+
updated: "updated";
|
|
377
|
+
removed: "removed";
|
|
378
|
+
}>;
|
|
379
|
+
meeting: z.ZodObject<{
|
|
380
|
+
id: z.ZodNumber;
|
|
381
|
+
uuid: z.ZodOptional<z.ZodString>;
|
|
382
|
+
hostId: z.ZodOptional<z.ZodString>;
|
|
383
|
+
topic: z.ZodString;
|
|
384
|
+
type: z.ZodOptional<z.ZodNumber>;
|
|
385
|
+
startTime: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
386
|
+
durationMinutes: z.ZodOptional<z.ZodNumber>;
|
|
387
|
+
timeZone: z.ZodOptional<z.ZodString>;
|
|
388
|
+
agenda: z.ZodOptional<z.ZodString>;
|
|
389
|
+
joinUrl: z.ZodOptional<z.ZodString>;
|
|
390
|
+
createdAt: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
391
|
+
}, z.core.$strict>;
|
|
392
|
+
previousMeeting: z.ZodOptional<z.ZodObject<{
|
|
393
|
+
id: z.ZodNumber;
|
|
394
|
+
uuid: z.ZodOptional<z.ZodString>;
|
|
395
|
+
hostId: z.ZodOptional<z.ZodString>;
|
|
396
|
+
topic: z.ZodString;
|
|
397
|
+
type: z.ZodOptional<z.ZodNumber>;
|
|
398
|
+
startTime: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
399
|
+
durationMinutes: z.ZodOptional<z.ZodNumber>;
|
|
400
|
+
timeZone: z.ZodOptional<z.ZodString>;
|
|
401
|
+
agenda: z.ZodOptional<z.ZodString>;
|
|
402
|
+
joinUrl: z.ZodOptional<z.ZodString>;
|
|
403
|
+
createdAt: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
404
|
+
}, z.core.$strict>>;
|
|
405
|
+
}, z.core.$strip>;
|
|
406
|
+
/** One meetingChanged delivery. */
|
|
407
|
+
type MeetingChangedEvent = z.infer<typeof MeetingChangedEventSchema>;
|
|
408
|
+
|
|
409
|
+
/** Manifest definition of meetingChanged. */
|
|
410
|
+
declare const MeetingChangedTriggerDefinition: TriggerDefinition;
|
|
411
|
+
/** One static application binding of meetingChanged. */
|
|
412
|
+
interface MeetingChangedTriggerBindingConfig {
|
|
413
|
+
/** Static connection name. */ connectionName: string;
|
|
414
|
+
/** Static binding name. */ bindingName: string;
|
|
415
|
+
/** Optional Connector Studio units; the binding has no field, because it always watches the authorized user. */ configurationUI?: ConnectorConfigurationUI;
|
|
416
|
+
}
|
|
417
|
+
/** Declare a static meetingChanged binding for Flow Definition tooling and Dex Web. */
|
|
418
|
+
declare function defineMeetingChangedTriggerBinding(config: MeetingChangedTriggerBindingConfig): TriggerBindingDefinition;
|
|
419
|
+
/** Binds one meetingChanged configuration to its application target and cursor. */
|
|
420
|
+
interface MeetingChangedTriggerRoute {
|
|
421
|
+
/** The stable application binding name, unique within the runner. */ bindingName: string;
|
|
422
|
+
/** Narrows the delivered change kinds; omitted delivers every kind. */ configuration?: MeetingChangedTriggerConfiguration;
|
|
423
|
+
/**
|
|
424
|
+
* Routes each change into the application. A target from newDurableTriggerTarget records each change before
|
|
425
|
+
* the cursor commits past it; any other target consumes it first.
|
|
426
|
+
*/
|
|
427
|
+
target: TriggerTarget<MeetingChangedEvent>;
|
|
428
|
+
/**
|
|
429
|
+
* Stores the binding's meeting snapshot, such as LoadedProject.pollCursorStore. Omitted keeps it in memory,
|
|
430
|
+
* so every process start records a new baseline and changes made while stopped are lost.
|
|
431
|
+
*/
|
|
432
|
+
cursor?: CursorStore;
|
|
433
|
+
}
|
|
434
|
+
/** Options of the meetingChanged runners. */
|
|
435
|
+
interface MeetingTriggerRunnerOptions {
|
|
436
|
+
/** Receives seed, reseed, poll failure, rate-limit, and inbox records, never payloads or credentials; omitted uses defaultTriggerLogger. */ logger?: TriggerLogger;
|
|
437
|
+
}
|
|
438
|
+
/**
|
|
439
|
+
* Create one poll Runner for the connection's meetingChanged bindings. Run replays each durable target,
|
|
440
|
+
* records the current meeting list as a baseline for a binding without a cursor, then lists every page of
|
|
441
|
+
* the authorized user's scheduled meetings each pollInterval with jitter and delivers the differences from
|
|
442
|
+
* the stored snapshot. A stored cursor that is undecodable or holds another Zoom user's meetings records a
|
|
443
|
+
* new baseline and logs a WARN record; differences in that gap are not delivered. A 429, including Zoom's
|
|
444
|
+
* daily-limit 429, pauses every binding of the connection for Retry-After, or backs off exponentially
|
|
445
|
+
* without it; other failures back off per binding up to 15 minutes. Delivery is at least once, and each
|
|
446
|
+
* change keeps one Trigger event ID across refetches. Throws for a connection without a ZoomClient, no
|
|
447
|
+
* routes, a blank binding name, a missing target, or an invalid configuration.
|
|
448
|
+
*/
|
|
449
|
+
declare function newMeetingTriggerRunner(connection: Connection, routes: readonly MeetingChangedTriggerRoute[], options?: MeetingTriggerRunnerOptions): Runner;
|
|
450
|
+
/** Selects one meetingChanged binding saved in the project configuration. */
|
|
451
|
+
interface ProjectMeetingChangedTriggerRoute {
|
|
452
|
+
/** Names the saved binding. */ bindingName: string;
|
|
453
|
+
/** Routes each change into the application, usually newDexFlowTriggerTarget. */ target: TriggerTarget<MeetingChangedEvent>;
|
|
454
|
+
}
|
|
455
|
+
/**
|
|
456
|
+
* Create a durable Runner for meetingChanged bindings saved in the loaded project. connection is the one
|
|
457
|
+
* newProjectConnection opened from project. Each route loads its binding's saved configuration (an unsaved
|
|
458
|
+
* binding delivers every change kind) and records changes in the binding's project Trigger inbox before its
|
|
459
|
+
* meeting snapshot commits in the binding's project poll cursor, so a restarted or replaced replica neither
|
|
460
|
+
* misses nor repeats a change. Inbox payloads use the Go connector's JSON fields, so Go and TypeScript
|
|
461
|
+
* replicas share them. Throws for an invalid saved configuration and as newMeetingTriggerRunner does.
|
|
462
|
+
*/
|
|
463
|
+
declare function newProjectMeetingTriggerRunner(project: LoadedProject, connection: Connection, routes: readonly ProjectMeetingChangedTriggerRoute[], options?: MeetingTriggerRunnerOptions): Runner;
|
|
464
|
+
/** Configuration of one in-memory meetingChanged Trigger. */
|
|
465
|
+
interface MeetingChangedTriggerConfig {
|
|
466
|
+
/** Zoom connection from newProjectConnection or newConnection with a ZoomClient. */ connection: Connection;
|
|
467
|
+
/** Static binding name. */ bindingName: string;
|
|
468
|
+
/** Narrows the delivered change kinds; omitted delivers every kind. */ configuration?: MeetingChangedTriggerConfiguration;
|
|
469
|
+
/** Routes accepted changes into the application. */ target: TriggerTarget<MeetingChangedEvent>;
|
|
470
|
+
/** Receives the Trigger's records; omitted uses defaultTriggerLogger. */ logger?: TriggerLogger;
|
|
471
|
+
}
|
|
472
|
+
/**
|
|
473
|
+
* Create a single meetingChanged TriggerRunner, as Go's generated NewMeetingChangedTrigger does. It has no
|
|
474
|
+
* project storage, so it keeps the cursor in memory and records a new baseline on every start; changes made
|
|
475
|
+
* while stopped are lost. Use newProjectMeetingTriggerRunner for durable delivery.
|
|
476
|
+
*/
|
|
477
|
+
declare function newMeetingChangedTrigger(config: MeetingChangedTriggerConfig): TriggerRunner;
|
|
478
|
+
/** Decode a replayed inbox payload, written by a Go or TypeScript replica; throws for another payload. */
|
|
479
|
+
declare function decodeMeetingChangedEventPayload(payloadJSON: string): MeetingChangedEvent;
|
|
480
|
+
|
|
481
|
+
export { Config, Connection, ConnectorID, CreateMeetingBranch, CreateMeetingBranchCreated, CreateMeetingBranchDefect, CreateMeetingBranchProviderRejected, CreateMeetingBranchUncertain, CreateMeetingDefinition, CreateMeetingInput, CreateMeetingMetadata, CreateMeetingOperation, type CreateMeetingStepConfig, CredentialSource, Credentials, GetMeetingBranch, GetMeetingBranchDefect, GetMeetingBranchFound, GetMeetingBranchInvalidResponse, GetMeetingBranchNotFound, GetMeetingBranchProviderRejected, GetMeetingDefinition, GetMeetingInput, GetMeetingMetadata, GetMeetingOperation, type GetMeetingStepConfig, ListMeetingsBranch, ListMeetingsBranchDefect, ListMeetingsBranchInvalidResponse, ListMeetingsBranchListed, ListMeetingsBranchProviderRejected, ListMeetingsDefinition, ListMeetingsInput, ListMeetingsMetadata, ListMeetingsOperation, type ListMeetingsStepConfig, ListPastMeetingParticipantsBranch, ListPastMeetingParticipantsBranchDefect, ListPastMeetingParticipantsBranchInvalidResponse, ListPastMeetingParticipantsBranchListed, ListPastMeetingParticipantsBranchNotFound, ListPastMeetingParticipantsBranchProviderRejected, ListPastMeetingParticipantsDefinition, ListPastMeetingParticipantsInput, ListPastMeetingParticipantsMetadata, ListPastMeetingParticipantsOperation, type ListPastMeetingParticipantsStepConfig, Meeting, type MeetingChangeKind, MeetingChangeKindSchema, MeetingChangeRemoved, MeetingChangeScheduled, MeetingChangeUpdated, type MeetingChangedEvent, MeetingChangedEventSchema, type MeetingChangedTriggerBindingConfig, type MeetingChangedTriggerConfig, type MeetingChangedTriggerConfiguration, MeetingChangedTriggerConfigurationSchema, MeetingChangedTriggerDefinition, type MeetingChangedTriggerRoute, MeetingPage, type MeetingTriggerRunnerOptions, MinimumPollIntervalMs, ParticipantPage, type ProjectMeetingChangedTriggerRoute, ProviderID, UpdateMeetingBranch, UpdateMeetingBranchDefect, UpdateMeetingBranchNotFound, UpdateMeetingBranchProviderRejected, UpdateMeetingBranchUpdated, UpdateMeetingDefinition, UpdateMeetingInput, UpdateMeetingMetadata, UpdateMeetingOperation, type UpdateMeetingStepConfig, UpdatedMeeting, ZoomClient, type ZoomClientOptions, decodeMeetingChangedEventPayload, defineMeetingChangedTriggerBinding, newCreateMeetingStep, newGetMeetingStep, newListMeetingsStep, newListPastMeetingParticipantsStep, newMeetingChangedTrigger, newMeetingTriggerRunner, newProjectConnection, newProjectMeetingTriggerRunner, newUpdateMeetingStep };
|