samva 0.54.0 → 0.55.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 +1 -1
- package/README.md +1 -0
- package/dist/_virtual/_rolldown/runtime.js +4 -4
- package/dist/agent/index.js +1 -1
- package/dist/client/client/client.gen.js +1 -2
- package/dist/client/client/utils.gen.js +1 -1
- package/dist/client/client.gen.js +1 -1
- package/dist/client/sdk.gen.d.ts +57 -3
- package/dist/client/sdk.gen.js +184 -8
- package/dist/client/types.gen.d.ts +420 -1
- package/dist/client-attribution.js +1 -1
- package/dist/effect/agents.js +1 -1
- package/dist/effect/analytics.js +1 -1
- package/dist/effect/api-keys.js +1 -1
- package/dist/effect/approval-requests.js +1 -1
- package/dist/effect/attachments.js +1 -1
- package/dist/effect/brands.js +2 -2
- package/dist/effect/campaigns.d.ts +66 -56
- package/dist/effect/campaigns.js +1 -1
- package/dist/effect/categories.js +6 -6
- package/dist/effect/contact-groups.js +1 -1
- package/dist/effect/contacts.js +1 -1
- package/dist/effect/conversations.js +1 -1
- package/dist/effect/custom-fields.js +1 -1
- package/dist/effect/descriptors/phone-numbers.d.ts +49 -0
- package/dist/effect/descriptors/phone-numbers.js +47 -0
- package/dist/effect/descriptors/topics.d.ts +1 -1
- package/dist/effect/descriptors/topics.js +1 -1
- package/dist/effect/email.js +1 -1
- package/dist/effect/errors.d.ts +1 -1
- package/dist/effect/errors.js +2 -2
- package/dist/effect/events.js +2 -2
- package/dist/effect/feedback.js +2 -2
- package/dist/effect/generated/accounts.d.ts +12 -1
- package/dist/effect/generated/accounts.js +2 -1
- package/dist/effect/generated/agents.js +7 -7
- package/dist/effect/generated/analytics.js +16 -16
- package/dist/effect/generated/api-keys.js +5 -5
- package/dist/effect/generated/approval-requests.js +1 -1
- package/dist/effect/generated/attachments.js +4 -4
- package/dist/effect/generated/brands.js +1 -1
- package/dist/effect/generated/campaigns.d.ts +17 -1
- package/dist/effect/generated/campaigns.js +15 -14
- package/dist/effect/generated/contact-events.js +1 -1
- package/dist/effect/generated/contact-groups.js +12 -12
- package/dist/effect/generated/contacts.js +50 -50
- package/dist/effect/generated/conversations.js +7 -7
- package/dist/effect/generated/custom-fields.js +6 -6
- package/dist/effect/generated/email.js +48 -48
- package/dist/effect/generated/events.js +5 -5
- package/dist/effect/generated/feedback.js +1 -1
- package/dist/effect/generated/index.d.ts +3 -1
- package/dist/effect/generated/integrations-catalog.d.ts +16 -0
- package/dist/effect/generated/integrations-catalog.js +10 -6
- package/dist/effect/generated/integrations.js +5 -5
- package/dist/effect/generated/journeys.d.ts +38 -1
- package/dist/effect/generated/journeys.js +16 -14
- package/dist/effect/generated/logs.js +2 -2
- package/dist/effect/generated/mailboxes.d.ts +41 -3
- package/dist/effect/generated/mailboxes.js +48 -50
- package/dist/effect/generated/media.js +1 -1
- package/dist/effect/generated/messages.js +5 -5
- package/dist/effect/generated/namespaces.d.ts +9 -9
- package/dist/effect/generated/namespaces.js +1 -1
- package/dist/effect/generated/newsletter-domains.js +1 -1
- package/dist/effect/generated/newsletter-issues.js +69 -69
- package/dist/effect/generated/newsletters.js +1 -1
- package/dist/effect/generated/operations.js +1 -1
- package/dist/effect/generated/organizations.d.ts +3 -0
- package/dist/effect/generated/organizations.js +2 -1
- package/dist/effect/generated/phone-numbers.d.ts +817 -0
- package/dist/effect/generated/phone-numbers.js +230 -0
- package/dist/effect/generated/policies.js +2 -2
- package/dist/effect/generated/scheduled-messages.js +1 -1
- package/dist/effect/generated/shared.d.ts +31 -10
- package/dist/effect/generated/shared.js +34 -13
- package/dist/effect/generated/subscriptions.js +1 -1
- package/dist/effect/generated/template-registrations.js +1 -1
- package/dist/effect/generated/template-share-links.js +9 -9
- package/dist/effect/generated/templates.js +119 -119
- package/dist/effect/generated/topic-forms.js +1 -1
- package/dist/effect/generated/topics.d.ts +10 -0
- package/dist/effect/generated/topics.js +20 -13
- package/dist/effect/generated/webhooks.js +18 -18
- package/dist/effect/generated/whats-app-flows.js +5 -5
- package/dist/effect/generated/whats-app-setup-links.js +1 -1
- package/dist/effect/generated/whats-app.d.ts +75 -0
- package/dist/effect/generated/whats-app.js +43 -18
- package/dist/effect/generated/whoami.js +1 -1
- package/dist/effect/generated-metadata.d.ts +35 -1
- package/dist/effect/generated-metadata.js +173 -146
- package/dist/effect/index.d.ts +1 -0
- package/dist/effect/index.js +6 -5
- package/dist/effect/integrations-catalog.js +1 -1
- package/dist/effect/integrations.js +1 -1
- package/dist/effect/internal/client.js +6 -6
- package/dist/effect/internal/email-sender.js +3 -3
- package/dist/effect/internal/log-events.js +2 -2
- package/dist/effect/internal/mailbox-events.js +1 -1
- package/dist/effect/internal/operation.js +2 -2
- package/dist/effect/internal/send.js +4 -4
- package/dist/effect/journeys.d.ts +10 -0
- package/dist/effect/journeys.js +1 -1
- package/dist/effect/logs.js +1 -1
- package/dist/effect/mailboxes.d.ts +191 -191
- package/dist/effect/mailboxes.js +3 -3
- package/dist/effect/media.js +2 -2
- package/dist/effect/messages.js +2 -2
- package/dist/effect/namespaces.d.ts +2 -2
- package/dist/effect/namespaces.js +1 -1
- package/dist/effect/newsletter-domains.js +1 -1
- package/dist/effect/newsletter-issues.js +1 -1
- package/dist/effect/newsletters.js +1 -1
- package/dist/effect/operations.js +1 -1
- package/dist/effect/organizations.js +1 -1
- package/dist/effect/phone-numbers.d.ts +22 -0
- package/dist/effect/phone-numbers.js +21 -0
- package/dist/effect/policies.js +1 -1
- package/dist/effect/retry.js +3 -3
- package/dist/effect/scheduled-messages.d.ts +350 -350
- package/dist/effect/scheduled-messages.js +1 -1
- package/dist/effect/subscriptions.js +1 -1
- package/dist/effect/template-registrations.js +1 -1
- package/dist/effect/template-share-links.js +1 -1
- package/dist/effect/templates.js +2 -2
- package/dist/effect/topic-forms.js +1 -1
- package/dist/effect/topics.d.ts +70 -2
- package/dist/effect/topics.js +1 -1
- package/dist/effect/webhooks.js +2 -2
- package/dist/effect/whatsapp-flows.js +1 -1
- package/dist/effect/whatsapp-setup-links.js +1 -1
- package/dist/effect/whatsapp.d.ts +10 -0
- package/dist/effect/whatsapp.js +1 -1
- package/dist/effect/whoami.js +1 -1
- package/dist/index.js +2 -2
- package/dist/package.json.js +5 -0
- package/dist/promises/client.d.ts +3 -1
- package/dist/promises/client.js +7 -5
- package/dist/promises/errors.gen.d.ts +16 -2
- package/dist/promises/errors.gen.js +48 -11
- package/dist/promises/index.js +3 -3
- package/dist/promises/types.gen.d.ts +1 -1
- package/dist/request-policy.js +1 -1
- package/dist/service-map.d.ts +25 -0
- package/package.json +9 -5
- package/dist/package.js +0 -5
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AbsoluteInstant } from "../runtime.js";
|
|
2
|
-
import { AnalyticsQueryError, ApiKeySecurityMiddleware, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, NamespaceId, UnauthorizedError, ValidationError } from "./shared.js";
|
|
3
2
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
4
3
|
import * as Schema from "effect/Schema";
|
|
4
|
+
import { AnalyticsQueryError, ApiKeySecurityMiddleware, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, NamespaceId, UnauthorizedError, ValidationError } from "./shared.js";
|
|
5
5
|
// src/effect/generated/analytics.ts
|
|
6
6
|
const AnalyticsGetChannelStatsQuery = /* @__PURE__ */ (() => Schema.Struct({
|
|
7
7
|
namespaceId: Schema.optionalKey(NamespaceId),
|
|
@@ -10,28 +10,28 @@ const AnalyticsGetChannelStatsQuery = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
10
10
|
}))();
|
|
11
11
|
const AnalyticsGetChannelStats200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
12
12
|
email: Schema.Struct({
|
|
13
|
-
sent: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
13
|
+
sent: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
14
14
|
deliveryRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
15
|
-
uniqueOpenedMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
16
|
-
openTrackingEligibleDeliveredMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
15
|
+
uniqueOpenedMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
16
|
+
openTrackingEligibleDeliveredMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
17
17
|
uniqueMessageOpenRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
18
|
-
uniqueClickedMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
19
|
-
clickTrackingEligibleDeliveredMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
18
|
+
uniqueClickedMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
19
|
+
clickTrackingEligibleDeliveredMessages: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
20
20
|
uniqueMessageClickRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
21
21
|
bounceRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" }))
|
|
22
22
|
}),
|
|
23
23
|
whatsapp: Schema.Struct({
|
|
24
|
-
sent: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
24
|
+
sent: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
25
25
|
deliveryRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
26
26
|
readRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
27
27
|
failureRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
28
28
|
avgResponseTime: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" }))
|
|
29
29
|
}),
|
|
30
30
|
sms: Schema.Struct({
|
|
31
|
-
sent: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
31
|
+
sent: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
32
32
|
deliveryRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
33
33
|
failureRate: Schema.Finite.check(Schema.isFinite().annotate({ expected: "a finite number" })),
|
|
34
|
-
totalSegments: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
34
|
+
totalSegments: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
35
35
|
})
|
|
36
36
|
}))();
|
|
37
37
|
const AnalyticsGetChannelStats400 = /* @__PURE__ */ (() => Schema.Union([AnalyticsQueryError, MalformedRequestError]))();
|
|
@@ -91,8 +91,8 @@ const AnalyticsGetHourlyDistributionQuery = /* @__PURE__ */ (() => Schema.Struct
|
|
|
91
91
|
}))();
|
|
92
92
|
const AnalyticsGetHourlyDistribution200 = /* @__PURE__ */ (() => Schema.Array(Schema.Struct({
|
|
93
93
|
hour: Schema.String,
|
|
94
|
-
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
95
|
-
weekdays: Schema.Array(Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
94
|
+
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
95
|
+
weekdays: Schema.Array(Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))).annotate({ description: "`count` split by organization-local weekday: seven entries, Monday first, summing to `count`." })
|
|
96
96
|
})))();
|
|
97
97
|
const AnalyticsGetHourlyDistribution400 = /* @__PURE__ */ (() => Schema.Union([AnalyticsQueryError, MalformedRequestError]))();
|
|
98
98
|
const AnalyticsGetHourlyDistribution401 = UnauthorizedError;
|
|
@@ -117,10 +117,10 @@ const AnalyticsGetStatsQuery = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
117
117
|
}))();
|
|
118
118
|
const AnalyticsGetStats200 = /* @__PURE__ */ (() => Schema.Struct({ volumeHistory: Schema.Array(Schema.Struct({
|
|
119
119
|
date: Schema.String,
|
|
120
|
-
email: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
121
|
-
whatsapp: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
122
|
-
sms: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
123
|
-
emailFailed: Schema.Finite.annotate({ description: "Emails in this bucket that bounced or failed. A subset of `email`." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
120
|
+
email: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
121
|
+
whatsapp: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
122
|
+
sms: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
123
|
+
emailFailed: Schema.Finite.annotate({ description: "Emails in this bucket that bounced or failed. A subset of `email`." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
124
124
|
})) }))();
|
|
125
125
|
const AnalyticsGetStats400 = /* @__PURE__ */ (() => Schema.Union([AnalyticsQueryError, MalformedRequestError]))();
|
|
126
126
|
const AnalyticsGetStats401 = UnauthorizedError;
|
|
@@ -144,7 +144,7 @@ const AnalyticsGetTopContacts200 = /* @__PURE__ */ (() => Schema.Array(Schema.St
|
|
|
144
144
|
name: Schema.Union([Schema.String, Schema.Null]),
|
|
145
145
|
email: Schema.Union([Schema.String, Schema.Null]),
|
|
146
146
|
phone: Schema.Union([Schema.String, Schema.Null]),
|
|
147
|
-
messageCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
147
|
+
messageCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
148
148
|
})))();
|
|
149
149
|
const AnalyticsGetTopContacts400 = /* @__PURE__ */ (() => Schema.Union([AnalyticsQueryError, MalformedRequestError]))();
|
|
150
150
|
const AnalyticsGetTopContacts401 = UnauthorizedError;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { SensitiveString } from "../runtime.js";
|
|
2
|
-
import { ApiKeyAccess, ApiKeyId, ApiKeySecurityMiddleware, BillingProviderError, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, NamespaceId, PaymentRequiredError, RateLimitedError, ResourceNotFoundError, SuccessResponse, UnauthorizedError, ValidationError } from "./shared.js";
|
|
3
2
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
4
3
|
import * as Schema from "effect/Schema";
|
|
4
|
+
import { ApiKeyAccess, ApiKeyId, ApiKeySecurityMiddleware, BillingProviderError, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, NamespaceId, PaymentRequiredError, RateLimitedError, ResourceNotFoundError, SuccessResponse, UnauthorizedError, ValidationError } from "./shared.js";
|
|
5
5
|
// src/effect/generated/api-keys.ts
|
|
6
6
|
const ApiKeyOwner = /* @__PURE__ */ (() => Schema.Struct({
|
|
7
7
|
id: Schema.String,
|
|
@@ -143,12 +143,12 @@ const ApiKeysGetStatsQuery = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
143
143
|
before: Schema.optionalKey(Schema.String)
|
|
144
144
|
}))();
|
|
145
145
|
const ApiKeysGetStats200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
146
|
-
totalRequests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
147
|
-
successfulRequests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
148
|
-
failedRequests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
146
|
+
totalRequests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
147
|
+
successfulRequests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
148
|
+
failedRequests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
149
149
|
dailyVolume: Schema.Array(Schema.Struct({
|
|
150
150
|
date: Schema.String,
|
|
151
|
-
requests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
151
|
+
requests: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
152
152
|
}))
|
|
153
153
|
}))();
|
|
154
154
|
const ApiKeysGetStats400 = MalformedRequestError;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ApiKeySecurityMiddleware, ConflictError, ForbiddenError, GatewayTimeoutError, InternalError, JsonObject, MalformedRequestError, NamespaceId, OrganizationId, ResourceNotFoundError, UnauthorizedError, UserId, ValidationError } from "./shared.js";
|
|
2
1
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
3
2
|
import * as Schema from "effect/Schema";
|
|
3
|
+
import { ApiKeySecurityMiddleware, ConflictError, ForbiddenError, GatewayTimeoutError, InternalError, JsonObject, MalformedRequestError, NamespaceId, OrganizationId, ResourceNotFoundError, UnauthorizedError, UserId, ValidationError } from "./shared.js";
|
|
4
4
|
// src/effect/generated/approval-requests.ts
|
|
5
5
|
const ApprovalRequestId = /* @__PURE__ */ (() => Schema.String.check(Schema.isPattern(new globalThis.RegExp("^apr_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).annotate({
|
|
6
6
|
expected: "a string matching the RegExp ^apr_[0-9a-hjkmnp-tv-z]{16,24}$",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ApiKeySecurityMiddleware, AttachmentId, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, MessageId, OrganizationId, ResourceNotFoundError, UnauthorizedError, ValidationError } from "./shared.js";
|
|
2
1
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
3
2
|
import * as Schema from "effect/Schema";
|
|
3
|
+
import { ApiKeySecurityMiddleware, AttachmentId, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, MessageId, OrganizationId, ResourceNotFoundError, UnauthorizedError, ValidationError } from "./shared.js";
|
|
4
4
|
// src/effect/generated/attachments.ts
|
|
5
5
|
const AttachmentList = /* @__PURE__ */ (() => Schema.Struct({ items: Schema.Array(Schema.Struct({
|
|
6
6
|
id: AttachmentId,
|
|
@@ -8,7 +8,7 @@ const AttachmentList = /* @__PURE__ */ (() => Schema.Struct({ items: Schema.Arra
|
|
|
8
8
|
organizationId: OrganizationId,
|
|
9
9
|
filename: Schema.String,
|
|
10
10
|
contentType: Schema.String,
|
|
11
|
-
size: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
11
|
+
size: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
12
12
|
contentId: Schema.Union([Schema.String, Schema.Null]),
|
|
13
13
|
isInline: Schema.Boolean,
|
|
14
14
|
createdAt: Schema.String
|
|
@@ -29,7 +29,7 @@ const AttachmentsGetById200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
29
29
|
organizationId: OrganizationId,
|
|
30
30
|
filename: Schema.String,
|
|
31
31
|
contentType: Schema.String,
|
|
32
|
-
size: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
32
|
+
size: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
33
33
|
contentId: Schema.Union([Schema.String, Schema.Null]),
|
|
34
34
|
isInline: Schema.Boolean,
|
|
35
35
|
createdAt: Schema.String
|
|
@@ -64,7 +64,7 @@ const AttachmentsDownloadUrl200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
64
64
|
organizationId: OrganizationId,
|
|
65
65
|
filename: Schema.String,
|
|
66
66
|
contentType: Schema.String,
|
|
67
|
-
size: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
67
|
+
size: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
68
68
|
contentId: Schema.Union([Schema.String, Schema.Null]),
|
|
69
69
|
isInline: Schema.Boolean,
|
|
70
70
|
createdAt: Schema.String
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ApiKeySecurityMiddleware, BrandAssets, BrandFooter, BrandId, ConflictError, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, NamespaceId, ResourceNotFoundError, SuccessResponse, UnauthorizedError, ValidationError } from "./shared.js";
|
|
2
1
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
3
2
|
import * as Schema from "effect/Schema";
|
|
3
|
+
import { ApiKeySecurityMiddleware, BrandAssets, BrandFooter, BrandId, ConflictError, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, NamespaceId, ResourceNotFoundError, SuccessResponse, UnauthorizedError, ValidationError } from "./shared.js";
|
|
4
4
|
// src/effect/generated/brands.ts
|
|
5
5
|
const Brand = /* @__PURE__ */ (() => Schema.Struct({
|
|
6
6
|
id: BrandId,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type * as EffectBrand from "effect/Brand";
|
|
2
2
|
import { HttpApiEndpoint, HttpApiGroup } from "effect/http-api";
|
|
3
3
|
import * as Schema from "effect/Schema";
|
|
4
|
-
import { ApiKeySecurityMiddleware, BillingProviderError, BrandAddressRequiredError, CampaignAudience, CampaignContentInput, CampaignContentMetadata, CampaignConversationRef, CampaignFooterRequiredError, CampaignId, CampaignLatestRun, CampaignReplyMailbox, CampaignRunId, ConflictError, ContactId, DeliveryUnavailableError, EmailCustomHeaders, EmailDomainId, EmailFooterOverride, EmailTrackingOverrideV1, ExternalServiceError, FlagDisabledError, ForbiddenError, FromAddressRequiredError, GatewayTimeoutError, InternalError, MalformedRequestError, MessageId, OnboardingReviewRequiredError, PaymentRequiredError, RateLimitedError, RenderLocale, RenderTimeZone, ResourceNotFoundError, SenderNotReadyError, SendsSeries, ServiceUnavailableError, SmsContent, StoredEmailAttachments, StoredReplyToAddresses, TemplateData, TemplateId, TemplateInputContractId, TemplatePublicationId, TemplateSourceError, TopicId, UnauthorizedError, ValidationError, WhatsAppTemplateDispatch, __SamvaRuntimeAbsoluteInstant } from "./shared.js";
|
|
4
|
+
import { ApiKeySecurityMiddleware, BillingProviderError, BrandAddressRequiredError, CampaignAudience, CampaignContentInput, CampaignContentMetadata, CampaignConversationRef, CampaignFooterRequiredError, CampaignId, CampaignLatestRun, CampaignReplyMailbox, CampaignRunId, ConflictError, ContactId, ContactReferenceSummary, DeliveryUnavailableError, EmailCustomHeaders, EmailDomainId, EmailFooterOverride, EmailTrackingOverrideV1, ExternalServiceError, FlagDisabledError, ForbiddenError, FromAddressRequiredError, GatewayTimeoutError, InternalError, MalformedRequestError, MessageId, OnboardingReviewRequiredError, PaymentRequiredError, RateLimitedError, RenderLocale, RenderTimeZone, ResourceNotFoundError, SenderNotReadyError, SendsSeries, ServiceUnavailableError, SmsContent, StoredEmailAttachments, StoredReplyToAddresses, TemplateData, TemplateId, TemplateInputContractId, TemplatePublicationId, TemplateSourceError, TopicId, UnauthorizedError, ValidationError, WhatsAppTemplateDispatch, __SamvaRuntimeAbsoluteInstant } from "./shared.js";
|
|
5
5
|
export type CampaignFrom = {
|
|
6
6
|
readonly email: string;
|
|
7
7
|
readonly name?: string | null;
|
|
@@ -83,6 +83,7 @@ export type CampaignRecipientPage = {
|
|
|
83
83
|
readonly id: CampaignRecipientId;
|
|
84
84
|
readonly runId: CampaignRunId;
|
|
85
85
|
readonly contactId: ContactId;
|
|
86
|
+
readonly contact: ContactReferenceSummary | null;
|
|
86
87
|
readonly status: "pending" | "dispatching" | "dispatched" | "failed" | "skipped";
|
|
87
88
|
readonly messageId: string | null;
|
|
88
89
|
readonly failureReason: string | null;
|
|
@@ -97,6 +98,11 @@ export declare const CampaignRecipientPage: Schema.Struct<{
|
|
|
97
98
|
readonly id: Schema.brand<Schema.String, "CampaignRecipientId">;
|
|
98
99
|
readonly runId: Schema.brand<Schema.String, "CampaignRunId">;
|
|
99
100
|
readonly contactId: Schema.brand<Schema.String, "ContactId">;
|
|
101
|
+
readonly contact: Schema.Union<readonly [Schema.Struct<{
|
|
102
|
+
readonly id: Schema.brand<Schema.String, "ContactId">;
|
|
103
|
+
readonly name: Schema.String;
|
|
104
|
+
readonly displayName: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
105
|
+
}>, Schema.Null]>;
|
|
100
106
|
readonly status: Schema.Union<readonly [Schema.Literal<"pending">, Schema.Literal<"dispatching">, Schema.Literal<"dispatched">, Schema.Literal<"failed">, Schema.Literal<"skipped">]>;
|
|
101
107
|
readonly messageId: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
102
108
|
readonly failureReason: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
@@ -2595,6 +2601,11 @@ export declare const CampaignsListRecipients200: Schema.Struct<{
|
|
|
2595
2601
|
readonly id: Schema.brand<Schema.String, "CampaignRecipientId">;
|
|
2596
2602
|
readonly runId: Schema.brand<Schema.String, "CampaignRunId">;
|
|
2597
2603
|
readonly contactId: Schema.brand<Schema.String, "ContactId">;
|
|
2604
|
+
readonly contact: Schema.Union<readonly [Schema.Struct<{
|
|
2605
|
+
readonly id: Schema.brand<Schema.String, "ContactId">;
|
|
2606
|
+
readonly name: Schema.String;
|
|
2607
|
+
readonly displayName: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
2608
|
+
}>, Schema.Null]>;
|
|
2598
2609
|
readonly status: Schema.Union<readonly [Schema.Literal<"pending">, Schema.Literal<"dispatching">, Schema.Literal<"dispatched">, Schema.Literal<"failed">, Schema.Literal<"skipped">]>;
|
|
2599
2610
|
readonly messageId: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
2600
2611
|
readonly failureReason: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
@@ -4546,6 +4557,11 @@ declare const CampaignsGroup_base: HttpApiGroup.HttpApiGroup<"Campaigns", HttpAp
|
|
|
4546
4557
|
readonly id: Schema.brand<Schema.String, "CampaignRecipientId">;
|
|
4547
4558
|
readonly runId: Schema.brand<Schema.String, "CampaignRunId">;
|
|
4548
4559
|
readonly contactId: Schema.brand<Schema.String, "ContactId">;
|
|
4560
|
+
readonly contact: Schema.Union<readonly [Schema.Struct<{
|
|
4561
|
+
readonly id: Schema.brand<Schema.String, "ContactId">;
|
|
4562
|
+
readonly name: Schema.String;
|
|
4563
|
+
readonly displayName: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
4564
|
+
}>, Schema.Null]>;
|
|
4549
4565
|
readonly status: Schema.Union<readonly [Schema.Literal<"pending">, Schema.Literal<"dispatching">, Schema.Literal<"dispatched">, Schema.Literal<"failed">, Schema.Literal<"skipped">]>;
|
|
4550
4566
|
readonly messageId: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
4551
4567
|
readonly failureReason: Schema.Union<readonly [Schema.String, Schema.Null]>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AbsoluteInstant } from "../runtime.js";
|
|
2
|
-
import { ApiKeySecurityMiddleware, BillingProviderError, BrandAddressRequiredError, CampaignAudience, CampaignContentInput, CampaignContentMetadata, CampaignConversationRef, CampaignFooterRequiredError, CampaignId, CampaignLatestRun, CampaignReplyMailbox, CampaignRunId, ConflictError, ContactId, DeliveryUnavailableError, EmailCustomHeaders, EmailDomainId, EmailFooterOverride, EmailTrackingOverrideV1, ExternalServiceError, FlagDisabledError, ForbiddenError, FromAddressRequiredError, GatewayTimeoutError, InternalError, MalformedRequestError, MessageId, OnboardingReviewRequiredError, PaymentRequiredError, RateLimitedError, RenderLocale, RenderTimeZone, ResourceNotFoundError, SenderNotReadyError, SendsSeries, ServiceUnavailableError, SmsContent, StoredEmailAttachments, StoredReplyToAddresses, TemplateData, TemplateId, TemplateInputContractId, TemplatePublicationId, TemplateSourceError, TopicId, UnauthorizedError, ValidationError, WhatsAppTemplateDispatch } from "./shared.js";
|
|
3
2
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
4
3
|
import * as Schema from "effect/Schema";
|
|
4
|
+
import { ApiKeySecurityMiddleware, BillingProviderError, BrandAddressRequiredError, CampaignAudience, CampaignContentInput, CampaignContentMetadata, CampaignConversationRef, CampaignFooterRequiredError, CampaignId, CampaignLatestRun, CampaignReplyMailbox, CampaignRunId, ConflictError, ContactId, ContactReferenceSummary, DeliveryUnavailableError, EmailCustomHeaders, EmailDomainId, EmailFooterOverride, EmailTrackingOverrideV1, ExternalServiceError, FlagDisabledError, ForbiddenError, FromAddressRequiredError, GatewayTimeoutError, InternalError, MalformedRequestError, MessageId, OnboardingReviewRequiredError, PaymentRequiredError, RateLimitedError, RenderLocale, RenderTimeZone, ResourceNotFoundError, SenderNotReadyError, SendsSeries, ServiceUnavailableError, SmsContent, StoredEmailAttachments, StoredReplyToAddresses, TemplateData, TemplateId, TemplateInputContractId, TemplatePublicationId, TemplateSourceError, TopicId, UnauthorizedError, ValidationError, WhatsAppTemplateDispatch } from "./shared.js";
|
|
5
5
|
// src/effect/generated/campaigns.ts
|
|
6
6
|
const CampaignFrom = /* @__PURE__ */ (() => Schema.Union([Schema.Struct({
|
|
7
7
|
email: Schema.String.check(Schema.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })),
|
|
@@ -39,8 +39,8 @@ const CampaignRecipientId = /* @__PURE__ */ (() => Schema.String.check(Schema.is
|
|
|
39
39
|
})).pipe(Schema.brand("CampaignRecipientId")))();
|
|
40
40
|
const CampaignRunReportEngagement = /* @__PURE__ */ (() => Schema.Struct({
|
|
41
41
|
measurement: Schema.Literal("directional"),
|
|
42
|
-
uniqueOpens: Schema.Finite.annotate({ description: "Directional unique recipients who opened, excluding machine events; not an exact measurement." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
43
|
-
uniqueClicks: Schema.Finite.annotate({ description: "Directional unique recipients who clicked, excluding machine events; not an exact measurement." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
42
|
+
uniqueOpens: Schema.Finite.annotate({ description: "Directional unique recipients who opened, excluding machine events; not an exact measurement." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
43
|
+
uniqueClicks: Schema.Finite.annotate({ description: "Directional unique recipients who clicked, excluding machine events; not an exact measurement." }).check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
44
44
|
}).annotate({ identifier: "CampaignRunReportEngagement" }))();
|
|
45
45
|
const CampaignRunReportSkippedReason = /* @__PURE__ */ (() => Schema.Struct({
|
|
46
46
|
reason: Schema.Union([
|
|
@@ -57,7 +57,7 @@ const CampaignRunReportSkippedReason = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
57
57
|
Schema.Literal("run_failed"),
|
|
58
58
|
Schema.Literal("missing_merge_field")
|
|
59
59
|
]),
|
|
60
|
-
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
60
|
+
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
61
61
|
}).annotate({ identifier: "CampaignRunReportSkippedReason" }))();
|
|
62
62
|
const CampaignPreview = /* @__PURE__ */ (() => Schema.Struct({
|
|
63
63
|
subject: Schema.String,
|
|
@@ -68,13 +68,14 @@ const CampaignPreview = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
68
68
|
const CampaignTestSend = /* @__PURE__ */ (() => Schema.Struct({ id: MessageId }).annotate({ identifier: "CampaignTestSend" }))();
|
|
69
69
|
const CampaignRunReportTopicUnsubscribes = /* @__PURE__ */ (() => Schema.Struct({
|
|
70
70
|
topicId: TopicId,
|
|
71
|
-
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
71
|
+
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
72
72
|
}).annotate({ identifier: "CampaignRunReportTopicUnsubscribes" }))();
|
|
73
73
|
const CampaignRecipientPage = /* @__PURE__ */ (() => Schema.Struct({
|
|
74
74
|
items: Schema.Array(Schema.Struct({
|
|
75
75
|
id: CampaignRecipientId,
|
|
76
76
|
runId: CampaignRunId,
|
|
77
77
|
contactId: ContactId,
|
|
78
|
+
contact: Schema.Union([ContactReferenceSummary, Schema.Null]),
|
|
78
79
|
status: Schema.Union([
|
|
79
80
|
Schema.Literal("pending"),
|
|
80
81
|
Schema.Literal("dispatching"),
|
|
@@ -106,17 +107,17 @@ const CampaignRecipientPage = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
106
107
|
const CampaignRunReport = /* @__PURE__ */ (() => Schema.Struct({
|
|
107
108
|
campaignId: CampaignId,
|
|
108
109
|
runId: CampaignRunId,
|
|
109
|
-
totalRecipients: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
110
|
-
dispatchedCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
111
|
-
failedCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
112
|
-
skippedCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
113
|
-
deliveredCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
114
|
-
hardBounceCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
115
|
-
softBounceCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
116
|
-
complaintCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
110
|
+
totalRecipients: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
111
|
+
dispatchedCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
112
|
+
failedCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
113
|
+
skippedCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
114
|
+
deliveredCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
115
|
+
hardBounceCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
116
|
+
softBounceCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
117
|
+
complaintCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
117
118
|
engagement: CampaignRunReportEngagement,
|
|
118
119
|
unsubscribesByTopic: Schema.Array(CampaignRunReportTopicUnsubscribes),
|
|
119
|
-
replyCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
120
|
+
replyCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
120
121
|
skippedReasons: Schema.Array(CampaignRunReportSkippedReason)
|
|
121
122
|
}).annotate({ identifier: "CampaignRunReport" }))();
|
|
122
123
|
const SmsCampaignContent = /* @__PURE__ */ (() => Schema.Struct({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ApiKeySecurityMiddleware, ContactEvent, ContactId, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, ResourceNotFoundError, UnauthorizedError, ValidationError } from "./shared.js";
|
|
2
1
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
3
2
|
import * as Schema from "effect/Schema";
|
|
3
|
+
import { ApiKeySecurityMiddleware, ContactEvent, ContactId, ForbiddenError, GatewayTimeoutError, InternalError, MalformedRequestError, ResourceNotFoundError, UnauthorizedError, ValidationError } from "./shared.js";
|
|
4
4
|
// src/effect/generated/contact-events.ts
|
|
5
5
|
const ContactEventPage = /* @__PURE__ */ (() => Schema.Struct({
|
|
6
6
|
items: Schema.Array(ContactEvent),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ApiKeySecurityMiddleware, ContactGroupId, ContactId, ContactIdentity, ForbiddenError, GatewayTimeoutError, InternalError, JsonValue, MalformedRequestError, OrganizationId, ResourceNotFoundError, UnauthorizedError, ValidationError } from "./shared.js";
|
|
2
1
|
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api";
|
|
3
2
|
import * as Schema from "effect/Schema";
|
|
3
|
+
import { ApiKeySecurityMiddleware, ContactGroupId, ContactId, ContactIdentity, ForbiddenError, GatewayTimeoutError, InternalError, JsonValue, MalformedRequestError, OrganizationId, ResourceNotFoundError, UnauthorizedError, ValidationError } from "./shared.js";
|
|
4
4
|
// src/effect/generated/contact-groups.ts
|
|
5
5
|
const ContactGroupPage = /* @__PURE__ */ (() => Schema.Struct({
|
|
6
6
|
items: Schema.Array(Schema.Struct({
|
|
@@ -24,7 +24,7 @@ const ContactGroupPage = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
24
24
|
]), Schema.Null]).annotate({ description: "The list's label color, one of six families, or null for the neutral chip. Customer-chosen and purely presentational; it carries no meaning the API enforces." }),
|
|
25
25
|
icon: Schema.Union([Schema.String, Schema.Null]),
|
|
26
26
|
parentGroupId: Schema.Union([ContactGroupId, Schema.Null]),
|
|
27
|
-
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
27
|
+
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
28
28
|
lastCalculatedAt: Schema.Union([Schema.String, Schema.Null]),
|
|
29
29
|
isActive: Schema.Boolean,
|
|
30
30
|
createdAt: Schema.String,
|
|
@@ -119,7 +119,7 @@ const ContactGroupsCreate201 = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
119
119
|
]), Schema.Null]).annotate({ description: "The list's label color, one of six families, or null for the neutral chip. Customer-chosen and purely presentational; it carries no meaning the API enforces." }),
|
|
120
120
|
icon: Schema.Union([Schema.String, Schema.Null]),
|
|
121
121
|
parentGroupId: Schema.Union([ContactGroupId, Schema.Null]),
|
|
122
|
-
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
122
|
+
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
123
123
|
lastCalculatedAt: Schema.Union([Schema.String, Schema.Null]),
|
|
124
124
|
isActive: Schema.Boolean,
|
|
125
125
|
createdAt: Schema.String,
|
|
@@ -153,7 +153,7 @@ const ContactGroupsGetById200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
153
153
|
]), Schema.Null]).annotate({ description: "The list's label color, one of six families, or null for the neutral chip. Customer-chosen and purely presentational; it carries no meaning the API enforces." }),
|
|
154
154
|
icon: Schema.Union([Schema.String, Schema.Null]),
|
|
155
155
|
parentGroupId: Schema.Union([ContactGroupId, Schema.Null]),
|
|
156
|
-
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
156
|
+
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
157
157
|
lastCalculatedAt: Schema.Union([Schema.String, Schema.Null]),
|
|
158
158
|
isActive: Schema.Boolean,
|
|
159
159
|
createdAt: Schema.String,
|
|
@@ -218,7 +218,7 @@ const ContactGroupsUpdate200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
|
218
218
|
]), Schema.Null]).annotate({ description: "The list's label color, one of six families, or null for the neutral chip. Customer-chosen and purely presentational; it carries no meaning the API enforces." }),
|
|
219
219
|
icon: Schema.Union([Schema.String, Schema.Null]),
|
|
220
220
|
parentGroupId: Schema.Union([ContactGroupId, Schema.Null]),
|
|
221
|
-
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
221
|
+
contactCount: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
222
222
|
lastCalculatedAt: Schema.Union([Schema.String, Schema.Null]),
|
|
223
223
|
isActive: Schema.Boolean,
|
|
224
224
|
createdAt: Schema.String,
|
|
@@ -233,9 +233,9 @@ const ContactGroupsUpdate500 = InternalError;
|
|
|
233
233
|
const ContactGroupsUpdate504 = GatewayTimeoutError;
|
|
234
234
|
const ContactGroupsEvaluateDynamicPathParams = /* @__PURE__ */ (() => Schema.Struct({ id: ContactGroupId }))();
|
|
235
235
|
const ContactGroupsEvaluateDynamic200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
236
|
-
added: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
237
|
-
removed: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
238
|
-
total: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
236
|
+
added: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
237
|
+
removed: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
238
|
+
total: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
239
239
|
}))();
|
|
240
240
|
const ContactGroupsEvaluateDynamic400 = MalformedRequestError;
|
|
241
241
|
const ContactGroupsEvaluateDynamic401 = UnauthorizedError;
|
|
@@ -267,8 +267,8 @@ const ContactGroupsAddMembersRequestJson = /* @__PURE__ */ (() => Schema.Struct(
|
|
|
267
267
|
]), Schema.Null]))
|
|
268
268
|
}))();
|
|
269
269
|
const ContactGroupsAddMembers200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
270
|
-
added: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
271
|
-
skipped: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
270
|
+
added: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
271
|
+
skipped: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" }))
|
|
272
272
|
}))();
|
|
273
273
|
const ContactGroupsAddMembers400 = MalformedRequestError;
|
|
274
274
|
const ContactGroupsAddMembers401 = UnauthorizedError;
|
|
@@ -279,7 +279,7 @@ const ContactGroupsAddMembers500 = InternalError;
|
|
|
279
279
|
const ContactGroupsAddMembers504 = GatewayTimeoutError;
|
|
280
280
|
const ContactGroupsRemoveMembersPathParams = /* @__PURE__ */ (() => Schema.Struct({ id: ContactGroupId }))();
|
|
281
281
|
const ContactGroupsRemoveMembersRequestJson = /* @__PURE__ */ (() => Schema.Struct({ contactIds: Schema.TupleWithRest(Schema.Tuple([ContactId]), [ContactId]).check(Schema.isMaxLength(1e3).annotate({ expected: "a value with a length of at most 1000" })) }))();
|
|
282
|
-
const ContactGroupsRemoveMembers200 = /* @__PURE__ */ (() => Schema.Struct({ removed: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
282
|
+
const ContactGroupsRemoveMembers200 = /* @__PURE__ */ (() => Schema.Struct({ removed: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })) }))();
|
|
283
283
|
const ContactGroupsRemoveMembers400 = MalformedRequestError;
|
|
284
284
|
const ContactGroupsRemoveMembers401 = UnauthorizedError;
|
|
285
285
|
const ContactGroupsRemoveMembers403 = ForbiddenError;
|
|
@@ -298,7 +298,7 @@ const ContactGroupsPreviewRequestJson = /* @__PURE__ */ (() => Schema.Struct({ c
|
|
|
298
298
|
})), Schema.Null]))
|
|
299
299
|
}) }))();
|
|
300
300
|
const ContactGroupsPreview200 = /* @__PURE__ */ (() => Schema.Struct({
|
|
301
|
-
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(
|
|
301
|
+
count: Schema.Finite.check(Schema.isInt().annotate({ expected: "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema.isLessThanOrEqualTo(0x1fffffffffffff).annotate({ expected: "a value less than or equal to 9007199254740991" })),
|
|
302
302
|
sample: Schema.Array(Schema.Struct({
|
|
303
303
|
id: ContactId,
|
|
304
304
|
name: Schema.String,
|