samva 0.26.0 → 0.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/dist/client/sdk.gen.js +245 -1
- package/dist/effect/agents.d.ts +121 -0
- package/dist/effect/agents.js +29 -0
- package/dist/effect/analytics.js +1 -1
- package/dist/effect/generated/agents.js +271 -0
- package/dist/effect/generated/email.d.ts +15 -30
- package/dist/effect/generated/email.js +3 -6
- package/dist/effect/generated/index.d.ts +1 -1
- package/dist/effect/generated/mailboxes.d.ts +294 -588
- package/dist/effect/generated/shared.d.ts +35 -70
- package/dist/effect/generated/shared.js +49 -22
- package/dist/effect/index.d.ts +1 -0
- package/dist/effect/index.js +2 -1
- package/dist/effect/internal/operation.js +1 -0
- package/dist/effect/journeys.d.ts +112 -112
- package/dist/package.js +1 -1
- package/dist/promises/index.d.ts +3 -1
- package/dist/promises/index.js +3 -1
- package/dist/service-map.d.ts +45 -0
- package/dist/service-map.js +30 -0
- package/package.json +7 -3
|
@@ -37,6 +37,9 @@ export declare const create: (input: {
|
|
|
37
37
|
readonly name: string;
|
|
38
38
|
readonly definition: {
|
|
39
39
|
readonly trigger: {
|
|
40
|
+
readonly type: "event";
|
|
41
|
+
readonly eventName: string;
|
|
42
|
+
} | {
|
|
40
43
|
readonly type: "contact.created";
|
|
41
44
|
} | {
|
|
42
45
|
readonly type: "contact.tag_added";
|
|
@@ -44,19 +47,10 @@ export declare const create: (input: {
|
|
|
44
47
|
} | {
|
|
45
48
|
readonly type: "contact.joined_group";
|
|
46
49
|
readonly groupId: string;
|
|
47
|
-
} | {
|
|
48
|
-
readonly type: "event";
|
|
49
|
-
readonly eventName: string;
|
|
50
50
|
};
|
|
51
51
|
readonly rootNodeId: string;
|
|
52
52
|
readonly nodes: {
|
|
53
53
|
readonly [x: string]: {
|
|
54
|
-
readonly type: "exit";
|
|
55
|
-
readonly config: {
|
|
56
|
-
readonly [x: string]: undefined;
|
|
57
|
-
};
|
|
58
|
-
readonly next: readonly never[];
|
|
59
|
-
} | {
|
|
60
54
|
readonly type: "send_email";
|
|
61
55
|
readonly config: {
|
|
62
56
|
readonly template: string;
|
|
@@ -100,49 +94,6 @@ export declare const create: (input: {
|
|
|
100
94
|
readonly next: readonly {
|
|
101
95
|
readonly nodeId: string;
|
|
102
96
|
}[];
|
|
103
|
-
} | {
|
|
104
|
-
readonly type: "update_tags";
|
|
105
|
-
readonly config: {
|
|
106
|
-
readonly add: readonly string[];
|
|
107
|
-
readonly remove: readonly string[];
|
|
108
|
-
};
|
|
109
|
-
readonly next: readonly {
|
|
110
|
-
readonly nodeId: string;
|
|
111
|
-
}[];
|
|
112
|
-
} | {
|
|
113
|
-
readonly type: "webhook";
|
|
114
|
-
readonly config: {
|
|
115
|
-
readonly data?: {
|
|
116
|
-
readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
|
|
117
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
118
|
-
} | null)[] | {
|
|
119
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
120
|
-
} | null)[] | {
|
|
121
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
122
|
-
} | null)[] | {
|
|
123
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
124
|
-
} | null)[] | {
|
|
125
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
126
|
-
} | null)[] | {
|
|
127
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
128
|
-
} | null)[] | {
|
|
129
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
130
|
-
} | null)[] | {
|
|
131
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
132
|
-
} | null)[] | {
|
|
133
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
134
|
-
} | null)[] | {
|
|
135
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
136
|
-
} | null)[] | {
|
|
137
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
138
|
-
} | null)[] | {
|
|
139
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
140
|
-
} | null | undefined;
|
|
141
|
-
} | undefined;
|
|
142
|
-
};
|
|
143
|
-
readonly next: readonly {
|
|
144
|
-
readonly nodeId: string;
|
|
145
|
-
}[];
|
|
146
97
|
} | {
|
|
147
98
|
readonly type: "wait_for_event";
|
|
148
99
|
readonly config: {
|
|
@@ -166,10 +117,6 @@ export declare const create: (input: {
|
|
|
166
117
|
readonly type: "tag";
|
|
167
118
|
readonly tag: string;
|
|
168
119
|
readonly present: boolean;
|
|
169
|
-
} | {
|
|
170
|
-
readonly type: "event";
|
|
171
|
-
readonly eventName: string;
|
|
172
|
-
readonly occurred: boolean;
|
|
173
120
|
} | {
|
|
174
121
|
readonly type: "property";
|
|
175
122
|
readonly field: "displayName" | "externalId" | "name" | "profile.company" | "profile.firstName" | "profile.jobTitle" | "profile.lastName" | "profile.location.city" | "profile.location.country" | "profile.location.state" | "profile.location.timezone" | "profile.source" | "status";
|
|
@@ -200,9 +147,62 @@ export declare const create: (input: {
|
|
|
200
147
|
} | {
|
|
201
148
|
readonly operator: "exists" | "not_exists";
|
|
202
149
|
};
|
|
150
|
+
} | {
|
|
151
|
+
readonly type: "event";
|
|
152
|
+
readonly eventName: string;
|
|
153
|
+
readonly occurred: boolean;
|
|
203
154
|
})[];
|
|
204
155
|
} | undefined;
|
|
205
156
|
}[];
|
|
157
|
+
} | {
|
|
158
|
+
readonly type: "update_tags";
|
|
159
|
+
readonly config: {
|
|
160
|
+
readonly add: readonly string[];
|
|
161
|
+
readonly remove: readonly string[];
|
|
162
|
+
};
|
|
163
|
+
readonly next: readonly {
|
|
164
|
+
readonly nodeId: string;
|
|
165
|
+
}[];
|
|
166
|
+
} | {
|
|
167
|
+
readonly type: "webhook";
|
|
168
|
+
readonly config: {
|
|
169
|
+
readonly data?: {
|
|
170
|
+
readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
|
|
171
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
172
|
+
} | null)[] | {
|
|
173
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
174
|
+
} | null)[] | {
|
|
175
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
176
|
+
} | null)[] | {
|
|
177
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
178
|
+
} | null)[] | {
|
|
179
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
180
|
+
} | null)[] | {
|
|
181
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
182
|
+
} | null)[] | {
|
|
183
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
184
|
+
} | null)[] | {
|
|
185
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
186
|
+
} | null)[] | {
|
|
187
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
188
|
+
} | null)[] | {
|
|
189
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
190
|
+
} | null)[] | {
|
|
191
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
192
|
+
} | null)[] | {
|
|
193
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
194
|
+
} | null | undefined;
|
|
195
|
+
} | undefined;
|
|
196
|
+
};
|
|
197
|
+
readonly next: readonly {
|
|
198
|
+
readonly nodeId: string;
|
|
199
|
+
}[];
|
|
200
|
+
} | {
|
|
201
|
+
readonly type: "exit";
|
|
202
|
+
readonly config: {
|
|
203
|
+
readonly [x: string]: undefined;
|
|
204
|
+
};
|
|
205
|
+
readonly next: readonly never[];
|
|
206
206
|
} | undefined;
|
|
207
207
|
};
|
|
208
208
|
readonly goal?: {
|
|
@@ -226,6 +226,9 @@ export declare const replaceDraft: (input: {
|
|
|
226
226
|
readonly revision: string;
|
|
227
227
|
readonly definition: {
|
|
228
228
|
readonly trigger: {
|
|
229
|
+
readonly type: "event";
|
|
230
|
+
readonly eventName: string;
|
|
231
|
+
} | {
|
|
229
232
|
readonly type: "contact.created";
|
|
230
233
|
} | {
|
|
231
234
|
readonly type: "contact.tag_added";
|
|
@@ -233,19 +236,10 @@ export declare const replaceDraft: (input: {
|
|
|
233
236
|
} | {
|
|
234
237
|
readonly type: "contact.joined_group";
|
|
235
238
|
readonly groupId: string;
|
|
236
|
-
} | {
|
|
237
|
-
readonly type: "event";
|
|
238
|
-
readonly eventName: string;
|
|
239
239
|
};
|
|
240
240
|
readonly rootNodeId: string;
|
|
241
241
|
readonly nodes: {
|
|
242
242
|
readonly [x: string]: {
|
|
243
|
-
readonly type: "exit";
|
|
244
|
-
readonly config: {
|
|
245
|
-
readonly [x: string]: undefined;
|
|
246
|
-
};
|
|
247
|
-
readonly next: readonly never[];
|
|
248
|
-
} | {
|
|
249
243
|
readonly type: "send_email";
|
|
250
244
|
readonly config: {
|
|
251
245
|
readonly template: string;
|
|
@@ -289,49 +283,6 @@ export declare const replaceDraft: (input: {
|
|
|
289
283
|
readonly next: readonly {
|
|
290
284
|
readonly nodeId: string;
|
|
291
285
|
}[];
|
|
292
|
-
} | {
|
|
293
|
-
readonly type: "update_tags";
|
|
294
|
-
readonly config: {
|
|
295
|
-
readonly add: readonly string[];
|
|
296
|
-
readonly remove: readonly string[];
|
|
297
|
-
};
|
|
298
|
-
readonly next: readonly {
|
|
299
|
-
readonly nodeId: string;
|
|
300
|
-
}[];
|
|
301
|
-
} | {
|
|
302
|
-
readonly type: "webhook";
|
|
303
|
-
readonly config: {
|
|
304
|
-
readonly data?: {
|
|
305
|
-
readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
|
|
306
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
307
|
-
} | null)[] | {
|
|
308
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
309
|
-
} | null)[] | {
|
|
310
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
311
|
-
} | null)[] | {
|
|
312
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
313
|
-
} | null)[] | {
|
|
314
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
315
|
-
} | null)[] | {
|
|
316
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
317
|
-
} | null)[] | {
|
|
318
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
319
|
-
} | null)[] | {
|
|
320
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
321
|
-
} | null)[] | {
|
|
322
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
323
|
-
} | null)[] | {
|
|
324
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
325
|
-
} | null)[] | {
|
|
326
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
327
|
-
} | null)[] | {
|
|
328
|
-
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
329
|
-
} | null | undefined;
|
|
330
|
-
} | undefined;
|
|
331
|
-
};
|
|
332
|
-
readonly next: readonly {
|
|
333
|
-
readonly nodeId: string;
|
|
334
|
-
}[];
|
|
335
286
|
} | {
|
|
336
287
|
readonly type: "wait_for_event";
|
|
337
288
|
readonly config: {
|
|
@@ -355,10 +306,6 @@ export declare const replaceDraft: (input: {
|
|
|
355
306
|
readonly type: "tag";
|
|
356
307
|
readonly tag: string;
|
|
357
308
|
readonly present: boolean;
|
|
358
|
-
} | {
|
|
359
|
-
readonly type: "event";
|
|
360
|
-
readonly eventName: string;
|
|
361
|
-
readonly occurred: boolean;
|
|
362
309
|
} | {
|
|
363
310
|
readonly type: "property";
|
|
364
311
|
readonly field: "displayName" | "externalId" | "name" | "profile.company" | "profile.firstName" | "profile.jobTitle" | "profile.lastName" | "profile.location.city" | "profile.location.country" | "profile.location.state" | "profile.location.timezone" | "profile.source" | "status";
|
|
@@ -389,9 +336,62 @@ export declare const replaceDraft: (input: {
|
|
|
389
336
|
} | {
|
|
390
337
|
readonly operator: "exists" | "not_exists";
|
|
391
338
|
};
|
|
339
|
+
} | {
|
|
340
|
+
readonly type: "event";
|
|
341
|
+
readonly eventName: string;
|
|
342
|
+
readonly occurred: boolean;
|
|
392
343
|
})[];
|
|
393
344
|
} | undefined;
|
|
394
345
|
}[];
|
|
346
|
+
} | {
|
|
347
|
+
readonly type: "update_tags";
|
|
348
|
+
readonly config: {
|
|
349
|
+
readonly add: readonly string[];
|
|
350
|
+
readonly remove: readonly string[];
|
|
351
|
+
};
|
|
352
|
+
readonly next: readonly {
|
|
353
|
+
readonly nodeId: string;
|
|
354
|
+
}[];
|
|
355
|
+
} | {
|
|
356
|
+
readonly type: "webhook";
|
|
357
|
+
readonly config: {
|
|
358
|
+
readonly data?: {
|
|
359
|
+
readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
|
|
360
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
361
|
+
} | null)[] | {
|
|
362
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
363
|
+
} | null)[] | {
|
|
364
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
365
|
+
} | null)[] | {
|
|
366
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
367
|
+
} | null)[] | {
|
|
368
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
369
|
+
} | null)[] | {
|
|
370
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
371
|
+
} | null)[] | {
|
|
372
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
373
|
+
} | null)[] | {
|
|
374
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
375
|
+
} | null)[] | {
|
|
376
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
377
|
+
} | null)[] | {
|
|
378
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
379
|
+
} | null)[] | {
|
|
380
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
381
|
+
} | null)[] | {
|
|
382
|
+
readonly [x: string]: string | number | boolean | any | any | null | undefined;
|
|
383
|
+
} | null | undefined;
|
|
384
|
+
} | undefined;
|
|
385
|
+
};
|
|
386
|
+
readonly next: readonly {
|
|
387
|
+
readonly nodeId: string;
|
|
388
|
+
}[];
|
|
389
|
+
} | {
|
|
390
|
+
readonly type: "exit";
|
|
391
|
+
readonly config: {
|
|
392
|
+
readonly [x: string]: undefined;
|
|
393
|
+
};
|
|
394
|
+
readonly next: readonly never[];
|
|
395
395
|
} | undefined;
|
|
396
396
|
};
|
|
397
397
|
readonly goal?: {
|
package/dist/package.js
CHANGED
package/dist/promises/index.d.ts
CHANGED
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
* ```
|
|
28
28
|
*/
|
|
29
29
|
import { type Client, type Config } from "../client/client";
|
|
30
|
-
import { Analytics as analytics, ApiKeys as apiKeys, Attachments as attachments, Brands as brands, Campaigns as campaigns, ContactGroups as contactGroups, ContactEvents as contactEvents, Contacts as contacts, Conversations as conversations, CustomFields as customFields, Email as email, ExtensionInstallations as extensionInstallations, Extensions as extensions, Events as events, Feedback as feedback, Journeys as journeys, Mailboxes as mailboxes, Media as media, Messages as messages, Namespaces as namespaces, Operations as operations, Organizations as organizations, ScheduledMessages as scheduledMessages, Subscriptions as subscriptions, Templates as templates, Unsubscribe as unsubscribeGroups, Webhooks as webhooks, Whoami as whoami } from "../client/sdk.gen";
|
|
30
|
+
import { Agents as agents, Analytics as analytics, ApiKeys as apiKeys, Attachments as attachments, Brands as brands, Campaigns as campaigns, ContactGroups as contactGroups, ContactEvents as contactEvents, Contacts as contacts, Conversations as conversations, CustomFields as customFields, Email as email, ExtensionInstallations as extensionInstallations, Extensions as extensions, Events as events, Feedback as feedback, Journeys as journeys, Mailboxes as mailboxes, Media as media, Messages as messages, Namespaces as namespaces, Operations as operations, Organizations as organizations, ScheduledMessages as scheduledMessages, Subscriptions as subscriptions, Templates as templates, Unsubscribe as unsubscribeGroups, Webhooks as webhooks, Whoami as whoami } from "../client/sdk.gen";
|
|
31
31
|
import type { MessagesSendData } from "../client/types.gen";
|
|
32
32
|
import { MailboxEventStream, type MailboxEventStreamOptions } from "../mailbox-events";
|
|
33
33
|
export * from "./errors.gen";
|
|
@@ -138,6 +138,7 @@ export interface SamvaRawClient {
|
|
|
138
138
|
readonly customFields: typeof customFields;
|
|
139
139
|
readonly subscriptions: typeof subscriptions;
|
|
140
140
|
readonly unsubscribeGroups: typeof unsubscribeGroups;
|
|
141
|
+
readonly agents: typeof agents;
|
|
141
142
|
readonly analytics: typeof analytics;
|
|
142
143
|
readonly feedback: typeof feedback;
|
|
143
144
|
readonly whoami: typeof whoami;
|
|
@@ -177,6 +178,7 @@ export interface SamvaClient {
|
|
|
177
178
|
readonly customFields: DirectService<typeof customFields>;
|
|
178
179
|
readonly subscriptions: DirectService<typeof subscriptions>;
|
|
179
180
|
readonly unsubscribeGroups: DirectService<typeof unsubscribeGroups>;
|
|
181
|
+
readonly agents: DirectService<typeof agents>;
|
|
180
182
|
readonly analytics: DirectService<typeof analytics>;
|
|
181
183
|
readonly feedback: DirectService<typeof feedback>;
|
|
182
184
|
readonly whoami: DirectService<typeof whoami>;
|
package/dist/promises/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CLIENT_ATTRIBUTION_HEADER, clientAttribution } from "../client-attribution.js";
|
|
2
2
|
import { mergeHeaders } from "../client/client/utils.gen.js";
|
|
3
3
|
import { createClient as createClient$1 } from "../client/client/client.gen.js";
|
|
4
|
-
import { Analytics, ApiKeys, Attachments, Brands, Campaigns, ContactEvents, ContactGroups, Contacts, Conversations, CustomFields, Email, Events, ExtensionInstallations, Extensions, Feedback, Journeys, Mailboxes, Media, Messages, Namespaces, Operations, Organizations, ScheduledMessages, Subscriptions, Templates, Unsubscribe, Webhooks, Whoami } from "../client/sdk.gen.js";
|
|
4
|
+
import { Agents, Analytics, ApiKeys, Attachments, Brands, Campaigns, ContactEvents, ContactGroups, Contacts, Conversations, CustomFields, Email, Events, ExtensionInstallations, Extensions, Feedback, Journeys, Mailboxes, Media, Messages, Namespaces, Operations, Organizations, ScheduledMessages, Subscriptions, Templates, Unsubscribe, Webhooks, Whoami } from "../client/sdk.gen.js";
|
|
5
5
|
import { MediaUploadError, mediaCreateBody, planInlineUploads, withUploadedAttachments } from "../inline-attachments.js";
|
|
6
6
|
import { MailboxEventStream, MailboxEventStreamError } from "../mailbox-events.js";
|
|
7
7
|
import { buildEmailSendPayload, buildMessagesSendPayload, replyToEmailsPayload } from "../normalize.js";
|
|
@@ -236,6 +236,7 @@ function createClient(config) {
|
|
|
236
236
|
customFields: createBoundService(CustomFields, clientInstance),
|
|
237
237
|
subscriptions: createBoundService(Subscriptions, clientInstance),
|
|
238
238
|
unsubscribeGroups: createBoundService(Unsubscribe, clientInstance),
|
|
239
|
+
agents: createBoundService(Agents, clientInstance),
|
|
239
240
|
analytics: createBoundService(Analytics, clientInstance),
|
|
240
241
|
feedback: createBoundService(Feedback, clientInstance),
|
|
241
242
|
whoami: createBoundService(Whoami, clientInstance),
|
|
@@ -273,6 +274,7 @@ function createClient(config) {
|
|
|
273
274
|
customFields: createDirectService(raw.customFields),
|
|
274
275
|
subscriptions: createDirectService(raw.subscriptions),
|
|
275
276
|
unsubscribeGroups: createDirectService(raw.unsubscribeGroups),
|
|
277
|
+
agents: createDirectService(raw.agents),
|
|
276
278
|
analytics: createDirectService(raw.analytics),
|
|
277
279
|
feedback: createDirectService(raw.feedback),
|
|
278
280
|
whoami: createDirectService(raw.whoami),
|
package/dist/service-map.d.ts
CHANGED
|
@@ -4,6 +4,17 @@
|
|
|
4
4
|
* is visible in review and test failures.
|
|
5
5
|
*/
|
|
6
6
|
export declare const SDK_SERVICE_OPERATIONS: {
|
|
7
|
+
readonly agents: {
|
|
8
|
+
readonly list: "agentsList";
|
|
9
|
+
readonly create: "agentsCreate";
|
|
10
|
+
readonly get: "agentsGet";
|
|
11
|
+
readonly update: "agentsUpdate";
|
|
12
|
+
readonly remove: "agentsRemove";
|
|
13
|
+
readonly replaceDraft: "agentsReplaceDraft";
|
|
14
|
+
readonly publish: "agentsPublish";
|
|
15
|
+
readonly listVersions: "agentsListVersions";
|
|
16
|
+
readonly getVersion: "agentsGetVersion";
|
|
17
|
+
};
|
|
7
18
|
readonly analytics: {
|
|
8
19
|
readonly getStats: "analyticsGetStats";
|
|
9
20
|
readonly getChannelStats: "analyticsGetChannelStats";
|
|
@@ -1291,6 +1302,40 @@ export declare const SDK_OPERATION_CALLS: {
|
|
|
1291
1302
|
readonly unsubscribeCheckSubscription: {
|
|
1292
1303
|
readonly kind: "params";
|
|
1293
1304
|
};
|
|
1305
|
+
readonly agentsList: {
|
|
1306
|
+
readonly kind: "params";
|
|
1307
|
+
};
|
|
1308
|
+
readonly agentsCreate: {
|
|
1309
|
+
readonly kind: "payload";
|
|
1310
|
+
};
|
|
1311
|
+
readonly agentsGet: {
|
|
1312
|
+
readonly kind: "path";
|
|
1313
|
+
readonly paths: readonly ["id"];
|
|
1314
|
+
};
|
|
1315
|
+
readonly agentsUpdate: {
|
|
1316
|
+
readonly kind: "pathPayload";
|
|
1317
|
+
readonly paths: readonly ["id"];
|
|
1318
|
+
};
|
|
1319
|
+
readonly agentsRemove: {
|
|
1320
|
+
readonly kind: "path";
|
|
1321
|
+
readonly paths: readonly ["id"];
|
|
1322
|
+
};
|
|
1323
|
+
readonly agentsReplaceDraft: {
|
|
1324
|
+
readonly kind: "pathPayload";
|
|
1325
|
+
readonly paths: readonly ["id"];
|
|
1326
|
+
};
|
|
1327
|
+
readonly agentsPublish: {
|
|
1328
|
+
readonly kind: "pathPayload";
|
|
1329
|
+
readonly paths: readonly ["id"];
|
|
1330
|
+
};
|
|
1331
|
+
readonly agentsListVersions: {
|
|
1332
|
+
readonly kind: "pathParams";
|
|
1333
|
+
readonly paths: readonly ["id"];
|
|
1334
|
+
};
|
|
1335
|
+
readonly agentsGetVersion: {
|
|
1336
|
+
readonly kind: "path";
|
|
1337
|
+
readonly paths: readonly ["id", "version"];
|
|
1338
|
+
};
|
|
1294
1339
|
readonly analyticsGetStats: {
|
|
1295
1340
|
readonly kind: "params";
|
|
1296
1341
|
};
|
package/dist/service-map.js
CHANGED
|
@@ -744,6 +744,36 @@ const SDK_OPERATION_CALLS = {
|
|
|
744
744
|
paths: ["id"]
|
|
745
745
|
},
|
|
746
746
|
unsubscribeCheckSubscription: { kind: "params" },
|
|
747
|
+
agentsList: { kind: "params" },
|
|
748
|
+
agentsCreate: { kind: "payload" },
|
|
749
|
+
agentsGet: {
|
|
750
|
+
kind: "path",
|
|
751
|
+
paths: ["id"]
|
|
752
|
+
},
|
|
753
|
+
agentsUpdate: {
|
|
754
|
+
kind: "pathPayload",
|
|
755
|
+
paths: ["id"]
|
|
756
|
+
},
|
|
757
|
+
agentsRemove: {
|
|
758
|
+
kind: "path",
|
|
759
|
+
paths: ["id"]
|
|
760
|
+
},
|
|
761
|
+
agentsReplaceDraft: {
|
|
762
|
+
kind: "pathPayload",
|
|
763
|
+
paths: ["id"]
|
|
764
|
+
},
|
|
765
|
+
agentsPublish: {
|
|
766
|
+
kind: "pathPayload",
|
|
767
|
+
paths: ["id"]
|
|
768
|
+
},
|
|
769
|
+
agentsListVersions: {
|
|
770
|
+
kind: "pathParams",
|
|
771
|
+
paths: ["id"]
|
|
772
|
+
},
|
|
773
|
+
agentsGetVersion: {
|
|
774
|
+
kind: "path",
|
|
775
|
+
paths: ["id", "version"]
|
|
776
|
+
},
|
|
747
777
|
analyticsGetStats: { kind: "params" },
|
|
748
778
|
analyticsGetChannelStats: { kind: "params" },
|
|
749
779
|
analyticsGetTopContacts: { kind: "params" },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "samva",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.27.0",
|
|
4
4
|
"description": "TypeScript SDK for the Samva email API",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"api-client",
|
|
@@ -55,6 +55,10 @@
|
|
|
55
55
|
"types": "./dist/effect/categories.d.ts",
|
|
56
56
|
"import": "./dist/effect/categories.js"
|
|
57
57
|
},
|
|
58
|
+
"./effect/agents": {
|
|
59
|
+
"types": "./dist/effect/agents.d.ts",
|
|
60
|
+
"import": "./dist/effect/agents.js"
|
|
61
|
+
},
|
|
58
62
|
"./effect/analytics": {
|
|
59
63
|
"types": "./dist/effect/analytics.d.ts",
|
|
60
64
|
"import": "./dist/effect/analytics.js"
|
|
@@ -191,7 +195,7 @@
|
|
|
191
195
|
"generate:promises": "bun run codegen/generate-promises.ts && bun run scripts/generate-promise-errors.ts && oxfmt --config=../../oxfmt.config.ts src/client src/promises/errors.gen.ts src/promises/types.gen.ts",
|
|
192
196
|
"generate:effect": "bun run codegen/generate-effect.ts && oxfmt --config=../../oxfmt.config.ts src/effect/generated src/effect/generated-metadata.ts && bun run codegen/normalize-effect.ts",
|
|
193
197
|
"generate": "bun run --filter @samva/openapi fetch && bun generate:openapi && bun generate:promises && bun generate:effect",
|
|
194
|
-
"test": "vitest run --root ../.. --project packages",
|
|
198
|
+
"test": "vitest run --root ../.. --project packages packages/sdk/tests",
|
|
195
199
|
"test:generation": "bun scripts/check-generation.ts",
|
|
196
200
|
"test:packed": "bun run build && bun scripts/test-packed-consumers.ts",
|
|
197
201
|
"test:tarball": "bun run build && bun scripts/check-tarball.ts",
|
|
@@ -200,7 +204,7 @@
|
|
|
200
204
|
"typecheck": "tsc-rs --noEmit && tsc-rs --noEmit -p codegen/tsconfig.json && tsc-rs --noEmit -p tests/tsconfig.json && tsc-rs --noEmit --project tests/parity/tsconfig.json"
|
|
201
205
|
},
|
|
202
206
|
"dependencies": {
|
|
203
|
-
"@samva/webhooks": "0.
|
|
207
|
+
"@samva/webhooks": "0.27.0"
|
|
204
208
|
},
|
|
205
209
|
"devDependencies": {
|
|
206
210
|
"@effect/openapi-generator": "4.0.4",
|