samva 0.27.0 → 0.28.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/AGENTS.md +7 -0
- package/README.md +12 -7
- package/dist/client/sdk.gen.d.ts +322 -143
- package/dist/client/sdk.gen.js +604 -95
- package/dist/client/types.gen.d.ts +1342 -479
- package/dist/effect/agents.d.ts +6 -8
- package/dist/effect/analytics.d.ts +1 -1
- package/dist/effect/api-keys.d.ts +6 -6
- package/dist/effect/attachments.d.ts +1 -1
- package/dist/effect/brands.d.ts +2 -0
- package/dist/effect/campaigns.d.ts +275 -25
- package/dist/effect/campaigns.js +7 -1
- package/dist/effect/contact-groups.d.ts +9 -9
- package/dist/effect/contacts.d.ts +74 -81
- package/dist/effect/contacts.js +7 -3
- package/dist/effect/conversations.d.ts +14 -6
- package/dist/effect/email.d.ts +34 -34
- package/dist/effect/errors.d.ts +1 -1
- package/dist/effect/errors.js +2 -2
- package/dist/effect/extension-installations.d.ts +3 -3
- package/dist/effect/extensions.d.ts +6 -6
- package/dist/effect/generated/agents.d.ts +6 -28
- package/dist/effect/generated/agents.js +2 -3
- package/dist/effect/generated/analytics.d.ts +3 -3
- package/dist/effect/generated/analytics.js +1 -1
- package/dist/effect/generated/api-keys.d.ts +6 -6
- package/dist/effect/generated/api-keys.js +2 -2
- package/dist/effect/generated/attachments.d.ts +3 -3
- package/dist/effect/generated/attachments.js +1 -1
- package/dist/effect/generated/brands.d.ts +16 -0
- package/dist/effect/generated/campaigns.d.ts +1181 -302
- package/dist/effect/generated/campaigns.js +169 -36
- package/dist/effect/generated/contact-events.d.ts +3 -3
- package/dist/effect/generated/contact-events.js +1 -1
- package/dist/effect/generated/contact-groups.d.ts +9 -9
- package/dist/effect/generated/contact-groups.js +7 -7
- package/dist/effect/generated/contacts.d.ts +2063 -290
- package/dist/effect/generated/contacts.js +343 -75
- package/dist/effect/generated/conversations.d.ts +14 -6
- package/dist/effect/generated/conversations.js +6 -6
- package/dist/effect/generated/email.d.ts +40 -40
- package/dist/effect/generated/email.js +15 -15
- package/dist/effect/generated/extension-installations.d.ts +3 -3
- package/dist/effect/generated/extension-installations.js +1 -1
- package/dist/effect/generated/extensions.d.ts +6 -6
- package/dist/effect/generated/extensions.js +2 -2
- package/dist/effect/generated/index.d.ts +5 -3
- package/dist/effect/generated/journeys.d.ts +9 -9
- package/dist/effect/generated/journeys.js +3 -3
- package/dist/effect/generated/mailboxes.d.ts +172 -124
- package/dist/effect/generated/mailboxes.js +22 -14
- package/dist/effect/generated/messages.d.ts +53 -29
- package/dist/effect/generated/messages.js +9 -5
- package/dist/effect/generated/namespaces.d.ts +3 -3
- package/dist/effect/generated/namespaces.js +1 -1
- package/dist/effect/generated/operations.d.ts +3 -3
- package/dist/effect/generated/operations.js +1 -1
- package/dist/effect/generated/organizations.d.ts +0 -9
- package/dist/effect/generated/organizations.js +1 -4
- package/dist/effect/generated/scheduled-messages.d.ts +69 -20
- package/dist/effect/generated/scheduled-messages.js +22 -3
- package/dist/effect/generated/shared.d.ts +396 -107
- package/dist/effect/generated/shared.js +170 -89
- package/dist/effect/generated/subscriptions.d.ts +4 -7
- package/dist/effect/generated/subscriptions.js +3 -4
- package/dist/effect/generated/templates.d.ts +71 -407
- package/dist/effect/generated/templates.js +23 -23
- package/dist/effect/generated/topic-forms.d.ts +656 -0
- package/dist/effect/generated/topic-forms.js +145 -0
- package/dist/effect/generated/{unsubscribe-groups.d.ts → topics.d.ts} +640 -435
- package/dist/effect/generated/topics.js +267 -0
- package/dist/effect/generated/webhooks.d.ts +6 -6
- package/dist/effect/generated/webhooks.js +2 -2
- package/dist/effect/generated-metadata.d.ts +78 -24
- package/dist/effect/generated-metadata.js +61 -27
- package/dist/effect/index.d.ts +2 -1
- package/dist/effect/index.js +4 -3
- package/dist/effect/internal/operation.js +3 -3
- package/dist/effect/internal/send.d.ts +4 -4
- package/dist/effect/journeys.d.ts +7 -7
- package/dist/effect/mailboxes.d.ts +137 -121
- package/dist/effect/messages.d.ts +19 -11
- package/dist/effect/namespaces.d.ts +3 -3
- package/dist/effect/operations.d.ts +3 -3
- package/dist/effect/scheduled-messages.d.ts +6 -6
- package/dist/effect/subscriptions.d.ts +1 -2
- package/dist/effect/templates.d.ts +13 -13
- package/dist/effect/topic-forms.d.ts +30 -0
- package/dist/effect/topic-forms.js +21 -0
- package/dist/effect/topics.d.ts +94 -0
- package/dist/effect/topics.js +29 -0
- package/dist/effect/webhooks.d.ts +6 -6
- package/dist/index.js +2 -2
- package/dist/package.js +1 -1
- package/dist/promises/errors.gen.d.ts +65 -8
- package/dist/promises/errors.gen.js +139 -7
- package/dist/promises/index.d.ts +5 -3
- package/dist/promises/index.js +7 -5
- package/dist/promises/types.gen.d.ts +1 -1
- package/dist/service-map.d.ts +74 -25
- package/dist/service-map.js +43 -12
- package/package.json +12 -8
- package/dist/effect/generated/unsubscribe-groups.js +0 -284
- package/dist/effect/unsubscribe-groups.d.ts +0 -74
- package/dist/effect/unsubscribe-groups.js +0 -29
|
@@ -65,7 +65,7 @@ const PublishExtensionVersionResponse = /* @__PURE__ */ Schema.Struct({
|
|
|
65
65
|
version: ExtensionVersion
|
|
66
66
|
}).annotate({ identifier: "PublishExtensionVersionResponse" });
|
|
67
67
|
const ExtensionsListQuery = /* @__PURE__ */ Schema.Struct({
|
|
68
|
-
limit: Schema.optionalKey(Schema.Union([Schema.
|
|
68
|
+
limit: Schema.optionalKey(Schema.Union([Schema.Finite.annotate({ description: "Items per page, at most 100." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isLessThanOrEqualTo(100).annotate({ expected: "a value less than or equal to 100" })).check(Schema.isGreaterThan(0).annotate({ expected: "a value greater than 0" })), Schema.Null])),
|
|
69
69
|
cursor: Schema.optionalKey(Schema.Union([Cursor, Schema.Null])),
|
|
70
70
|
after: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])),
|
|
71
71
|
before: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]))
|
|
@@ -120,7 +120,7 @@ const ExtensionsGet500 = InternalError;
|
|
|
120
120
|
const ExtensionsGet504 = GatewayTimeoutError;
|
|
121
121
|
const ExtensionsListVersionsPathParams = /* @__PURE__ */ Schema.Struct({ id: Schema.String.annotate({ description: "The extension's id (`ext_…`) or its name." }).check(Schema.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })).check(Schema.isMaxCodePoints(64).annotate({ expected: "a string with at most 64 code points" })).check(Schema.isMaxLength(64).annotate({ expected: "a value with a length of at most 64" })) });
|
|
122
122
|
const ExtensionsListVersionsQuery = /* @__PURE__ */ Schema.Struct({
|
|
123
|
-
limit: Schema.optionalKey(Schema.Union([Schema.
|
|
123
|
+
limit: Schema.optionalKey(Schema.Union([Schema.Finite.annotate({ description: "Items per page, at most 100." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isLessThanOrEqualTo(100).annotate({ expected: "a value less than or equal to 100" })).check(Schema.isGreaterThan(0).annotate({ expected: "a value greater than 0" })), Schema.Null])),
|
|
124
124
|
cursor: Schema.optionalKey(Schema.Union([Cursor, Schema.Null]))
|
|
125
125
|
});
|
|
126
126
|
const ExtensionsListVersions200 = ExtensionVersionPage;
|
|
@@ -25,7 +25,8 @@ import { OrganizationsGroup } from "./organizations";
|
|
|
25
25
|
import { ScheduledMessagesGroup } from "./scheduled-messages";
|
|
26
26
|
import { SubscriptionsGroup } from "./subscriptions";
|
|
27
27
|
import { TemplatesGroup } from "./templates";
|
|
28
|
-
import {
|
|
28
|
+
import { TopicFormsGroup } from "./topic-forms";
|
|
29
|
+
import { TopicsGroup } from "./topics";
|
|
29
30
|
import { WebhooksGroup } from "./webhooks";
|
|
30
31
|
import { WhoamiGroup } from "./whoami";
|
|
31
32
|
export * from "./shared";
|
|
@@ -55,9 +56,10 @@ export * from "./operations";
|
|
|
55
56
|
export * from "./organizations";
|
|
56
57
|
export * from "./subscriptions";
|
|
57
58
|
export * from "./templates";
|
|
58
|
-
export * from "./
|
|
59
|
+
export * from "./topics";
|
|
60
|
+
export * from "./topic-forms";
|
|
59
61
|
export * from "./webhooks";
|
|
60
62
|
export * from "./whoami";
|
|
61
|
-
declare const SamvaApi_base: HttpApi.HttpApi<"SamvaApi", typeof AgentsGroup | typeof AnalyticsGroup | typeof APIKeysGroup | typeof AttachmentsGroup | typeof BrandsGroup | typeof CampaignsGroup | typeof ContactEventsGroup | typeof ContactGroupsGroup | typeof ContactsGroup | typeof ConversationsGroup | typeof CustomFieldsGroup | typeof EmailGroup | typeof EventsGroup | typeof ExtensionInstallationsGroup | typeof ExtensionsGroup | typeof FeedbackGroup | typeof JourneysGroup | typeof MailboxesGroup | typeof MediaGroup | typeof MessagesGroup | typeof NamespacesGroup | typeof OperationsGroup | typeof OrganizationsGroup | typeof ScheduledMessagesGroup | typeof SubscriptionsGroup | typeof TemplatesGroup | typeof
|
|
63
|
+
declare const SamvaApi_base: HttpApi.HttpApi<"SamvaApi", typeof AgentsGroup | typeof AnalyticsGroup | typeof APIKeysGroup | typeof AttachmentsGroup | typeof BrandsGroup | typeof CampaignsGroup | typeof ContactEventsGroup | typeof ContactGroupsGroup | typeof ContactsGroup | typeof ConversationsGroup | typeof CustomFieldsGroup | typeof EmailGroup | typeof EventsGroup | typeof ExtensionInstallationsGroup | typeof ExtensionsGroup | typeof FeedbackGroup | typeof JourneysGroup | typeof MailboxesGroup | typeof MediaGroup | typeof MessagesGroup | typeof NamespacesGroup | typeof OperationsGroup | typeof OrganizationsGroup | typeof ScheduledMessagesGroup | typeof SubscriptionsGroup | typeof TemplatesGroup | typeof TopicFormsGroup | typeof TopicsGroup | typeof WebhooksGroup | typeof WhoamiGroup>;
|
|
62
64
|
export declare class SamvaApi extends SamvaApi_base {
|
|
63
65
|
}
|
|
@@ -584,12 +584,12 @@ export declare const JourneyVersion: Schema.Struct<{
|
|
|
584
584
|
}>;
|
|
585
585
|
export type JourneysListQuery = {
|
|
586
586
|
readonly status?: JourneyStatus | null;
|
|
587
|
-
readonly limit?:
|
|
587
|
+
readonly limit?: number | null;
|
|
588
588
|
readonly cursor?: Cursor | null;
|
|
589
589
|
};
|
|
590
590
|
export declare const JourneysListQuery: Schema.Struct<{
|
|
591
591
|
readonly status: Schema.optionalKey<Schema.Union<readonly [Schema.Union<readonly [Schema.Literal<"draft">, Schema.Literal<"active">, Schema.Literal<"paused">, Schema.Literal<"archived">]>, Schema.Null]>>;
|
|
592
|
-
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.
|
|
592
|
+
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Null]>>;
|
|
593
593
|
readonly cursor: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
|
|
594
594
|
}>;
|
|
595
595
|
export type JourneysList200 = JourneyPage;
|
|
@@ -2509,13 +2509,13 @@ export declare const JourneysListRunsPathParams: Schema.Struct<{
|
|
|
2509
2509
|
export type JourneysListRunsQuery = {
|
|
2510
2510
|
readonly status?: JourneyRunStatus | null;
|
|
2511
2511
|
readonly contactId?: ContactId | null;
|
|
2512
|
-
readonly limit?:
|
|
2512
|
+
readonly limit?: number | null;
|
|
2513
2513
|
readonly cursor?: Cursor | null;
|
|
2514
2514
|
};
|
|
2515
2515
|
export declare const JourneysListRunsQuery: Schema.Struct<{
|
|
2516
2516
|
readonly status: Schema.optionalKey<Schema.Union<readonly [Schema.Union<readonly [Schema.Literal<"active">, Schema.Literal<"paused">, Schema.Literal<"exited">, Schema.Literal<"failed">]>, Schema.Null]>>;
|
|
2517
2517
|
readonly contactId: Schema.optionalKey<Schema.Union<readonly [Schema.brand<Schema.String, "ContactId">, Schema.Null]>>;
|
|
2518
|
-
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.
|
|
2518
|
+
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Null]>>;
|
|
2519
2519
|
readonly cursor: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
|
|
2520
2520
|
}>;
|
|
2521
2521
|
export type JourneysListRuns200 = JourneyRunPage;
|
|
@@ -2610,10 +2610,10 @@ export declare const JourneysStatsPathParams: Schema.Struct<{
|
|
|
2610
2610
|
readonly id: Schema.brand<Schema.String, "JourneyId">;
|
|
2611
2611
|
}>;
|
|
2612
2612
|
export type JourneysStatsQuery = {
|
|
2613
|
-
readonly version?:
|
|
2613
|
+
readonly version?: number | null;
|
|
2614
2614
|
};
|
|
2615
2615
|
export declare const JourneysStatsQuery: Schema.Struct<{
|
|
2616
|
-
readonly version: Schema.optionalKey<Schema.Union<readonly [Schema.
|
|
2616
|
+
readonly version: Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Null]>>;
|
|
2617
2617
|
}>;
|
|
2618
2618
|
export type JourneysStats200 = JourneyStats;
|
|
2619
2619
|
export declare const JourneysStats200: Schema.Struct<{
|
|
@@ -4154,7 +4154,7 @@ declare const JourneysGroup_base: HttpApiGroup.HttpApiGroup<"Journeys", HttpApiE
|
|
|
4154
4154
|
readonly fields: Schema.optionalKey<Schema.Union<readonly [Schema.$Record<Schema.String, Schema.$Array<Schema.String>>, Schema.Null]>>;
|
|
4155
4155
|
}>, never, never> | typeof InternalError>, ApiKeySecurityMiddleware, never> | HttpApiEndpoint.HttpApiEndpoint<"journeysList", "GET", "/v1/journeys", never, Schema.toCodecStringTree<Schema.Struct<{
|
|
4156
4156
|
readonly status: Schema.optionalKey<Schema.Union<readonly [Schema.Union<readonly [Schema.Literal<"draft">, Schema.Literal<"active">, Schema.Literal<"paused">, Schema.Literal<"archived">]>, Schema.Null]>>;
|
|
4157
|
-
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.
|
|
4157
|
+
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Null]>>;
|
|
4158
4158
|
readonly cursor: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
|
|
4159
4159
|
}>>, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
4160
4160
|
readonly items: Schema.$Array<Schema.Struct<{
|
|
@@ -4232,7 +4232,7 @@ declare const JourneysGroup_base: HttpApiGroup.HttpApiGroup<"Journeys", HttpApiE
|
|
|
4232
4232
|
}>>, Schema.toCodecStringTree<Schema.Struct<{
|
|
4233
4233
|
readonly status: Schema.optionalKey<Schema.Union<readonly [Schema.Union<readonly [Schema.Literal<"active">, Schema.Literal<"paused">, Schema.Literal<"exited">, Schema.Literal<"failed">]>, Schema.Null]>>;
|
|
4234
4234
|
readonly contactId: Schema.optionalKey<Schema.Union<readonly [Schema.brand<Schema.String, "ContactId">, Schema.Null]>>;
|
|
4235
|
-
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.
|
|
4235
|
+
readonly limit: Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Null]>>;
|
|
4236
4236
|
readonly cursor: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
|
|
4237
4237
|
}>>, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
4238
4238
|
readonly items: Schema.$Array<Schema.Struct<{
|
|
@@ -5753,7 +5753,7 @@ declare const JourneysGroup_base: HttpApiGroup.HttpApiGroup<"Journeys", HttpApiE
|
|
|
5753
5753
|
}>, never, never> | typeof InternalError>, ApiKeySecurityMiddleware, never> | HttpApiEndpoint.HttpApiEndpoint<"journeysStats", "GET", "/v1/journeys/:id/stats", Schema.toCodecStringTree<Schema.Struct<{
|
|
5754
5754
|
readonly id: Schema.brand<Schema.String, "JourneyId">;
|
|
5755
5755
|
}>>, Schema.toCodecStringTree<Schema.Struct<{
|
|
5756
|
-
readonly version: Schema.optionalKey<Schema.Union<readonly [Schema.
|
|
5756
|
+
readonly version: Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Null]>>;
|
|
5757
5757
|
}>>, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
5758
5758
|
readonly journeyId: Schema.brand<Schema.String, "JourneyId">;
|
|
5759
5759
|
readonly version: Schema.Finite;
|
|
@@ -138,7 +138,7 @@ const JourneyVersion = /* @__PURE__ */ Schema.Struct({
|
|
|
138
138
|
}).annotate({ identifier: "JourneyVersion" });
|
|
139
139
|
const JourneysListQuery = /* @__PURE__ */ Schema.Struct({
|
|
140
140
|
status: Schema.optionalKey(Schema.Union([JourneyStatus, Schema.Null])),
|
|
141
|
-
limit: Schema.optionalKey(Schema.Union([Schema.
|
|
141
|
+
limit: Schema.optionalKey(Schema.Union([Schema.Finite.annotate({ description: "Items per page, at most 100." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isLessThanOrEqualTo(100).annotate({ expected: "a value less than or equal to 100" })).check(Schema.isGreaterThan(0).annotate({ expected: "a value greater than 0" })), Schema.Null])),
|
|
142
142
|
cursor: Schema.optionalKey(Schema.Union([Cursor, Schema.Null]))
|
|
143
143
|
});
|
|
144
144
|
const JourneysList200 = JourneyPage;
|
|
@@ -247,7 +247,7 @@ const JourneysListRunsPathParams = /* @__PURE__ */ Schema.Struct({ id: JourneyId
|
|
|
247
247
|
const JourneysListRunsQuery = /* @__PURE__ */ Schema.Struct({
|
|
248
248
|
status: Schema.optionalKey(Schema.Union([JourneyRunStatus, Schema.Null])),
|
|
249
249
|
contactId: Schema.optionalKey(Schema.Union([ContactId, Schema.Null])),
|
|
250
|
-
limit: Schema.optionalKey(Schema.Union([Schema.
|
|
250
|
+
limit: Schema.optionalKey(Schema.Union([Schema.Finite.annotate({ description: "Items per page, at most 100." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isLessThanOrEqualTo(100).annotate({ expected: "a value less than or equal to 100" })).check(Schema.isGreaterThan(0).annotate({ expected: "a value greater than 0" })), Schema.Null])),
|
|
251
251
|
cursor: Schema.optionalKey(Schema.Union([Cursor, Schema.Null]))
|
|
252
252
|
});
|
|
253
253
|
const JourneysListRuns200 = JourneyRunPage;
|
|
@@ -269,7 +269,7 @@ const JourneysGetRun422 = ValidationError;
|
|
|
269
269
|
const JourneysGetRun500 = InternalError;
|
|
270
270
|
const JourneysGetRun504 = GatewayTimeoutError;
|
|
271
271
|
const JourneysStatsPathParams = /* @__PURE__ */ Schema.Struct({ id: JourneyId });
|
|
272
|
-
const JourneysStatsQuery = /* @__PURE__ */ Schema.Struct({ version: Schema.optionalKey(Schema.Union([Schema.
|
|
272
|
+
const JourneysStatsQuery = /* @__PURE__ */ Schema.Struct({ version: Schema.optionalKey(Schema.Union([Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isLessThanOrEqualTo(9007199254740991).annotate({ expected: "a value less than or equal to 9007199254740991" })).check(Schema.isGreaterThan(0).annotate({ expected: "a value greater than 0" })), Schema.Null])) });
|
|
273
273
|
const JourneysStats200 = JourneyStats;
|
|
274
274
|
const JourneysStats401 = UnauthorizedError;
|
|
275
275
|
const JourneysStats403 = ForbiddenError;
|