samva 0.15.0 → 0.16.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/{categories-BGUBFdH9.js → categories-DV51kr2H.js} +5 -1
- package/dist/client/sdk.gen.d.ts +61 -47
- package/dist/client/types.gen.d.ts +265 -207
- package/dist/{client-CDg7zJs0.js → client-BMUew5Wp.js} +300 -232
- package/dist/effect/analytics.js +1 -1
- package/dist/effect/api-keys.d.ts +1 -0
- package/dist/effect/api-keys.js +5 -2
- package/dist/effect/attachments.js +1 -1
- package/dist/effect/brands.js +2 -2
- package/dist/effect/campaigns.js +1 -1
- package/dist/effect/categories.js +1 -1
- package/dist/effect/client.js +1 -1
- 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/email.d.ts +0 -18
- package/dist/effect/email.js +3 -7
- package/dist/effect/extension-installations.js +1 -1
- package/dist/effect/extensions.js +1 -1
- package/dist/effect/feedback.js +2 -2
- package/dist/effect/generated-metadata.d.ts +4 -0
- package/dist/effect/generated.d.ts +1586 -1641
- package/dist/effect/index.d.ts +2 -1
- package/dist/effect/index.js +6 -5
- package/dist/effect/mailboxes.d.ts +144 -94
- package/dist/effect/mailboxes.js +2 -2
- package/dist/effect/media.js +1 -1
- package/dist/effect/messages.js +1 -1
- package/dist/effect/namespaces.js +1 -1
- package/dist/effect/operations.js +1 -1
- package/dist/effect/organizations.js +1 -1
- package/dist/effect/retry.js +1 -1
- package/dist/effect/scheduled-messages.js +1 -1
- package/dist/effect/subscriptions.js +1 -1
- package/dist/effect/templates.js +2 -2
- package/dist/effect/unsubscribe-groups.js +1 -1
- package/dist/effect/webhooks.js +2 -2
- package/dist/effect/whoami.d.ts +46 -0
- package/dist/effect/whoami.js +9 -0
- package/dist/index.js +3 -3
- package/dist/{inline-attachments-UxLeyytJ.js → inline-attachments-Cegg6tTF.js} +2 -2
- package/dist/{mailboxes-BH_JPmOE.js → mailboxes-Thp5z0oX.js} +10 -8
- package/dist/{operation-BZ5Xov-x.js → operation-BTXjPrwf.js} +13 -15
- package/dist/promises/errors.gen.d.ts +12 -2
- package/dist/promises/index.d.ts +3 -1
- package/dist/promises/index.js +3 -3
- package/dist/promises/types.gen.d.ts +1 -1
- package/dist/{promises-Cd6Jamqk.js → promises-KrA2nSLg.js} +174 -88
- package/dist/service-map.d.ts +16 -15
- package/package.json +6 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as uploadContentType, o as CLIENT_ATTRIBUTION_HEADER, s as clientAttribution, t as MediaUploadError } from "./inline-attachments-
|
|
1
|
+
import { i as uploadContentType, o as CLIENT_ATTRIBUTION_HEADER, s as clientAttribution, t as MediaUploadError } from "./inline-attachments-Cegg6tTF.js";
|
|
2
2
|
import { Context, Effect, Layer, Redacted, Schema, SchemaTransformation } from "effect";
|
|
3
3
|
import { HttpApi, HttpApiClient, HttpApiEndpoint, HttpApiGroup, HttpApiMiddleware, HttpApiSchema, HttpApiSecurity, OpenApi } from "effect/http-api";
|
|
4
4
|
import * as Schema$1 from "effect/Schema";
|
|
@@ -308,10 +308,6 @@ const WebhookEndpointId = Schema$1.String.check(Schema$1.isPattern(/* @__PURE__
|
|
|
308
308
|
expected: "a string matching the RegExp ^wep_[0-9a-hjkmnp-tv-z]{16,24}$",
|
|
309
309
|
identifier: "WebhookEndpointId"
|
|
310
310
|
})).pipe(Schema$1.brand("WebhookEndpointId"));
|
|
311
|
-
const EmailSenderId = Schema$1.String.check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^sender_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).annotate({
|
|
312
|
-
expected: "a string matching the RegExp ^sender_[0-9a-hjkmnp-tv-z]{16,24}$",
|
|
313
|
-
identifier: "EmailSenderId"
|
|
314
|
-
})).pipe(Schema$1.brand("EmailSenderId"));
|
|
315
311
|
const DeliverabilityFacts = Schema$1.Struct({
|
|
316
312
|
bounceRate: Schema$1.Finite.check(Schema$1.isFinite().annotate({ expected: "a finite number" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema$1.isLessThanOrEqualTo(1).annotate({ expected: "a value less than or equal to 1" })),
|
|
317
313
|
complaintRate: Schema$1.Finite.check(Schema$1.isFinite().annotate({ expected: "a finite number" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema$1.isLessThanOrEqualTo(1).annotate({ expected: "a value less than or equal to 1" })),
|
|
@@ -464,6 +460,10 @@ const IdentityClearanceStatus = Schema$1.Struct({
|
|
|
464
460
|
]), Schema$1.Null]),
|
|
465
461
|
updatedAt: Schema$1.String
|
|
466
462
|
}).annotate({ identifier: "IdentityClearanceStatus" });
|
|
463
|
+
const EmailSenderId = Schema$1.String.check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^sender_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).annotate({
|
|
464
|
+
expected: "a string matching the RegExp ^sender_[0-9a-hjkmnp-tv-z]{16,24}$",
|
|
465
|
+
identifier: "EmailSenderId"
|
|
466
|
+
})).pipe(Schema$1.brand("EmailSenderId"));
|
|
467
467
|
const SuppressionId = Schema$1.String.check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^supp_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).annotate({
|
|
468
468
|
expected: "a string matching the RegExp ^supp_[0-9a-hjkmnp-tv-z]{16,24}$",
|
|
469
469
|
identifier: "SuppressionId"
|
|
@@ -584,18 +584,22 @@ const FeedbackId = Schema$1.String.check(Schema$1.isPattern(/* @__PURE__ */ new
|
|
|
584
584
|
identifier: "FeedbackId"
|
|
585
585
|
})).pipe(Schema$1.brand("FeedbackId"));
|
|
586
586
|
const MailboxStatus = Schema$1.Union([Schema$1.Literal("active"), Schema$1.Literal("paused")]).annotate({ identifier: "MailboxStatus" });
|
|
587
|
+
const MailboxChannel = Schema$1.Literal("email").annotate({
|
|
588
|
+
description: "The channel an endpoint, thread, or message belongs to.",
|
|
589
|
+
identifier: "MailboxChannel"
|
|
590
|
+
});
|
|
587
591
|
const MailboxMetadata = Schema$1.Record(Schema$1.String, Schema$1.String.check(Schema$1.isMaxCodePoints(512).annotate({ expected: "a string with at most 512 code points" })).check(Schema$1.isMaxLength(512).annotate({ expected: "a value with a length of at most 512" }))).check(Schema$1.isPropertyNames(Schema$1.String.check(Schema$1.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })).check(Schema$1.isMaxCodePoints(64).annotate({ expected: "a string with at most 64 code points" }))).annotate({
|
|
588
592
|
expected: "an object with property names matching the schema",
|
|
589
593
|
identifier: "MailboxMetadata"
|
|
590
594
|
}));
|
|
591
|
-
const
|
|
592
|
-
expected: "a string matching the RegExp ^
|
|
593
|
-
identifier: "
|
|
594
|
-
})).pipe(Schema$1.brand("
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
})
|
|
595
|
+
const MailboxEndpointId = Schema$1.String.check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^mbxep_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).annotate({
|
|
596
|
+
expected: "a string matching the RegExp ^mbxep_[0-9a-hjkmnp-tv-z]{16,24}$",
|
|
597
|
+
identifier: "MailboxEndpointId"
|
|
598
|
+
})).pipe(Schema$1.brand("MailboxEndpointId"));
|
|
599
|
+
var MailboxChannelUnsupportedError = class extends Schema$1.TaggedError()("MailboxChannelUnsupportedError", Schema$1.Struct({
|
|
600
|
+
message: Schema$1.String,
|
|
601
|
+
channel: Schema$1.String
|
|
602
|
+
})) {};
|
|
599
603
|
const MailboxMetadataPatch = Schema$1.Record(Schema$1.String, Schema$1.Union([Schema$1.String.check(Schema$1.isMaxCodePoints(512).annotate({ expected: "a string with at most 512 code points" })).check(Schema$1.isMaxLength(512).annotate({ expected: "a value with a length of at most 512" })), Schema$1.Null])).check(Schema$1.isPropertyNames(Schema$1.String.check(Schema$1.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })).check(Schema$1.isMaxCodePoints(64).annotate({ expected: "a string with at most 64 code points" }))).annotate({
|
|
600
604
|
expected: "an object with property names matching the schema",
|
|
601
605
|
identifier: "MailboxMetadataPatch"
|
|
@@ -754,11 +758,11 @@ const MailboxAgentActivity = Schema$1.Struct({
|
|
|
754
758
|
events: Schema$1.Struct({ byType: Schema$1.Array(Schema$1.Struct({
|
|
755
759
|
type: Schema$1.Union([
|
|
756
760
|
Schema$1.Literal("mailbox.created"),
|
|
757
|
-
Schema$1.Literal("
|
|
758
|
-
Schema$1.Literal("
|
|
759
|
-
Schema$1.Literal("
|
|
760
|
-
Schema$1.Literal("
|
|
761
|
-
Schema$1.Literal("
|
|
761
|
+
Schema$1.Literal("endpoint.attached"),
|
|
762
|
+
Schema$1.Literal("endpoint.detached"),
|
|
763
|
+
Schema$1.Literal("message.received"),
|
|
764
|
+
Schema$1.Literal("message.released"),
|
|
765
|
+
Schema$1.Literal("message.sent"),
|
|
762
766
|
Schema$1.Literal("thread.created"),
|
|
763
767
|
Schema$1.Literal("action.proposed"),
|
|
764
768
|
Schema$1.Literal("action.policy_decided"),
|
|
@@ -1068,6 +1072,11 @@ const WebhookDailyDeliveries = Schema$1.Struct({
|
|
|
1068
1072
|
exhausted: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })),
|
|
1069
1073
|
cancelled: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" }))
|
|
1070
1074
|
}).annotate({ identifier: "WebhookDailyDeliveries" });
|
|
1075
|
+
const WhoamiUser = Schema$1.Struct({
|
|
1076
|
+
id: Schema$1.String,
|
|
1077
|
+
name: Schema$1.String,
|
|
1078
|
+
email: Schema$1.String
|
|
1079
|
+
}).annotate({ identifier: "WhoamiUser" });
|
|
1071
1080
|
Schema$1.Struct({
|
|
1072
1081
|
entryPath: Schema$1.String.check(Schema$1.isMaxCodePoints(1024).annotate({ expected: "a string with at most 1024 code points" })).check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^(?!\\/)(?!.*\\\\)(?!.*(?:^|\\/)\\.{1,2}(?:\\/|$))(?!.*(?:^|\\/)\\.git(?:\\/|$))(?:templates|emails)\\/.+\\.tsx$", "u")).annotate({ expected: "a string matching the RegExp ^(?!\\/)(?!.*\\\\)(?!.*(?:^|\\/)\\.{1,2}(?:\\/|$))(?!.*(?:^|\\/)\\.git(?:\\/|$))(?:templates|emails)\\/.+\\.tsx$" })).check(Schema$1.isMaxLength(1024).annotate({ expected: "a value with a length of at most 1024" })),
|
|
1073
1082
|
name: Schema$1.String.check(Schema$1.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })).check(Schema$1.isMaxCodePoints(200).annotate({ expected: "a string with at most 200 code points" })).check(Schema$1.isMaxLength(200).annotate({ expected: "a value with a length of at most 200" })),
|
|
@@ -1097,10 +1106,6 @@ Schema$1.Struct({
|
|
|
1097
1106
|
dailyGrowthPercent: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })).check(Schema$1.isLessThanOrEqualTo(1e4).annotate({ expected: "a value less than or equal to 10000" })),
|
|
1098
1107
|
targetDailyRecipients: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isLessThanOrEqualTo(1e6).annotate({ expected: "a value less than or equal to 1000000" })).check(Schema$1.isGreaterThan(0).annotate({ expected: "a value greater than 0" }))
|
|
1099
1108
|
}).annotate({ identifier: "CreateDomainWarmingPlanPayload" });
|
|
1100
|
-
Schema$1.Struct({
|
|
1101
|
-
address: Schema$1.String,
|
|
1102
|
-
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null]))
|
|
1103
|
-
}).annotate({ identifier: "CreateMailboxAddressPayload" });
|
|
1104
1109
|
Schema$1.Struct({
|
|
1105
1110
|
slug: Schema$1.String,
|
|
1106
1111
|
displayName: Schema$1.String,
|
|
@@ -1182,6 +1187,10 @@ Schema$1.Struct({
|
|
|
1182
1187
|
targetDailyRecipients: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isLessThanOrEqualTo(1e6).annotate({ expected: "a value less than or equal to 1000000" })).check(Schema$1.isGreaterThan(0).annotate({ expected: "a value greater than 0" })),
|
|
1183
1188
|
note: Schema$1.optionalKey(Schema$1.Union([Schema$1.String.check(Schema$1.isMaxCodePoints(500).annotate({ expected: "a string with at most 500 code points" })).check(Schema$1.isMaxLength(500).annotate({ expected: "a value with a length of at most 500" })), Schema$1.Null]))
|
|
1184
1189
|
}).annotate({ identifier: "UpdateDomainWarmingPolicyPayload" });
|
|
1190
|
+
Schema$1.Struct({
|
|
1191
|
+
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([Schema$1.String, Schema$1.Null]), Schema$1.Null])),
|
|
1192
|
+
default: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal(true), Schema$1.Null]))
|
|
1193
|
+
}).annotate({ identifier: "UpdateMailboxEndpointPayload" });
|
|
1185
1194
|
Schema$1.Struct({
|
|
1186
1195
|
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
1187
1196
|
color: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([Schema$1.Union([
|
|
@@ -1375,6 +1384,11 @@ const AttachmentList = Schema$1.Struct({ items: Schema$1.Array(Schema$1.Struct({
|
|
|
1375
1384
|
isInline: Schema$1.Boolean,
|
|
1376
1385
|
createdAt: Schema$1.String
|
|
1377
1386
|
})) }).annotate({ identifier: "AttachmentList" });
|
|
1387
|
+
const WhoamiOrganization = Schema$1.Struct({
|
|
1388
|
+
id: OrganizationId,
|
|
1389
|
+
slug: Schema$1.String,
|
|
1390
|
+
name: Schema$1.String
|
|
1391
|
+
}).annotate({ identifier: "WhoamiOrganization" });
|
|
1378
1392
|
const BrandFooter = Schema$1.Struct({
|
|
1379
1393
|
companyName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String.check(Schema$1.isMaxCodePoints(255).annotate({ expected: "a string with at most 255 code points" })).check(Schema$1.isMaxLength(255).annotate({ expected: "a value with a length of at most 255" })), Schema$1.Null])),
|
|
1380
1394
|
address: Schema$1.optionalKey(Schema$1.Union([BrandAddress, Schema$1.Null])),
|
|
@@ -1939,7 +1953,6 @@ const EmailDomainPage = Schema$1.Struct({
|
|
|
1939
1953
|
dkimSelector: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
1940
1954
|
dkimPublicKey: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
1941
1955
|
isDefault: Schema$1.Boolean,
|
|
1942
|
-
defaultSenderId: Schema$1.Union([EmailSenderId, Schema$1.Null]),
|
|
1943
1956
|
deliverability: DeliverabilityFacts,
|
|
1944
1957
|
series: SendsSeries,
|
|
1945
1958
|
createdAt: Schema$1.String,
|
|
@@ -1981,42 +1994,10 @@ const EmailDomainDetailed = Schema$1.Struct({
|
|
|
1981
1994
|
})),
|
|
1982
1995
|
verifiedAt: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
1983
1996
|
isDefault: Schema$1.Boolean,
|
|
1984
|
-
defaultSenderId: Schema$1.Union([EmailSenderId, Schema$1.Null]),
|
|
1985
1997
|
deliverability: DeliverabilityFacts,
|
|
1986
1998
|
createdAt: Schema$1.String,
|
|
1987
1999
|
updatedAt: Schema$1.String
|
|
1988
2000
|
}).annotate({ identifier: "EmailDomainDetailed" });
|
|
1989
|
-
const EmailSenderPage = Schema$1.Struct({
|
|
1990
|
-
items: Schema$1.Array(Schema$1.Struct({
|
|
1991
|
-
id: EmailSenderId,
|
|
1992
|
-
organizationId: Schema$1.String,
|
|
1993
|
-
email: Schema$1.String,
|
|
1994
|
-
name: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
1995
|
-
domainId: Schema$1.Union([EmailDomainId, Schema$1.Null]),
|
|
1996
|
-
verificationStatus: Schema$1.Union([
|
|
1997
|
-
Schema$1.Literal("pending"),
|
|
1998
|
-
Schema$1.Literal("verified"),
|
|
1999
|
-
Schema$1.Literal("failed")
|
|
2000
|
-
]),
|
|
2001
|
-
verifiedAt: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2002
|
-
verificationToken: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2003
|
-
providerLifecycle: Schema$1.Union([
|
|
2004
|
-
Schema$1.Literal("provisioning"),
|
|
2005
|
-
Schema$1.Literal("active"),
|
|
2006
|
-
Schema$1.Literal("deleting"),
|
|
2007
|
-
Schema$1.Literal("failed")
|
|
2008
|
-
]),
|
|
2009
|
-
providerFailureCode: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2010
|
-
isDefault: Schema$1.Boolean,
|
|
2011
|
-
replyToEmails: Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null]),
|
|
2012
|
-
deliverability: DeliverabilityFacts,
|
|
2013
|
-
series: SendsSeries,
|
|
2014
|
-
isActive: Schema$1.Boolean,
|
|
2015
|
-
createdAt: Schema$1.String,
|
|
2016
|
-
updatedAt: Schema$1.String
|
|
2017
|
-
})),
|
|
2018
|
-
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
2019
|
-
}).annotate({ identifier: "EmailSenderPage" });
|
|
2020
2001
|
const CustomTrackingStatus = Schema$1.Struct({
|
|
2021
2002
|
enabled: Schema$1.Boolean,
|
|
2022
2003
|
customTracking: Schema$1.Union([Schema$1.Struct({
|
|
@@ -2197,6 +2178,37 @@ const OnboardingReviewStatus = Schema$1.Struct({
|
|
|
2197
2178
|
identities: Schema$1.Array(IdentityClearanceStatus),
|
|
2198
2179
|
updatedAt: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
2199
2180
|
}).annotate({ identifier: "OnboardingReviewStatus" });
|
|
2181
|
+
const EmailSenderPage = Schema$1.Struct({
|
|
2182
|
+
items: Schema$1.Array(Schema$1.Struct({
|
|
2183
|
+
id: EmailSenderId,
|
|
2184
|
+
organizationId: Schema$1.String,
|
|
2185
|
+
email: Schema$1.String,
|
|
2186
|
+
name: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2187
|
+
domainId: Schema$1.Union([EmailDomainId, Schema$1.Null]),
|
|
2188
|
+
verificationStatus: Schema$1.Union([
|
|
2189
|
+
Schema$1.Literal("pending"),
|
|
2190
|
+
Schema$1.Literal("verified"),
|
|
2191
|
+
Schema$1.Literal("failed")
|
|
2192
|
+
]),
|
|
2193
|
+
verifiedAt: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2194
|
+
verificationToken: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2195
|
+
providerLifecycle: Schema$1.Union([
|
|
2196
|
+
Schema$1.Literal("provisioning"),
|
|
2197
|
+
Schema$1.Literal("active"),
|
|
2198
|
+
Schema$1.Literal("deleting"),
|
|
2199
|
+
Schema$1.Literal("failed")
|
|
2200
|
+
]),
|
|
2201
|
+
providerFailureCode: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2202
|
+
isDefault: Schema$1.Boolean,
|
|
2203
|
+
replyToEmails: Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null]),
|
|
2204
|
+
deliverability: DeliverabilityFacts,
|
|
2205
|
+
series: SendsSeries,
|
|
2206
|
+
isActive: Schema$1.Boolean,
|
|
2207
|
+
createdAt: Schema$1.String,
|
|
2208
|
+
updatedAt: Schema$1.String
|
|
2209
|
+
})),
|
|
2210
|
+
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
2211
|
+
}).annotate({ identifier: "EmailSenderPage" });
|
|
2200
2212
|
const SuppressionEntry = Schema$1.Struct({
|
|
2201
2213
|
id: SuppressionId,
|
|
2202
2214
|
email: Schema$1.String,
|
|
@@ -2300,27 +2312,23 @@ const MailboxSummary = Schema$1.Struct({
|
|
|
2300
2312
|
primaryAddress: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2301
2313
|
createdAt: Schema$1.String
|
|
2302
2314
|
}).annotate({ identifier: "MailboxSummary" });
|
|
2303
|
-
Schema$1.Struct({
|
|
2304
|
-
|
|
2315
|
+
const CreateMailboxEndpointPayload = Schema$1.Struct({
|
|
2316
|
+
channel: MailboxChannel,
|
|
2305
2317
|
address: Schema$1.String,
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
const MailboxAddress = Schema$1.Struct({
|
|
2311
|
-
id: MailboxAddressId,
|
|
2318
|
+
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null]))
|
|
2319
|
+
}).annotate({ identifier: "CreateMailboxEndpointPayload" });
|
|
2320
|
+
const MailboxEndpoint = Schema$1.Struct({
|
|
2321
|
+
id: MailboxEndpointId,
|
|
2312
2322
|
address: Schema$1.String,
|
|
2323
|
+
displayName: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2324
|
+
default: Schema$1.Boolean,
|
|
2325
|
+
channel: Schema$1.Literal("email"),
|
|
2313
2326
|
source: Schema$1.Union([Schema$1.Literal("samvaHosted"), Schema$1.Literal("verifiedDomain")]),
|
|
2314
|
-
domainId: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
2315
|
-
|
|
2316
|
-
}).annotate({ identifier: "MailboxAddress" });
|
|
2327
|
+
domainId: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
2328
|
+
}).annotate({ identifier: "MailboxEndpoint" });
|
|
2317
2329
|
Schema$1.Struct({
|
|
2318
2330
|
name: Schema$1.optionalKey(Schema$1.Union([Schema$1.String.check(Schema$1.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })), Schema$1.Null])),
|
|
2319
|
-
metadata: Schema$1.optionalKey(Schema$1.Union([MailboxMetadataPatch, Schema$1.Null]))
|
|
2320
|
-
defaultFrom: Schema$1.optionalKey(Schema$1.Union([Schema$1.Struct({
|
|
2321
|
-
address: Schema$1.String,
|
|
2322
|
-
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([Schema$1.String, Schema$1.Null]), Schema$1.Null]))
|
|
2323
|
-
}), Schema$1.Null]))
|
|
2331
|
+
metadata: Schema$1.optionalKey(Schema$1.Union([MailboxMetadataPatch, Schema$1.Null]))
|
|
2324
2332
|
}).annotate({ identifier: "UpdateMailboxPayload" });
|
|
2325
2333
|
const MailboxQuarantinedMessage = Schema$1.Struct({
|
|
2326
2334
|
id: MessageId,
|
|
@@ -2368,6 +2376,7 @@ const MailboxSendOutcome = Schema$1.Struct({
|
|
|
2368
2376
|
}).annotate({ identifier: "MailboxSendOutcome" });
|
|
2369
2377
|
const MailboxDraftSummary = Schema$1.Struct({
|
|
2370
2378
|
id: MailboxDraftId,
|
|
2379
|
+
channel: MailboxChannel,
|
|
2371
2380
|
threadId: Schema$1.Union([MailboxThreadId, Schema$1.Null]),
|
|
2372
2381
|
inReplyToMessageId: Schema$1.Union([MessageId, Schema$1.Null]),
|
|
2373
2382
|
state: MailboxDraftState,
|
|
@@ -2381,11 +2390,11 @@ const MailboxEvent = Schema$1.Struct({
|
|
|
2381
2390
|
id: MailboxEventId,
|
|
2382
2391
|
type: Schema$1.Union([
|
|
2383
2392
|
Schema$1.Literal("mailbox.created"),
|
|
2384
|
-
Schema$1.Literal("
|
|
2385
|
-
Schema$1.Literal("
|
|
2386
|
-
Schema$1.Literal("
|
|
2387
|
-
Schema$1.Literal("
|
|
2388
|
-
Schema$1.Literal("
|
|
2393
|
+
Schema$1.Literal("endpoint.attached"),
|
|
2394
|
+
Schema$1.Literal("endpoint.detached"),
|
|
2395
|
+
Schema$1.Literal("message.received"),
|
|
2396
|
+
Schema$1.Literal("message.released"),
|
|
2397
|
+
Schema$1.Literal("message.sent"),
|
|
2389
2398
|
Schema$1.Literal("thread.created"),
|
|
2390
2399
|
Schema$1.Literal("action.proposed"),
|
|
2391
2400
|
Schema$1.Literal("action.policy_decided"),
|
|
@@ -2475,6 +2484,7 @@ const MailboxLabel = Schema$1.Struct({
|
|
|
2475
2484
|
Schema$1.Struct({ labels: Schema$1.TupleWithRest(Schema$1.Tuple([MailboxLabelId]), [MailboxLabelId]) }).annotate({ identifier: "MailboxThreadLabels" });
|
|
2476
2485
|
const MailboxMessageSummary = Schema$1.Struct({
|
|
2477
2486
|
id: MessageId,
|
|
2487
|
+
channel: MailboxChannel,
|
|
2478
2488
|
direction: Schema$1.Union([Schema$1.Literal("inbound"), Schema$1.Literal("outbound")]),
|
|
2479
2489
|
from: MailboxMessageSender,
|
|
2480
2490
|
to: Schema$1.Array(Schema$1.String),
|
|
@@ -2489,6 +2499,20 @@ const MailboxMessage = Schema$1.Struct({
|
|
|
2489
2499
|
conversationId: ConversationId,
|
|
2490
2500
|
direction: Schema$1.Union([Schema$1.Literal("inbound"), Schema$1.Literal("outbound")]),
|
|
2491
2501
|
from: MailboxMessageSender,
|
|
2502
|
+
sentBy: Schema$1.optionalKey(Schema$1.Union([Schema$1.Struct({
|
|
2503
|
+
kind: Schema$1.Union([
|
|
2504
|
+
Schema$1.Literal("user"),
|
|
2505
|
+
Schema$1.Literal("apiKey"),
|
|
2506
|
+
Schema$1.Literal("extension"),
|
|
2507
|
+
Schema$1.Literal("externalAgent"),
|
|
2508
|
+
Schema$1.Literal("samvaAgent"),
|
|
2509
|
+
Schema$1.Literal("system")
|
|
2510
|
+
]),
|
|
2511
|
+
id: Schema$1.String,
|
|
2512
|
+
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null]))
|
|
2513
|
+
}), Schema$1.Null])),
|
|
2514
|
+
occurredAt: Schema$1.String,
|
|
2515
|
+
channel: Schema$1.Literal("email"),
|
|
2492
2516
|
recipients: Schema$1.Array(MailboxMessageRecipient),
|
|
2493
2517
|
replyTo: Schema$1.Array(Schema$1.String),
|
|
2494
2518
|
subject: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
@@ -2507,20 +2531,7 @@ const MailboxMessage = Schema$1.Struct({
|
|
|
2507
2531
|
contentType: Schema$1.String,
|
|
2508
2532
|
size: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })),
|
|
2509
2533
|
isInline: Schema$1.Boolean
|
|
2510
|
-
}))
|
|
2511
|
-
sentBy: Schema$1.optionalKey(Schema$1.Union([Schema$1.Struct({
|
|
2512
|
-
kind: Schema$1.Union([
|
|
2513
|
-
Schema$1.Literal("user"),
|
|
2514
|
-
Schema$1.Literal("apiKey"),
|
|
2515
|
-
Schema$1.Literal("extension"),
|
|
2516
|
-
Schema$1.Literal("externalAgent"),
|
|
2517
|
-
Schema$1.Literal("samvaAgent"),
|
|
2518
|
-
Schema$1.Literal("system")
|
|
2519
|
-
]),
|
|
2520
|
-
id: Schema$1.String,
|
|
2521
|
-
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null]))
|
|
2522
|
-
}), Schema$1.Null])),
|
|
2523
|
-
occurredAt: Schema$1.String
|
|
2534
|
+
}))
|
|
2524
2535
|
}).annotate({ identifier: "MailboxMessage" });
|
|
2525
2536
|
const MailboxPolicy = Schema$1.Struct({
|
|
2526
2537
|
id: MailboxPolicyId,
|
|
@@ -2545,6 +2556,8 @@ Schema$1.Struct({
|
|
|
2545
2556
|
}).annotate({ identifier: "UpdateMailboxPolicyPayload" });
|
|
2546
2557
|
const MailboxThreadSummary = Schema$1.Struct({
|
|
2547
2558
|
id: MailboxThreadId,
|
|
2559
|
+
channel: MailboxChannel,
|
|
2560
|
+
endpointId: Schema$1.Union([MailboxEndpointId, Schema$1.Null]),
|
|
2548
2561
|
subject: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2549
2562
|
preview: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2550
2563
|
from: Schema$1.Union([MailboxThreadSender, Schema$1.Null]),
|
|
@@ -2577,6 +2590,8 @@ Schema$1.Struct({
|
|
|
2577
2590
|
}).annotate({ identifier: "UpdateMailboxThreadPayload" });
|
|
2578
2591
|
const MailboxThread = Schema$1.Struct({
|
|
2579
2592
|
id: MailboxThreadId,
|
|
2593
|
+
channel: MailboxChannel,
|
|
2594
|
+
endpointId: Schema$1.Union([MailboxEndpointId, Schema$1.Null]),
|
|
2580
2595
|
subject: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2581
2596
|
preview: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
2582
2597
|
from: Schema$1.Union([MailboxThreadSender, Schema$1.Null]),
|
|
@@ -2940,6 +2955,15 @@ const WebhookStatsResponse = Schema$1.Struct({
|
|
|
2940
2955
|
cancelled: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isGreaterThanOrEqualTo(0).annotate({ expected: "a value greater than or equal to 0" })),
|
|
2941
2956
|
daily: Schema$1.Array(WebhookDailyDeliveries)
|
|
2942
2957
|
}).annotate({ identifier: "WebhookStatsResponse" });
|
|
2958
|
+
const WhoamiUserCredential = Schema$1.Struct({
|
|
2959
|
+
type: Schema$1.Literal("user"),
|
|
2960
|
+
user: WhoamiUser,
|
|
2961
|
+
role: Schema$1.Union([
|
|
2962
|
+
Schema$1.Literal("member"),
|
|
2963
|
+
Schema$1.Literal("admin"),
|
|
2964
|
+
Schema$1.Literal("owner")
|
|
2965
|
+
])
|
|
2966
|
+
}).annotate({ identifier: "WhoamiUserCredential" });
|
|
2943
2967
|
const ApiKeyAccess = Schema$1.Union([Schema$1.Struct({ mode: Schema$1.Literal("full") }), Schema$1.Struct({
|
|
2944
2968
|
mode: Schema$1.Literal("restricted"),
|
|
2945
2969
|
resources: ApiKeyResourceAccess,
|
|
@@ -2996,6 +3020,7 @@ const UpdateBrand = Schema$1.Struct({
|
|
|
2996
3020
|
}).annotate({ identifier: "UpdateBrand" });
|
|
2997
3021
|
const EmailAttachments = Schema$1.Union([Schema$1.Array(EmailAttachment).check(Schema$1.isMaxLength(10).annotate({ expected: "a value with a length of at most 10" })), Schema$1.Null]).annotate({ identifier: "EmailAttachments" });
|
|
2998
3022
|
const MailboxSendSnapshot = Schema$1.Struct({
|
|
3023
|
+
channel: Schema$1.Literal("email"),
|
|
2999
3024
|
draftRevision: Schema$1.Finite.check(Schema$1.isInt().annotate({ expected: "an integer" })).check(Schema$1.isGreaterThan(0).annotate({ expected: "a value greater than 0" })),
|
|
3000
3025
|
from: Schema$1.String,
|
|
3001
3026
|
fromName: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
@@ -3013,6 +3038,7 @@ const MailboxSendSnapshot = Schema$1.Struct({
|
|
|
3013
3038
|
}).annotate({ identifier: "MailboxSendSnapshot" });
|
|
3014
3039
|
const MailboxDraft = Schema$1.Struct({
|
|
3015
3040
|
id: MailboxDraftId,
|
|
3041
|
+
channel: Schema$1.Literal("email"),
|
|
3016
3042
|
threadId: Schema$1.Union([MailboxThreadId, Schema$1.Null]),
|
|
3017
3043
|
inReplyToMessageId: Schema$1.Union([MessageId, Schema$1.Null]),
|
|
3018
3044
|
state: MailboxDraftState,
|
|
@@ -3021,6 +3047,7 @@ const MailboxDraft = Schema$1.Struct({
|
|
|
3021
3047
|
subject: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
3022
3048
|
createdAt: Schema$1.String,
|
|
3023
3049
|
updatedAt: Schema$1.String,
|
|
3050
|
+
endpointId: Schema$1.Union([MailboxEndpointId, Schema$1.Null]),
|
|
3024
3051
|
cc: Schema$1.Array(Schema$1.String),
|
|
3025
3052
|
bcc: Schema$1.Array(Schema$1.String),
|
|
3026
3053
|
replyTo: Schema$1.Array(Schema$1.String),
|
|
@@ -3029,6 +3056,8 @@ const MailboxDraft = Schema$1.Struct({
|
|
|
3029
3056
|
attachments: Schema$1.Array(EmailAttachment).check(Schema$1.isMaxLength(10).annotate({ expected: "a value with a length of at most 10" }))
|
|
3030
3057
|
}).annotate({ identifier: "MailboxDraft" });
|
|
3031
3058
|
Schema$1.Struct({
|
|
3059
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
3060
|
+
endpointId: Schema$1.optionalKey(Schema$1.Union([MailboxEndpointId, Schema$1.Null])),
|
|
3032
3061
|
to: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
3033
3062
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
3034
3063
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
@@ -3048,6 +3077,7 @@ Schema$1.Struct({
|
|
|
3048
3077
|
attachments: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(EmailAttachment).check(Schema$1.isMaxLength(10).annotate({ expected: "a value with a length of at most 10" })), Schema$1.Null]))
|
|
3049
3078
|
}).annotate({ identifier: "ForwardMailboxMessagePayload" });
|
|
3050
3079
|
Schema$1.Struct({
|
|
3080
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
3051
3081
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
3052
3082
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
3053
3083
|
text: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
@@ -3055,6 +3085,7 @@ Schema$1.Struct({
|
|
|
3055
3085
|
attachments: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(EmailAttachment).check(Schema$1.isMaxLength(10).annotate({ expected: "a value with a length of at most 10" })), Schema$1.Null]))
|
|
3056
3086
|
}).annotate({ identifier: "ReplyMailboxMessagePayload" });
|
|
3057
3087
|
Schema$1.Struct({
|
|
3088
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
3058
3089
|
to: Schema$1.TupleWithRest(Schema$1.Tuple([Schema$1.String]), [Schema$1.String]),
|
|
3059
3090
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
3060
3091
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
@@ -3539,6 +3570,13 @@ const MailboxPage = Schema$1.Struct({
|
|
|
3539
3570
|
items: Schema$1.Array(MailboxSummary),
|
|
3540
3571
|
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
3541
3572
|
}).annotate({ identifier: "MailboxPage" });
|
|
3573
|
+
Schema$1.Struct({
|
|
3574
|
+
namespaceId: Schema$1.optionalKey(Schema$1.Union([NamespaceId, Schema$1.Null])),
|
|
3575
|
+
endpoint: CreateMailboxEndpointPayload,
|
|
3576
|
+
name: Schema$1.String,
|
|
3577
|
+
slug: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
3578
|
+
metadata: Schema$1.optionalKey(Schema$1.Union([MailboxMetadata, Schema$1.Null]))
|
|
3579
|
+
}).annotate({ identifier: "CreateMailboxPayload" });
|
|
3542
3580
|
const Mailbox = Schema$1.Struct({
|
|
3543
3581
|
id: MailboxId,
|
|
3544
3582
|
namespaceId: Schema$1.Union([NamespaceId, Schema$1.Null]),
|
|
@@ -3549,8 +3587,7 @@ const Mailbox = Schema$1.Struct({
|
|
|
3549
3587
|
createdAt: Schema$1.String,
|
|
3550
3588
|
description: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
3551
3589
|
metadata: MailboxMetadata,
|
|
3552
|
-
|
|
3553
|
-
defaultFrom: Schema$1.Union([MailboxDefaultFrom, Schema$1.Null]),
|
|
3590
|
+
endpoints: Schema$1.Array(MailboxEndpoint),
|
|
3554
3591
|
updatedAt: Schema$1.String
|
|
3555
3592
|
}).annotate({ identifier: "Mailbox" });
|
|
3556
3593
|
const MailboxQuarantinePage = Schema$1.Struct({
|
|
@@ -3756,6 +3793,13 @@ const ApiKeyWithSecret = Schema$1.Struct({
|
|
|
3756
3793
|
access: ApiKeyAccess,
|
|
3757
3794
|
owner: Schema$1.Union([ApiKeyOwner, Schema$1.Null])
|
|
3758
3795
|
}).annotate({ identifier: "ApiKeyWithSecret" });
|
|
3796
|
+
const WhoamiApiKeyCredential = Schema$1.Struct({
|
|
3797
|
+
type: Schema$1.Literal("apiKey"),
|
|
3798
|
+
id: Schema$1.String,
|
|
3799
|
+
name: Schema$1.String,
|
|
3800
|
+
start: Schema$1.Union([Schema$1.String, Schema$1.Null]),
|
|
3801
|
+
access: ApiKeyAccess
|
|
3802
|
+
}).annotate({ identifier: "WhoamiApiKeyCredential" });
|
|
3759
3803
|
const Message = Schema$1.Struct({
|
|
3760
3804
|
id: MessageId,
|
|
3761
3805
|
channel: Schema$1.Literal("email"),
|
|
@@ -3929,13 +3973,27 @@ const ApiKeyPage = Schema$1.Struct({
|
|
|
3929
3973
|
items: Schema$1.Array(ApiKey),
|
|
3930
3974
|
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
3931
3975
|
}).annotate({ identifier: "ApiKeyPage" });
|
|
3932
|
-
const
|
|
3976
|
+
const Whoami = Schema$1.Struct({
|
|
3977
|
+
organization: WhoamiOrganization,
|
|
3978
|
+
credential: Schema$1.Union([WhoamiApiKeyCredential, WhoamiUserCredential])
|
|
3979
|
+
}).annotate({ identifier: "Whoami" });
|
|
3980
|
+
const CampaignContent = Schema$1.Struct({
|
|
3933
3981
|
channel: Schema$1.Literal("email"),
|
|
3934
3982
|
email: EmailContent,
|
|
3935
3983
|
conversationId: Schema$1.optionalKey(CampaignConversationRef),
|
|
3936
3984
|
metadata: Schema$1.optionalKey(CampaignContentMetadata)
|
|
3937
|
-
}).annotate({ identifier: "
|
|
3938
|
-
const
|
|
3985
|
+
}).annotate({ identifier: "CampaignContent" });
|
|
3986
|
+
const SendMessagePayload = Schema$1.Struct({
|
|
3987
|
+
conversationId: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([ConversationId, Schema$1.Null]), Schema$1.Null])),
|
|
3988
|
+
metadata: Schema$1.optionalKey(MessageMetadata),
|
|
3989
|
+
channel: Schema$1.Literal("email"),
|
|
3990
|
+
to: EmailRecipients,
|
|
3991
|
+
cc: Schema$1.optionalKey(EmailCcRecipients),
|
|
3992
|
+
bcc: Schema$1.optionalKey(EmailBccRecipients),
|
|
3993
|
+
from: Schema$1.optionalKey(EmailSender),
|
|
3994
|
+
email: EmailContent
|
|
3995
|
+
}).annotate({ identifier: "SendMessagePayload" });
|
|
3996
|
+
Schema$1.Struct({
|
|
3939
3997
|
conversationId: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([ConversationId, Schema$1.Null]), Schema$1.Null])),
|
|
3940
3998
|
metadata: Schema$1.optionalKey(MessageMetadata),
|
|
3941
3999
|
channel: Schema$1.Literal("email"),
|
|
@@ -3945,13 +4003,13 @@ const EmailSendMessagePayload = Schema$1.Struct({
|
|
|
3945
4003
|
from: Schema$1.optionalKey(EmailSender),
|
|
3946
4004
|
email: EmailContent
|
|
3947
4005
|
}).annotate({ identifier: "EmailSendMessagePayload" });
|
|
3948
|
-
const
|
|
4006
|
+
const CampaignContentInput = Schema$1.Struct({
|
|
3949
4007
|
channel: Schema$1.Literal("email"),
|
|
3950
4008
|
email: EmailDispatchContent,
|
|
3951
4009
|
conversationId: Schema$1.optionalKey(CampaignConversationRef),
|
|
3952
4010
|
metadata: Schema$1.optionalKey(CampaignContentMetadata)
|
|
3953
|
-
}).annotate({ identifier: "
|
|
3954
|
-
const
|
|
4011
|
+
}).annotate({ identifier: "CampaignContentInput" });
|
|
4012
|
+
const DispatchSendMessagePayload = Schema$1.Struct({
|
|
3955
4013
|
conversationId: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([ConversationId, Schema$1.Null]), Schema$1.Null])),
|
|
3956
4014
|
metadata: Schema$1.optionalKey(MessageMetadata),
|
|
3957
4015
|
channel: Schema$1.Literal("email"),
|
|
@@ -3960,17 +4018,9 @@ const EmailDispatchSendMessagePayload = Schema$1.Struct({
|
|
|
3960
4018
|
bcc: Schema$1.optionalKey(EmailBccRecipients),
|
|
3961
4019
|
from: Schema$1.optionalKey(EmailSender),
|
|
3962
4020
|
email: EmailDispatchContent
|
|
3963
|
-
}).annotate({ identifier: "
|
|
4021
|
+
}).annotate({ identifier: "DispatchSendMessagePayload" });
|
|
3964
4022
|
const MailboxAction = Schema$1.Union([MailboxSendAction, MailboxNonSendAction]).annotate({ identifier: "MailboxAction" });
|
|
3965
4023
|
const MailboxPendingAction = Schema$1.Union([MailboxSendAction, MailboxNonSendAction]).annotate({ identifier: "MailboxPendingAction" });
|
|
3966
|
-
const CampaignContent = Schema$1.Union([EmailCampaignContent]).annotate({ identifier: "CampaignContent" });
|
|
3967
|
-
const SendMessagePayload = Schema$1.Union([EmailSendMessagePayload]).annotate({ identifier: "SendMessagePayload" });
|
|
3968
|
-
const CampaignContentInput = Schema$1.Union([EmailCampaignContentInput]).annotate({ identifier: "CampaignContentInput" });
|
|
3969
|
-
const DispatchSendMessagePayload = Schema$1.Union([EmailDispatchSendMessagePayload]).annotate({ identifier: "DispatchSendMessagePayload" });
|
|
3970
|
-
const MailboxActionPage = Schema$1.Struct({
|
|
3971
|
-
items: Schema$1.Array(MailboxAction),
|
|
3972
|
-
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
3973
|
-
}).annotate({ identifier: "MailboxActionPage" });
|
|
3974
4024
|
const CampaignListItem = Schema$1.Struct({
|
|
3975
4025
|
id: CampaignId,
|
|
3976
4026
|
name: Schema$1.String,
|
|
@@ -4060,6 +4110,10 @@ const ScheduledMessage = Schema$1.Struct({
|
|
|
4060
4110
|
createdAt: Schema$1.String,
|
|
4061
4111
|
updatedAt: Schema$1.String
|
|
4062
4112
|
}).annotate({ identifier: "ScheduledMessage" });
|
|
4113
|
+
const MailboxActionPage = Schema$1.Struct({
|
|
4114
|
+
items: Schema$1.Array(MailboxAction),
|
|
4115
|
+
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
4116
|
+
}).annotate({ identifier: "MailboxActionPage" });
|
|
4063
4117
|
const CampaignPage = Schema$1.Struct({
|
|
4064
4118
|
items: Schema$1.Array(CampaignListItem),
|
|
4065
4119
|
nextCursor: Schema$1.Union([Schema$1.String, Schema$1.Null])
|
|
@@ -5722,23 +5776,6 @@ const EmailSetDefaultDomain404 = ResourceNotFoundError;
|
|
|
5722
5776
|
const EmailSetDefaultDomain422 = ValidationError;
|
|
5723
5777
|
const EmailSetDefaultDomain500 = InternalError;
|
|
5724
5778
|
const EmailSetDefaultDomain504 = GatewayTimeoutError;
|
|
5725
|
-
const EmailSetDomainDefaultSenderPathParams = Schema$1.Struct({ id: EmailDomainId });
|
|
5726
|
-
const EmailSetDomainDefaultSenderRequestJson = Schema$1.Struct({ senderId: EmailSenderId });
|
|
5727
|
-
const EmailSetDomainDefaultSender200 = SuccessResult;
|
|
5728
|
-
const EmailSetDomainDefaultSender401 = UnauthorizedError;
|
|
5729
|
-
const EmailSetDomainDefaultSender403 = ForbiddenError;
|
|
5730
|
-
const EmailSetDomainDefaultSender404 = ResourceNotFoundError;
|
|
5731
|
-
const EmailSetDomainDefaultSender422 = ValidationError;
|
|
5732
|
-
const EmailSetDomainDefaultSender500 = InternalError;
|
|
5733
|
-
const EmailSetDomainDefaultSender504 = GatewayTimeoutError;
|
|
5734
|
-
const EmailClearDomainDefaultSenderPathParams = Schema$1.Struct({ id: EmailDomainId });
|
|
5735
|
-
const EmailClearDomainDefaultSender200 = SuccessResult;
|
|
5736
|
-
const EmailClearDomainDefaultSender401 = UnauthorizedError;
|
|
5737
|
-
const EmailClearDomainDefaultSender403 = ForbiddenError;
|
|
5738
|
-
const EmailClearDomainDefaultSender404 = ResourceNotFoundError;
|
|
5739
|
-
const EmailClearDomainDefaultSender422 = ValidationError;
|
|
5740
|
-
const EmailClearDomainDefaultSender500 = InternalError;
|
|
5741
|
-
const EmailClearDomainDefaultSender504 = GatewayTimeoutError;
|
|
5742
5779
|
const EmailDisableCatchAllPathParams = Schema$1.Struct({ id: EmailDomainId });
|
|
5743
5780
|
const EmailDisableCatchAll200 = Schema$1.Struct({ success: Schema$1.Literal(true) });
|
|
5744
5781
|
const EmailDisableCatchAll401 = UnauthorizedError;
|
|
@@ -6485,7 +6522,7 @@ const MailboxesList500 = InternalError;
|
|
|
6485
6522
|
const MailboxesList504 = GatewayTimeoutError;
|
|
6486
6523
|
const MailboxesCreateRequestJson = Schema$1.Struct({
|
|
6487
6524
|
namespaceId: Schema$1.optionalKey(Schema$1.Union([NamespaceId, Schema$1.Null])),
|
|
6488
|
-
|
|
6525
|
+
endpoint: CreateMailboxEndpointPayload,
|
|
6489
6526
|
name: Schema$1.String,
|
|
6490
6527
|
slug: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
6491
6528
|
metadata: Schema$1.optionalKey(Schema$1.Union([MailboxMetadata, Schema$1.Null]))
|
|
@@ -6496,7 +6533,7 @@ const MailboxesCreate402 = PaymentRequiredError;
|
|
|
6496
6533
|
const MailboxesCreate403 = ForbiddenError;
|
|
6497
6534
|
const MailboxesCreate404 = ResourceNotFoundError;
|
|
6498
6535
|
const MailboxesCreate409 = ConflictError;
|
|
6499
|
-
const MailboxesCreate422 = ValidationError;
|
|
6536
|
+
const MailboxesCreate422 = Schema$1.Union([ValidationError, MailboxChannelUnsupportedError]);
|
|
6500
6537
|
const MailboxesCreate500 = InternalError;
|
|
6501
6538
|
const MailboxesCreate502 = BillingProviderError;
|
|
6502
6539
|
const MailboxesCreate504 = GatewayTimeoutError;
|
|
@@ -6520,11 +6557,7 @@ const MailboxesRemove504 = GatewayTimeoutError;
|
|
|
6520
6557
|
const MailboxesUpdatePathParams = Schema$1.Struct({ id: MailboxId });
|
|
6521
6558
|
const MailboxesUpdateRequestJson = Schema$1.Struct({
|
|
6522
6559
|
name: Schema$1.optionalKey(Schema$1.Union([Schema$1.String.check(Schema$1.isMinLength(1).annotate({ expected: "a value with a length of at least 1" })), Schema$1.Null])),
|
|
6523
|
-
metadata: Schema$1.optionalKey(Schema$1.Union([MailboxMetadataPatch, Schema$1.Null]))
|
|
6524
|
-
defaultFrom: Schema$1.optionalKey(Schema$1.Union([Schema$1.Struct({
|
|
6525
|
-
address: Schema$1.String,
|
|
6526
|
-
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([Schema$1.String, Schema$1.Null]), Schema$1.Null]))
|
|
6527
|
-
}), Schema$1.Null]))
|
|
6560
|
+
metadata: Schema$1.optionalKey(Schema$1.Union([MailboxMetadataPatch, Schema$1.Null]))
|
|
6528
6561
|
});
|
|
6529
6562
|
const MailboxesUpdate200 = Mailbox;
|
|
6530
6563
|
const MailboxesUpdate401 = UnauthorizedError;
|
|
@@ -6590,7 +6623,7 @@ const MailboxesApproveAction403 = Schema$1.Union([
|
|
|
6590
6623
|
]);
|
|
6591
6624
|
const MailboxesApproveAction404 = ResourceNotFoundError;
|
|
6592
6625
|
const MailboxesApproveAction409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
6593
|
-
const MailboxesApproveAction422 = ValidationError;
|
|
6626
|
+
const MailboxesApproveAction422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
6594
6627
|
const MailboxesApproveAction429 = RateLimitedError;
|
|
6595
6628
|
const MailboxesApproveAction500 = InternalError;
|
|
6596
6629
|
const MailboxesApproveAction502 = BillingProviderError;
|
|
@@ -6611,7 +6644,7 @@ const MailboxesCancelAction403 = Schema$1.Union([
|
|
|
6611
6644
|
]);
|
|
6612
6645
|
const MailboxesCancelAction404 = ResourceNotFoundError;
|
|
6613
6646
|
const MailboxesCancelAction409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
6614
|
-
const MailboxesCancelAction422 = ValidationError;
|
|
6647
|
+
const MailboxesCancelAction422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
6615
6648
|
const MailboxesCancelAction429 = RateLimitedError;
|
|
6616
6649
|
const MailboxesCancelAction500 = InternalError;
|
|
6617
6650
|
const MailboxesCancelAction502 = BillingProviderError;
|
|
@@ -6645,36 +6678,12 @@ const MailboxesRetryAction403 = Schema$1.Union([
|
|
|
6645
6678
|
]);
|
|
6646
6679
|
const MailboxesRetryAction404 = ResourceNotFoundError;
|
|
6647
6680
|
const MailboxesRetryAction409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
6648
|
-
const MailboxesRetryAction422 = ValidationError;
|
|
6681
|
+
const MailboxesRetryAction422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
6649
6682
|
const MailboxesRetryAction429 = RateLimitedError;
|
|
6650
6683
|
const MailboxesRetryAction500 = InternalError;
|
|
6651
6684
|
const MailboxesRetryAction502 = BillingProviderError;
|
|
6652
6685
|
const MailboxesRetryAction503 = SenderNotReadyError;
|
|
6653
6686
|
const MailboxesRetryAction504 = GatewayTimeoutError;
|
|
6654
|
-
const MailboxesCreateAddressPathParams = Schema$1.Struct({ id: MailboxId });
|
|
6655
|
-
const MailboxesCreateAddressRequestJson = Schema$1.Struct({
|
|
6656
|
-
address: Schema$1.String,
|
|
6657
|
-
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null]))
|
|
6658
|
-
});
|
|
6659
|
-
const MailboxesCreateAddress201 = Mailbox;
|
|
6660
|
-
const MailboxesCreateAddress401 = UnauthorizedError;
|
|
6661
|
-
const MailboxesCreateAddress403 = ForbiddenError;
|
|
6662
|
-
const MailboxesCreateAddress404 = ResourceNotFoundError;
|
|
6663
|
-
const MailboxesCreateAddress409 = ConflictError;
|
|
6664
|
-
const MailboxesCreateAddress422 = ValidationError;
|
|
6665
|
-
const MailboxesCreateAddress500 = InternalError;
|
|
6666
|
-
const MailboxesCreateAddress504 = GatewayTimeoutError;
|
|
6667
|
-
const MailboxesRemoveAddressPathParams = Schema$1.Struct({
|
|
6668
|
-
id: MailboxId,
|
|
6669
|
-
addressId: MailboxAddressId
|
|
6670
|
-
});
|
|
6671
|
-
const MailboxesRemoveAddress200 = Mailbox;
|
|
6672
|
-
const MailboxesRemoveAddress401 = UnauthorizedError;
|
|
6673
|
-
const MailboxesRemoveAddress403 = ForbiddenError;
|
|
6674
|
-
const MailboxesRemoveAddress404 = ResourceNotFoundError;
|
|
6675
|
-
const MailboxesRemoveAddress422 = ValidationError;
|
|
6676
|
-
const MailboxesRemoveAddress500 = InternalError;
|
|
6677
|
-
const MailboxesRemoveAddress504 = GatewayTimeoutError;
|
|
6678
6687
|
const MailboxesGetAgentActivityPathParams = Schema$1.Struct({ id: MailboxId });
|
|
6679
6688
|
const MailboxesGetAgentActivityQuery = Schema$1.Struct({
|
|
6680
6689
|
after: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
@@ -6702,6 +6711,8 @@ const MailboxesListDrafts500 = InternalError;
|
|
|
6702
6711
|
const MailboxesListDrafts504 = GatewayTimeoutError;
|
|
6703
6712
|
const MailboxesCreateDraftPathParams = Schema$1.Struct({ id: MailboxId });
|
|
6704
6713
|
const MailboxesCreateDraftRequestJson = Schema$1.Struct({
|
|
6714
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
6715
|
+
endpointId: Schema$1.optionalKey(Schema$1.Union([MailboxEndpointId, Schema$1.Null])),
|
|
6705
6716
|
to: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
6706
6717
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
6707
6718
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
@@ -6716,7 +6727,7 @@ const MailboxesCreateDraft201 = MailboxDraft;
|
|
|
6716
6727
|
const MailboxesCreateDraft401 = UnauthorizedError;
|
|
6717
6728
|
const MailboxesCreateDraft403 = ForbiddenError;
|
|
6718
6729
|
const MailboxesCreateDraft404 = ResourceNotFoundError;
|
|
6719
|
-
const MailboxesCreateDraft422 = ValidationError;
|
|
6730
|
+
const MailboxesCreateDraft422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
6720
6731
|
const MailboxesCreateDraft500 = InternalError;
|
|
6721
6732
|
const MailboxesCreateDraft504 = GatewayTimeoutError;
|
|
6722
6733
|
const MailboxesGetDraftPathParams = Schema$1.Struct({
|
|
@@ -6779,12 +6790,52 @@ const MailboxesSendDraft403 = Schema$1.Union([
|
|
|
6779
6790
|
]);
|
|
6780
6791
|
const MailboxesSendDraft404 = ResourceNotFoundError;
|
|
6781
6792
|
const MailboxesSendDraft409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
6782
|
-
const MailboxesSendDraft422 = ValidationError;
|
|
6793
|
+
const MailboxesSendDraft422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
6783
6794
|
const MailboxesSendDraft429 = RateLimitedError;
|
|
6784
6795
|
const MailboxesSendDraft500 = InternalError;
|
|
6785
6796
|
const MailboxesSendDraft502 = BillingProviderError;
|
|
6786
6797
|
const MailboxesSendDraft503 = SenderNotReadyError;
|
|
6787
6798
|
const MailboxesSendDraft504 = GatewayTimeoutError;
|
|
6799
|
+
const MailboxesCreateEndpointPathParams = Schema$1.Struct({ id: MailboxId });
|
|
6800
|
+
const MailboxesCreateEndpointRequestJson = Schema$1.Struct({
|
|
6801
|
+
channel: MailboxChannel,
|
|
6802
|
+
address: Schema$1.String,
|
|
6803
|
+
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null]))
|
|
6804
|
+
});
|
|
6805
|
+
const MailboxesCreateEndpoint201 = Mailbox;
|
|
6806
|
+
const MailboxesCreateEndpoint401 = UnauthorizedError;
|
|
6807
|
+
const MailboxesCreateEndpoint403 = ForbiddenError;
|
|
6808
|
+
const MailboxesCreateEndpoint404 = ResourceNotFoundError;
|
|
6809
|
+
const MailboxesCreateEndpoint409 = ConflictError;
|
|
6810
|
+
const MailboxesCreateEndpoint422 = Schema$1.Union([ValidationError, MailboxChannelUnsupportedError]);
|
|
6811
|
+
const MailboxesCreateEndpoint500 = InternalError;
|
|
6812
|
+
const MailboxesCreateEndpoint504 = GatewayTimeoutError;
|
|
6813
|
+
const MailboxesRemoveEndpointPathParams = Schema$1.Struct({
|
|
6814
|
+
id: MailboxId,
|
|
6815
|
+
endpointId: MailboxEndpointId
|
|
6816
|
+
});
|
|
6817
|
+
const MailboxesRemoveEndpoint200 = Mailbox;
|
|
6818
|
+
const MailboxesRemoveEndpoint401 = UnauthorizedError;
|
|
6819
|
+
const MailboxesRemoveEndpoint403 = ForbiddenError;
|
|
6820
|
+
const MailboxesRemoveEndpoint404 = ResourceNotFoundError;
|
|
6821
|
+
const MailboxesRemoveEndpoint422 = ValidationError;
|
|
6822
|
+
const MailboxesRemoveEndpoint500 = InternalError;
|
|
6823
|
+
const MailboxesRemoveEndpoint504 = GatewayTimeoutError;
|
|
6824
|
+
const MailboxesUpdateEndpointPathParams = Schema$1.Struct({
|
|
6825
|
+
id: MailboxId,
|
|
6826
|
+
endpointId: MailboxEndpointId
|
|
6827
|
+
});
|
|
6828
|
+
const MailboxesUpdateEndpointRequestJson = Schema$1.Struct({
|
|
6829
|
+
displayName: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([Schema$1.String, Schema$1.Null]), Schema$1.Null])),
|
|
6830
|
+
default: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal(true), Schema$1.Null]))
|
|
6831
|
+
});
|
|
6832
|
+
const MailboxesUpdateEndpoint200 = Mailbox;
|
|
6833
|
+
const MailboxesUpdateEndpoint401 = UnauthorizedError;
|
|
6834
|
+
const MailboxesUpdateEndpoint403 = ForbiddenError;
|
|
6835
|
+
const MailboxesUpdateEndpoint404 = ResourceNotFoundError;
|
|
6836
|
+
const MailboxesUpdateEndpoint422 = ValidationError;
|
|
6837
|
+
const MailboxesUpdateEndpoint500 = InternalError;
|
|
6838
|
+
const MailboxesUpdateEndpoint504 = GatewayTimeoutError;
|
|
6788
6839
|
const MailboxesListEventsPathParams = Schema$1.Struct({ id: MailboxId });
|
|
6789
6840
|
const MailboxesListEventsQuery = Schema$1.Struct({
|
|
6790
6841
|
limit: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
@@ -6926,6 +6977,7 @@ const MailboxesUpdateLabel504 = GatewayTimeoutError;
|
|
|
6926
6977
|
const MailboxesSendMessagePathParams = Schema$1.Struct({ id: MailboxId });
|
|
6927
6978
|
const MailboxesSendMessageHeaders = Schema$1.Struct({ "idempotency-key": Schema$1.optionalKey(Schema$1.Union([Schema$1.String.annotate({ description: "Optional key that makes a mailbox send idempotent for the calling key or member. Repeating the request with the same key and body returns the original action in its current state. Keep the key after a lost response. Reusing it with different content returns 409. Active actions retain their key; terminal receipts remain replayable for 24 hours." }).check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^[\\s\\S]{1,255}$")).annotate({ expected: "a string matching the RegExp ^[\\s\\S]{1,255}$" })), Schema$1.Null])) });
|
|
6928
6979
|
const MailboxesSendMessageRequestJson = Schema$1.Struct({
|
|
6980
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
6929
6981
|
to: Schema$1.TupleWithRest(Schema$1.Tuple([Schema$1.String]), [Schema$1.String]),
|
|
6930
6982
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
6931
6983
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
@@ -6946,7 +6998,7 @@ const MailboxesSendMessage403 = Schema$1.Union([
|
|
|
6946
6998
|
]);
|
|
6947
6999
|
const MailboxesSendMessage404 = ResourceNotFoundError;
|
|
6948
7000
|
const MailboxesSendMessage409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
6949
|
-
const MailboxesSendMessage422 = ValidationError;
|
|
7001
|
+
const MailboxesSendMessage422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
6950
7002
|
const MailboxesSendMessage429 = RateLimitedError;
|
|
6951
7003
|
const MailboxesSendMessage500 = InternalError;
|
|
6952
7004
|
const MailboxesSendMessage502 = BillingProviderError;
|
|
@@ -7025,7 +7077,7 @@ const MailboxesForward403 = Schema$1.Union([
|
|
|
7025
7077
|
]);
|
|
7026
7078
|
const MailboxesForward404 = ResourceNotFoundError;
|
|
7027
7079
|
const MailboxesForward409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
7028
|
-
const MailboxesForward422 = ValidationError;
|
|
7080
|
+
const MailboxesForward422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
7029
7081
|
const MailboxesForward429 = RateLimitedError;
|
|
7030
7082
|
const MailboxesForward500 = InternalError;
|
|
7031
7083
|
const MailboxesForward502 = BillingProviderError;
|
|
@@ -7060,6 +7112,7 @@ const MailboxesReplyPathParams = Schema$1.Struct({
|
|
|
7060
7112
|
});
|
|
7061
7113
|
const MailboxesReplyHeaders = Schema$1.Struct({ "idempotency-key": Schema$1.optionalKey(Schema$1.Union([Schema$1.String.annotate({ description: "Optional key that makes a mailbox send idempotent for the calling key or member. Repeating the request with the same key and body returns the original action in its current state. Keep the key after a lost response. Reusing it with different content returns 409. Active actions retain their key; terminal receipts remain replayable for 24 hours." }).check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^[\\s\\S]{1,255}$")).annotate({ expected: "a string matching the RegExp ^[\\s\\S]{1,255}$" })), Schema$1.Null])) });
|
|
7062
7114
|
const MailboxesReplyRequestJson = Schema$1.Struct({
|
|
7115
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
7063
7116
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
7064
7117
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
7065
7118
|
text: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
@@ -7077,7 +7130,7 @@ const MailboxesReply403 = Schema$1.Union([
|
|
|
7077
7130
|
]);
|
|
7078
7131
|
const MailboxesReply404 = ResourceNotFoundError;
|
|
7079
7132
|
const MailboxesReply409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
7080
|
-
const MailboxesReply422 = ValidationError;
|
|
7133
|
+
const MailboxesReply422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
7081
7134
|
const MailboxesReply429 = RateLimitedError;
|
|
7082
7135
|
const MailboxesReply500 = InternalError;
|
|
7083
7136
|
const MailboxesReply502 = BillingProviderError;
|
|
@@ -7089,6 +7142,7 @@ const MailboxesReplyAllPathParams = Schema$1.Struct({
|
|
|
7089
7142
|
});
|
|
7090
7143
|
const MailboxesReplyAllHeaders = Schema$1.Struct({ "idempotency-key": Schema$1.optionalKey(Schema$1.Union([Schema$1.String.annotate({ description: "Optional key that makes a mailbox send idempotent for the calling key or member. Repeating the request with the same key and body returns the original action in its current state. Keep the key after a lost response. Reusing it with different content returns 409. Active actions retain their key; terminal receipts remain replayable for 24 hours." }).check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^[\\s\\S]{1,255}$")).annotate({ expected: "a string matching the RegExp ^[\\s\\S]{1,255}$" })), Schema$1.Null])) });
|
|
7091
7144
|
const MailboxesReplyAllRequestJson = Schema$1.Struct({
|
|
7145
|
+
channel: Schema$1.optionalKey(Schema$1.Union([Schema$1.Literal("email"), Schema$1.Null])),
|
|
7092
7146
|
cc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
7093
7147
|
bcc: Schema$1.optionalKey(Schema$1.Union([Schema$1.Array(Schema$1.String), Schema$1.Null])),
|
|
7094
7148
|
text: Schema$1.optionalKey(Schema$1.Union([Schema$1.String, Schema$1.Null])),
|
|
@@ -7106,7 +7160,7 @@ const MailboxesReplyAll403 = Schema$1.Union([
|
|
|
7106
7160
|
]);
|
|
7107
7161
|
const MailboxesReplyAll404 = ResourceNotFoundError;
|
|
7108
7162
|
const MailboxesReplyAll409 = Schema$1.Union([MailboxSendConflictError, ConflictError]);
|
|
7109
|
-
const MailboxesReplyAll422 = ValidationError;
|
|
7163
|
+
const MailboxesReplyAll422 = Schema$1.Union([MailboxChannelUnsupportedError, ValidationError]);
|
|
7110
7164
|
const MailboxesReplyAll429 = RateLimitedError;
|
|
7111
7165
|
const MailboxesReplyAll500 = InternalError;
|
|
7112
7166
|
const MailboxesReplyAll502 = BillingProviderError;
|
|
@@ -7446,7 +7500,16 @@ const MessagesList422 = ValidationError;
|
|
|
7446
7500
|
const MessagesList500 = InternalError;
|
|
7447
7501
|
const MessagesList504 = GatewayTimeoutError;
|
|
7448
7502
|
const MessagesSendHeaders = Schema$1.Struct({ "idempotency-key": Schema$1.optionalKey(Schema$1.Union([Schema$1.String.annotate({ description: "Optional org-scoped key that makes a send idempotent. Repeating a request with the same key and identical payload replays the original 201 response; reusing the key with different content returns 409." }).check(Schema$1.isPattern(/* @__PURE__ */ new RegExp("^[\\s\\S]{1,255}$")).annotate({ expected: "a string matching the RegExp ^[\\s\\S]{1,255}$" })), Schema$1.Null])) });
|
|
7449
|
-
const MessagesSendRequestJson = Schema$1.
|
|
7503
|
+
const MessagesSendRequestJson = Schema$1.Struct({
|
|
7504
|
+
conversationId: Schema$1.optionalKey(Schema$1.Union([Schema$1.Union([ConversationId, Schema$1.Null]), Schema$1.Null])),
|
|
7505
|
+
metadata: Schema$1.optionalKey(MessageMetadata),
|
|
7506
|
+
channel: Schema$1.Literal("email"),
|
|
7507
|
+
to: EmailRecipients,
|
|
7508
|
+
cc: Schema$1.optionalKey(EmailCcRecipients),
|
|
7509
|
+
bcc: Schema$1.optionalKey(EmailBccRecipients),
|
|
7510
|
+
from: Schema$1.optionalKey(EmailSender),
|
|
7511
|
+
email: EmailContent
|
|
7512
|
+
});
|
|
7450
7513
|
const MessagesSend201 = MessageReceipt;
|
|
7451
7514
|
const MessagesSend401 = UnauthorizedError;
|
|
7452
7515
|
const MessagesSend402 = PaymentRequiredError;
|
|
@@ -10014,6 +10077,12 @@ const WebhooksTest404 = ResourceNotFoundError;
|
|
|
10014
10077
|
const WebhooksTest422 = ValidationError;
|
|
10015
10078
|
const WebhooksTest500 = InternalError;
|
|
10016
10079
|
const WebhooksTest504 = GatewayTimeoutError;
|
|
10080
|
+
const WhoamiGet200 = Whoami;
|
|
10081
|
+
const WhoamiGet401 = UnauthorizedError;
|
|
10082
|
+
const WhoamiGet403 = ForbiddenError;
|
|
10083
|
+
const WhoamiGet422 = ValidationError;
|
|
10084
|
+
const WhoamiGet500 = InternalError;
|
|
10085
|
+
const WhoamiGet504 = GatewayTimeoutError;
|
|
10017
10086
|
const ApiKeySecurity = HttpApiSecurity.apiKey({
|
|
10018
10087
|
key: "x-api-key",
|
|
10019
10088
|
in: "header"
|
|
@@ -11222,30 +11291,7 @@ var EmailGroup = class extends HttpApiGroup.make("Email").add(HttpApiEndpoint.ge
|
|
|
11222
11291
|
EmailSetDefaultDomain500,
|
|
11223
11292
|
EmailSetDefaultDomain504.pipe(HttpApiSchema.status(504))
|
|
11224
11293
|
]
|
|
11225
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "email.setDefaultDomain").annotate(OpenApi.Summary, "Set the default sending domain").annotate(OpenApi.Description, "Marks a verified domain as the organization's default sending domain, atomically clearing any previous default.
|
|
11226
|
-
params: EmailSetDomainDefaultSenderPathParams,
|
|
11227
|
-
payload: EmailSetDomainDefaultSenderRequestJson,
|
|
11228
|
-
success: EmailSetDomainDefaultSender200,
|
|
11229
|
-
error: [
|
|
11230
|
-
EmailSetDomainDefaultSender401.pipe(HttpApiSchema.status(401)),
|
|
11231
|
-
EmailSetDomainDefaultSender403.pipe(HttpApiSchema.status(403)),
|
|
11232
|
-
EmailSetDomainDefaultSender404.pipe(HttpApiSchema.status(404)),
|
|
11233
|
-
EmailSetDomainDefaultSender422.pipe(HttpApiSchema.status(422)),
|
|
11234
|
-
EmailSetDomainDefaultSender500,
|
|
11235
|
-
EmailSetDomainDefaultSender504.pipe(HttpApiSchema.status(504))
|
|
11236
|
-
]
|
|
11237
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "email.setDomainDefaultSender").annotate(OpenApi.Summary, "Set a domain's default sender").annotate(OpenApi.Description, "Sets the default sender used for omitted-`from` sends from this domain. The sender must belong to the domain and be verified and active."), HttpApiEndpoint.delete("emailClearDomainDefaultSender", "/v1/email/domains/:id/default-sender", {
|
|
11238
|
-
params: EmailClearDomainDefaultSenderPathParams,
|
|
11239
|
-
success: EmailClearDomainDefaultSender200,
|
|
11240
|
-
error: [
|
|
11241
|
-
EmailClearDomainDefaultSender401.pipe(HttpApiSchema.status(401)),
|
|
11242
|
-
EmailClearDomainDefaultSender403.pipe(HttpApiSchema.status(403)),
|
|
11243
|
-
EmailClearDomainDefaultSender404.pipe(HttpApiSchema.status(404)),
|
|
11244
|
-
EmailClearDomainDefaultSender422.pipe(HttpApiSchema.status(422)),
|
|
11245
|
-
EmailClearDomainDefaultSender500,
|
|
11246
|
-
EmailClearDomainDefaultSender504.pipe(HttpApiSchema.status(504))
|
|
11247
|
-
]
|
|
11248
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "email.clearDomainDefaultSender").annotate(OpenApi.Summary, "Clear a domain's default sender").annotate(OpenApi.Description, "Removes the domain's default sender so omitted-`from` sends fall through to the organization default sender."), HttpApiEndpoint.post("emailDisableCatchAll", "/v1/email/domains/:id/disable-catch-all", {
|
|
11294
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "email.setDefaultDomain").annotate(OpenApi.Summary, "Set the default sending domain").annotate(OpenApi.Description, "Marks a verified domain as the organization's default sending domain, atomically clearing any previous default. Provisioning and inbound routing prefer the default domain when several apply. It does not choose the `from` of omitted-`from` sends; those use the organization default sender."), HttpApiEndpoint.post("emailDisableCatchAll", "/v1/email/domains/:id/disable-catch-all", {
|
|
11249
11295
|
params: EmailDisableCatchAllPathParams,
|
|
11250
11296
|
success: EmailDisableCatchAll200,
|
|
11251
11297
|
error: [
|
|
@@ -11613,7 +11659,7 @@ var EmailGroup = class extends HttpApiGroup.make("Email").add(HttpApiEndpoint.ge
|
|
|
11613
11659
|
EmailSetDefaultSender500,
|
|
11614
11660
|
EmailSetDefaultSender504.pipe(HttpApiSchema.status(504))
|
|
11615
11661
|
]
|
|
11616
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "email.setDefaultSender").annotate(OpenApi.Summary, "Set the organization default sender").annotate(OpenApi.Description, "Marks a verified, active sender as the organization default, atomically clearing any previous default.
|
|
11662
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "email.setDefaultSender").annotate(OpenApi.Summary, "Set the organization default sender").annotate(OpenApi.Description, "Marks a verified, active sender as the organization default, atomically clearing any previous default. Omitted-`from` sends use it when neither the request nor the template names a `from`; with no default, the organization's sole verified sender is used."), HttpApiEndpoint.get("emailCheckSenderVerification", "/v1/email/senders/:id/verification", {
|
|
11617
11663
|
params: EmailCheckSenderVerificationPathParams,
|
|
11618
11664
|
success: EmailCheckSenderVerification200,
|
|
11619
11665
|
error: [
|
|
@@ -11893,7 +11939,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
11893
11939
|
MailboxesList500,
|
|
11894
11940
|
MailboxesList504.pipe(HttpApiSchema.status(504))
|
|
11895
11941
|
]
|
|
11896
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.list").annotate(OpenApi.Summary, "List mailboxes").annotate(OpenApi.Description, "Returns summaries of the mailboxes the caller can read, newest first, filterable by creation time (`after`, `before`). Pass `nextCursor` back as `cursor` for the next page; it is null on the last page. Read a mailbox's
|
|
11942
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.list").annotate(OpenApi.Summary, "List mailboxes").annotate(OpenApi.Description, "Returns summaries of the mailboxes the caller can read, newest first, filterable by creation time (`after`, `before`). Pass `nextCursor` back as `cursor` for the next page; it is null on the last page. Read a mailbox's endpoints and metadata with `GET /v1/mailboxes/{id}`."), HttpApiEndpoint.post("mailboxesCreate", "/v1/mailboxes", {
|
|
11897
11943
|
payload: MailboxesCreateRequestJson,
|
|
11898
11944
|
success: MailboxesCreate201.pipe(HttpApiSchema.status(201)),
|
|
11899
11945
|
error: [
|
|
@@ -11907,7 +11953,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
11907
11953
|
MailboxesCreate502.pipe(HttpApiSchema.status(502)),
|
|
11908
11954
|
MailboxesCreate504.pipe(HttpApiSchema.status(504))
|
|
11909
11955
|
]
|
|
11910
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.create").annotate(OpenApi.Summary, "Create a mailbox").annotate(OpenApi.Description, "Creates a mailbox with one
|
|
11956
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.create").annotate(OpenApi.Summary, "Create a mailbox").annotate(OpenApi.Description, "Creates a mailbox with one endpoint and returns it with status 201; the caller gets an admin grant on it. Email is the channel a mailbox endpoint uses today; another channel is refused (422). An email endpoint's address must be under the organization's Samva-hosted mail domain or a verified domain with receiving enabled, and the mailbox sends from it. The slug defaults to the address's local part. Pass `slug` when that is taken or not a valid slug. The mailbox receives mail from now on; mail that arrived earlier is not added to it. Conflicts if the address or slug is already in use. Returns 402 when the organization is at its plan's mailbox allowance or at its mailbox storage allowance; incoming mail is still received past the storage allowance."), HttpApiEndpoint.get("mailboxesGet", "/v1/mailboxes/:id", {
|
|
11911
11957
|
params: MailboxesGetPathParams,
|
|
11912
11958
|
success: MailboxesGet200,
|
|
11913
11959
|
error: [
|
|
@@ -11918,7 +11964,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
11918
11964
|
MailboxesGet500,
|
|
11919
11965
|
MailboxesGet504.pipe(HttpApiSchema.status(504))
|
|
11920
11966
|
]
|
|
11921
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.get").annotate(OpenApi.Summary, "Get a mailbox").annotate(OpenApi.Description, "Returns a mailbox with its
|
|
11967
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.get").annotate(OpenApi.Summary, "Get a mailbox").annotate(OpenApi.Description, "Returns a mailbox with its endpoints and metadata; each endpoint says whether it is the mailbox's default on its channel. Its grants are `GET /v1/mailboxes/{id}/grants` and its send policies `GET /v1/mailboxes/{id}/policies`."), HttpApiEndpoint.delete("mailboxesRemove", "/v1/mailboxes/:id", {
|
|
11922
11968
|
params: MailboxesRemovePathParams,
|
|
11923
11969
|
success: MailboxesRemove200,
|
|
11924
11970
|
error: [
|
|
@@ -11930,7 +11976,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
11930
11976
|
MailboxesRemove502.pipe(HttpApiSchema.status(502)),
|
|
11931
11977
|
MailboxesRemove504.pipe(HttpApiSchema.status(504))
|
|
11932
11978
|
]
|
|
11933
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.remove").annotate(OpenApi.Summary, "Delete a mailbox").annotate(OpenApi.Description, "Deletes a mailbox with its
|
|
11979
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.remove").annotate(OpenApi.Summary, "Delete a mailbox").annotate(OpenApi.Description, "Deletes a mailbox with its endpoints, threads, drafts, and history. The messages it received stay with the organization. The mailbox leaves every API key scope and webhook endpoint filter that named it; a key or endpoint left with no mailbox is disabled."), HttpApiEndpoint.patch("mailboxesUpdate", "/v1/mailboxes/:id", {
|
|
11934
11980
|
params: MailboxesUpdatePathParams,
|
|
11935
11981
|
payload: MailboxesUpdateRequestJson,
|
|
11936
11982
|
success: MailboxesUpdate200,
|
|
@@ -11942,7 +11988,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
11942
11988
|
MailboxesUpdate500,
|
|
11943
11989
|
MailboxesUpdate504.pipe(HttpApiSchema.status(504))
|
|
11944
11990
|
]
|
|
11945
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.update").annotate(OpenApi.Summary, "Update a mailbox").annotate(OpenApi.Description, "Updates the fields you name and keeps the rest. `metadata` merges into the stored metadata by key, and a `null` value deletes that key.
|
|
11991
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.update").annotate(OpenApi.Summary, "Update a mailbox").annotate(OpenApi.Description, "Updates the fields you name and keeps the rest. `metadata` merges into the stored metadata by key, and a `null` value deletes that key. Change an endpoint's sender name or default with `PATCH /v1/mailboxes/{id}/endpoints/{endpointId}`."), HttpApiEndpoint.get("mailboxesListActions", "/v1/mailboxes/:id/actions", {
|
|
11946
11992
|
params: MailboxesListActionsPathParams,
|
|
11947
11993
|
query: MailboxesListActionsQuery,
|
|
11948
11994
|
success: MailboxesListActions200,
|
|
@@ -12026,31 +12072,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12026
12072
|
MailboxesRetryAction503.pipe(HttpApiSchema.status(503)),
|
|
12027
12073
|
MailboxesRetryAction504.pipe(HttpApiSchema.status(504))
|
|
12028
12074
|
]
|
|
12029
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.retryAction").annotate(OpenApi.Summary, "Resume a mailbox send").annotate(OpenApi.Description, "Resumes the same action only after its previous execution is confirmed ended and safe continuation is possible. Only an authorized person who proposed the send or can approve actions may retry. Automatic waits need no manual Retry. This does not grant new approval, reset the original deadline, replace the message identity, or resubmit an accepted or uncertain send."), HttpApiEndpoint.
|
|
12030
|
-
params: MailboxesCreateAddressPathParams,
|
|
12031
|
-
payload: MailboxesCreateAddressRequestJson,
|
|
12032
|
-
success: MailboxesCreateAddress201.pipe(HttpApiSchema.status(201)),
|
|
12033
|
-
error: [
|
|
12034
|
-
MailboxesCreateAddress401.pipe(HttpApiSchema.status(401)),
|
|
12035
|
-
MailboxesCreateAddress403.pipe(HttpApiSchema.status(403)),
|
|
12036
|
-
MailboxesCreateAddress404.pipe(HttpApiSchema.status(404)),
|
|
12037
|
-
MailboxesCreateAddress409.pipe(HttpApiSchema.status(409)),
|
|
12038
|
-
MailboxesCreateAddress422.pipe(HttpApiSchema.status(422)),
|
|
12039
|
-
MailboxesCreateAddress500,
|
|
12040
|
-
MailboxesCreateAddress504.pipe(HttpApiSchema.status(504))
|
|
12041
|
-
]
|
|
12042
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.createAddress").annotate(OpenApi.Summary, "Add an address to a mailbox").annotate(OpenApi.Description, "Adds an address to a mailbox and returns the mailbox with status 201. The address follows the same rules as the address of a new mailbox: it must be under the organization's Samva-hosted mail domain or a verified domain with receiving enabled, and no mailbox may already hold it (409). Mail sent to it reaches the mailbox from now on; the mailbox keeps sending from its current default address until you change `defaultFrom`."), HttpApiEndpoint.delete("mailboxesRemoveAddress", "/v1/mailboxes/:id/addresses/:addressId", {
|
|
12043
|
-
params: MailboxesRemoveAddressPathParams,
|
|
12044
|
-
success: MailboxesRemoveAddress200,
|
|
12045
|
-
error: [
|
|
12046
|
-
MailboxesRemoveAddress401.pipe(HttpApiSchema.status(401)),
|
|
12047
|
-
MailboxesRemoveAddress403.pipe(HttpApiSchema.status(403)),
|
|
12048
|
-
MailboxesRemoveAddress404.pipe(HttpApiSchema.status(404)),
|
|
12049
|
-
MailboxesRemoveAddress422.pipe(HttpApiSchema.status(422)),
|
|
12050
|
-
MailboxesRemoveAddress500,
|
|
12051
|
-
MailboxesRemoveAddress504.pipe(HttpApiSchema.status(504))
|
|
12052
|
-
]
|
|
12053
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.removeAddress").annotate(OpenApi.Summary, "Remove an address from a mailbox").annotate(OpenApi.Description, "Removes an address from a mailbox and returns the mailbox. Mail sent to the address stops reaching the mailbox; its existing threads and messages stay. A mailbox keeps at least one address, so removing the last one is refused (422). When the removed address was the default `From`, the mailbox sends from its oldest remaining address, without a sender name of its own."), HttpApiEndpoint.get("mailboxesGetAgentActivity", "/v1/mailboxes/:id/agent-activity", {
|
|
12075
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.retryAction").annotate(OpenApi.Summary, "Resume a mailbox send").annotate(OpenApi.Description, "Resumes the same action only after its previous execution is confirmed ended and safe continuation is possible. Only an authorized person who proposed the send or can approve actions may retry. Automatic waits need no manual Retry. This does not grant new approval, reset the original deadline, replace the message identity, or resubmit an accepted or uncertain send."), HttpApiEndpoint.get("mailboxesGetAgentActivity", "/v1/mailboxes/:id/agent-activity", {
|
|
12054
12076
|
params: MailboxesGetAgentActivityPathParams,
|
|
12055
12077
|
query: MailboxesGetAgentActivityQuery,
|
|
12056
12078
|
success: MailboxesGetAgentActivity200,
|
|
@@ -12086,7 +12108,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12086
12108
|
MailboxesCreateDraft500,
|
|
12087
12109
|
MailboxesCreateDraft504.pipe(HttpApiSchema.status(504))
|
|
12088
12110
|
]
|
|
12089
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.createDraft").annotate(OpenApi.Summary, "Create a draft").annotate(OpenApi.Description, "Saves a draft of a new message, or of a reply when `inReplyToMessageId` names a message in the mailbox, and returns it with status 201. Send it with `POST /v1/mailboxes/{id}/drafts/{draftId}/send`."), HttpApiEndpoint.get("mailboxesGetDraft", "/v1/mailboxes/:id/drafts/:draftId", {
|
|
12111
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.createDraft").annotate(OpenApi.Summary, "Create a draft").annotate(OpenApi.Description, "Saves a draft of a new message, or of a reply when `inReplyToMessageId` names a message in the mailbox, and returns it with status 201. Email drafts are the kind a mailbox saves today; another channel is refused (422). Send it with `POST /v1/mailboxes/{id}/drafts/{draftId}/send`."), HttpApiEndpoint.get("mailboxesGetDraft", "/v1/mailboxes/:id/drafts/:draftId", {
|
|
12090
12112
|
params: MailboxesGetDraftPathParams,
|
|
12091
12113
|
success: MailboxesGetDraft200,
|
|
12092
12114
|
error: [
|
|
@@ -12138,7 +12160,43 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12138
12160
|
MailboxesSendDraft503.pipe(HttpApiSchema.status(503)),
|
|
12139
12161
|
MailboxesSendDraft504.pipe(HttpApiSchema.status(504))
|
|
12140
12162
|
]
|
|
12141
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.sendDraft").annotate(OpenApi.Summary, "Send a draft").annotate(OpenApi.Description, "Sends one of the caller's drafts: a reply draft in its thread, any other draft as a new conversation. A draft needs recipients, a subject, and a body."), HttpApiEndpoint.
|
|
12163
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.sendDraft").annotate(OpenApi.Summary, "Send a draft").annotate(OpenApi.Description, "Sends one of the caller's drafts: a reply draft in its thread, any other draft as a new conversation. A draft needs recipients, a subject, and a body."), HttpApiEndpoint.post("mailboxesCreateEndpoint", "/v1/mailboxes/:id/endpoints", {
|
|
12164
|
+
params: MailboxesCreateEndpointPathParams,
|
|
12165
|
+
payload: MailboxesCreateEndpointRequestJson,
|
|
12166
|
+
success: MailboxesCreateEndpoint201.pipe(HttpApiSchema.status(201)),
|
|
12167
|
+
error: [
|
|
12168
|
+
MailboxesCreateEndpoint401.pipe(HttpApiSchema.status(401)),
|
|
12169
|
+
MailboxesCreateEndpoint403.pipe(HttpApiSchema.status(403)),
|
|
12170
|
+
MailboxesCreateEndpoint404.pipe(HttpApiSchema.status(404)),
|
|
12171
|
+
MailboxesCreateEndpoint409.pipe(HttpApiSchema.status(409)),
|
|
12172
|
+
MailboxesCreateEndpoint422.pipe(HttpApiSchema.status(422)),
|
|
12173
|
+
MailboxesCreateEndpoint500,
|
|
12174
|
+
MailboxesCreateEndpoint504.pipe(HttpApiSchema.status(504))
|
|
12175
|
+
]
|
|
12176
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.createEndpoint").annotate(OpenApi.Summary, "Add an endpoint to a mailbox").annotate(OpenApi.Description, "Adds an endpoint to a mailbox and returns the mailbox with status 201. It follows the same rules as the endpoint of a new mailbox: email is the channel a mailbox endpoint uses today (422 otherwise), the address must be under the organization's Samva-hosted mail domain or a verified domain with receiving enabled, and no mailbox may already hold it (409). Messages sent to it reach the mailbox from now on. It becomes the default on its channel only when the mailbox has no endpoint there yet."), HttpApiEndpoint.delete("mailboxesRemoveEndpoint", "/v1/mailboxes/:id/endpoints/:endpointId", {
|
|
12177
|
+
params: MailboxesRemoveEndpointPathParams,
|
|
12178
|
+
success: MailboxesRemoveEndpoint200,
|
|
12179
|
+
error: [
|
|
12180
|
+
MailboxesRemoveEndpoint401.pipe(HttpApiSchema.status(401)),
|
|
12181
|
+
MailboxesRemoveEndpoint403.pipe(HttpApiSchema.status(403)),
|
|
12182
|
+
MailboxesRemoveEndpoint404.pipe(HttpApiSchema.status(404)),
|
|
12183
|
+
MailboxesRemoveEndpoint422.pipe(HttpApiSchema.status(422)),
|
|
12184
|
+
MailboxesRemoveEndpoint500,
|
|
12185
|
+
MailboxesRemoveEndpoint504.pipe(HttpApiSchema.status(504))
|
|
12186
|
+
]
|
|
12187
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.removeEndpoint").annotate(OpenApi.Summary, "Remove an endpoint from a mailbox").annotate(OpenApi.Description, "Removes an endpoint from a mailbox and returns the mailbox. Messages sent to it stop reaching the mailbox; its existing threads and messages stay, and replies in them leave from the mailbox's default endpoint on their channel. A mailbox keeps at least one endpoint, so removing the last one is refused (422). When the removed endpoint was the default on its channel, the oldest remaining endpoint there becomes the default."), HttpApiEndpoint.patch("mailboxesUpdateEndpoint", "/v1/mailboxes/:id/endpoints/:endpointId", {
|
|
12188
|
+
params: MailboxesUpdateEndpointPathParams,
|
|
12189
|
+
payload: MailboxesUpdateEndpointRequestJson,
|
|
12190
|
+
success: MailboxesUpdateEndpoint200,
|
|
12191
|
+
error: [
|
|
12192
|
+
MailboxesUpdateEndpoint401.pipe(HttpApiSchema.status(401)),
|
|
12193
|
+
MailboxesUpdateEndpoint403.pipe(HttpApiSchema.status(403)),
|
|
12194
|
+
MailboxesUpdateEndpoint404.pipe(HttpApiSchema.status(404)),
|
|
12195
|
+
MailboxesUpdateEndpoint422.pipe(HttpApiSchema.status(422)),
|
|
12196
|
+
MailboxesUpdateEndpoint500,
|
|
12197
|
+
MailboxesUpdateEndpoint504.pipe(HttpApiSchema.status(504))
|
|
12198
|
+
]
|
|
12199
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.updateEndpoint").annotate(OpenApi.Summary, "Update a mailbox endpoint").annotate(OpenApi.Description, "Updates the fields you name and keeps the rest, and returns the mailbox. `displayName` is the name messages sent from the endpoint carry; null falls back to the mailbox's name. `default: true` makes the endpoint the one the mailbox starts new conversations from on its channel; replies always leave from the endpoint of their thread."), HttpApiEndpoint.get("mailboxesListEvents", "/v1/mailboxes/:id/events", {
|
|
12142
12200
|
params: MailboxesListEventsPathParams,
|
|
12143
12201
|
query: MailboxesListEventsQuery,
|
|
12144
12202
|
success: MailboxesListEvents200,
|
|
@@ -12150,7 +12208,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12150
12208
|
MailboxesListEvents500,
|
|
12151
12209
|
MailboxesListEvents504.pipe(HttpApiSchema.status(504))
|
|
12152
12210
|
]
|
|
12153
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.listEvents").annotate(OpenApi.Summary, "List mailbox events").annotate(OpenApi.Description, "Returns mailbox audit records, newest first, filterable by when they happened (`after`, `before`). Audit event types: `mailbox.created`, `
|
|
12211
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.listEvents").annotate(OpenApi.Summary, "List mailbox events").annotate(OpenApi.Description, "Returns mailbox audit records, newest first, filterable by when they happened (`after`, `before`). Audit event types: `mailbox.created`, `endpoint.attached`, `endpoint.detached`, `message.received`, `message.released`, `message.sent`, `thread.created`, `action.proposed`, `action.policy_decided`, `action.approval_requested`, `action.approval_resolved`, `action.accepted`, `action.executed`, `action.failed`. Thread and draft changes have no dedicated audit event types. Pass `nextCursor` back as `cursor` for the next page; it is null on the last page."), HttpApiEndpoint.get("mailboxesListFolders", "/v1/mailboxes/:id/folders", {
|
|
12154
12212
|
params: MailboxesListFoldersPathParams,
|
|
12155
12213
|
success: MailboxesListFolders200,
|
|
12156
12214
|
error: [
|
|
@@ -12276,7 +12334,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12276
12334
|
MailboxesSendMessage503.pipe(HttpApiSchema.status(503)),
|
|
12277
12335
|
MailboxesSendMessage504.pipe(HttpApiSchema.status(504))
|
|
12278
12336
|
]
|
|
12279
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.sendMessage").annotate(OpenApi.Summary, "Send a new message").annotate(OpenApi.Description, "Records a send action and returns 202 with its current receipt and a Location for action status. An installation, grant, or policy may require approval; otherwise the send is queued. Observe the same action through acceptance and mailbox completion. A policy refusal returns 403 with the recorded receipt."), HttpApiEndpoint.get("mailboxesGetMessage", "/v1/mailboxes/:id/messages/:messageId", {
|
|
12337
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.sendMessage").annotate(OpenApi.Summary, "Send a new message").annotate(OpenApi.Description, "Starts a new conversation from the mailbox's default endpoint on the channel the body names (email when omitted); a channel the mailbox cannot send on yet is refused (422). Records a send action and returns 202 with its current receipt and a Location for action status. An installation, grant, or policy may require approval; otherwise the send is queued. Observe the same action through acceptance and mailbox completion. A policy refusal returns 403 with the recorded receipt."), HttpApiEndpoint.get("mailboxesGetMessage", "/v1/mailboxes/:id/messages/:messageId", {
|
|
12280
12338
|
params: MailboxesGetMessagePathParams,
|
|
12281
12339
|
success: MailboxesGetMessage200,
|
|
12282
12340
|
error: [
|
|
@@ -12287,7 +12345,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12287
12345
|
MailboxesGetMessage500,
|
|
12288
12346
|
MailboxesGetMessage504.pipe(HttpApiSchema.status(504))
|
|
12289
12347
|
]
|
|
12290
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.getMessage").annotate(OpenApi.Summary, "Get a mailbox message").annotate(OpenApi.Description, "Returns a message in the mailbox
|
|
12348
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.getMessage").annotate(OpenApi.Summary, "Get a mailbox message").annotate(OpenApi.Description, "Returns a message in the mailbox, discriminated by `channel`. An email has its text, sanitized HTML, `replyText` (what the sender wrote, without quoted history), authentication verdicts, and attachments."), HttpApiEndpoint.get("mailboxesGetMessageAttachment", "/v1/mailboxes/:id/messages/:messageId/attachments/:attachmentId", {
|
|
12291
12349
|
params: MailboxesGetMessageAttachmentPathParams,
|
|
12292
12350
|
success: MailboxesGetMessageAttachment200,
|
|
12293
12351
|
error: [
|
|
@@ -12341,7 +12399,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12341
12399
|
MailboxesForward503.pipe(HttpApiSchema.status(503)),
|
|
12342
12400
|
MailboxesForward504.pipe(HttpApiSchema.status(504))
|
|
12343
12401
|
]
|
|
12344
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.forward").annotate(OpenApi.Summary, "Forward a message").annotate(OpenApi.Description, "Forwards
|
|
12402
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.forward").annotate(OpenApi.Summary, "Forward a message").annotate(OpenApi.Description, "Forwards an email to new recipients as a new conversation from the thread's endpoint, with the original quoted below the caller's text and its attachments attached ahead of any the caller adds. The combined attachments must fit the email attachment limits."), HttpApiEndpoint.get("mailboxesGetMessageRaw", "/v1/mailboxes/:id/messages/:messageId/raw", {
|
|
12345
12403
|
params: MailboxesGetMessageRawPathParams,
|
|
12346
12404
|
success: MailboxesGetMessageRaw200,
|
|
12347
12405
|
error: [
|
|
@@ -12382,7 +12440,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12382
12440
|
MailboxesReply503.pipe(HttpApiSchema.status(503)),
|
|
12383
12441
|
MailboxesReply504.pipe(HttpApiSchema.status(504))
|
|
12384
12442
|
]
|
|
12385
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.reply").annotate(OpenApi.Summary, "Reply to a message").annotate(OpenApi.Description, "Replies to the message's Reply-To address, or its sender, in the same thread. The server sets the recipients, subject, and threading headers."), HttpApiEndpoint.post("mailboxesReplyAll", "/v1/mailboxes/:id/messages/:messageId/reply-all", {
|
|
12443
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.reply").annotate(OpenApi.Summary, "Reply to a message").annotate(OpenApi.Description, "Replies to the message's Reply-To address, or its sender, in the same thread and from the thread's endpoint. The server sets the recipients, subject, and threading headers. The body's `channel` must match the thread's."), HttpApiEndpoint.post("mailboxesReplyAll", "/v1/mailboxes/:id/messages/:messageId/reply-all", {
|
|
12386
12444
|
params: MailboxesReplyAllPathParams,
|
|
12387
12445
|
headers: MailboxesReplyAllHeaders,
|
|
12388
12446
|
payload: MailboxesReplyAllRequestJson,
|
|
@@ -12400,7 +12458,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12400
12458
|
MailboxesReplyAll503.pipe(HttpApiSchema.status(503)),
|
|
12401
12459
|
MailboxesReplyAll504.pipe(HttpApiSchema.status(504))
|
|
12402
12460
|
]
|
|
12403
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.replyAll").annotate(OpenApi.Summary, "Reply to all recipients of a message").annotate(OpenApi.Description, "Replies to the sender and every other recipient of the message except the mailbox itself, in the same thread."), HttpApiEndpoint.post("mailboxesPause", "/v1/mailboxes/:id/pause", {
|
|
12461
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.replyAll").annotate(OpenApi.Summary, "Reply to all recipients of a message").annotate(OpenApi.Description, "Replies to the sender and every other recipient of the message except the mailbox itself, in the same thread and from the thread's endpoint."), HttpApiEndpoint.post("mailboxesPause", "/v1/mailboxes/:id/pause", {
|
|
12404
12462
|
params: MailboxesPausePathParams,
|
|
12405
12463
|
success: MailboxesPause200,
|
|
12406
12464
|
error: [
|
|
@@ -12622,7 +12680,7 @@ var MailboxesGroup = class extends HttpApiGroup.make("Mailboxes").add(HttpApiEnd
|
|
|
12622
12680
|
MailboxesUpdateNote500,
|
|
12623
12681
|
MailboxesUpdateNote504.pipe(HttpApiSchema.status(504))
|
|
12624
12682
|
]
|
|
12625
|
-
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.updateNote").annotate(OpenApi.Summary, "Update a mailbox note").annotate(OpenApi.Description, "Updates the fields you name and keeps the rest. Only the note's author may.")).annotate(OpenApi.Description, "Mailboxes:
|
|
12683
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "mailboxes.updateNote").annotate(OpenApi.Summary, "Update a mailbox note").annotate(OpenApi.Description, "Updates the fields you name and keeps the rest. Only the note's author may.")).annotate(OpenApi.Description, "Mailboxes: endpoints, threads, messages, drafts, and governed sends") {};
|
|
12626
12684
|
var MediaGroup = class extends HttpApiGroup.make("Media").add(HttpApiEndpoint.post("mediaCreate", "/v1/media", {
|
|
12627
12685
|
payload: MediaCreateRequestJson,
|
|
12628
12686
|
success: MediaCreate201.pipe(HttpApiSchema.status(201)),
|
|
@@ -13667,7 +13725,17 @@ var WebhooksGroup = class extends HttpApiGroup.make("Webhooks").add(HttpApiEndpo
|
|
|
13667
13725
|
WebhooksTest504.pipe(HttpApiSchema.status(504))
|
|
13668
13726
|
]
|
|
13669
13727
|
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "webhooks.test").annotate(OpenApi.Summary, "Send a test webhook delivery").annotate(OpenApi.Description, "Queues a signed webhook.test event through the normal delivery and retry lifecycle.")).annotate(OpenApi.Description, "Customer event webhook management, testing, and delivery logs") {};
|
|
13670
|
-
var
|
|
13728
|
+
var WhoamiGroup = class extends HttpApiGroup.make("Whoami").add(HttpApiEndpoint.get("whoamiGet", "/v1/whoami", {
|
|
13729
|
+
success: WhoamiGet200,
|
|
13730
|
+
error: [
|
|
13731
|
+
WhoamiGet401.pipe(HttpApiSchema.status(401)),
|
|
13732
|
+
WhoamiGet403.pipe(HttpApiSchema.status(403)),
|
|
13733
|
+
WhoamiGet422.pipe(HttpApiSchema.status(422)),
|
|
13734
|
+
WhoamiGet500,
|
|
13735
|
+
WhoamiGet504.pipe(HttpApiSchema.status(504))
|
|
13736
|
+
]
|
|
13737
|
+
}).middleware(ApiKeySecurityMiddleware).annotate(OpenApi.Identifier, "whoami.get").annotate(OpenApi.Summary, "Get the calling credential").annotate(OpenApi.Description, "Returns the organization the request acts in and the credential it presents: an API key with its name, prefix, and access, or a signed-in user with their role. Any valid credential may call it, whatever its grants.")).annotate(OpenApi.Description, "The organization and credential behind the request.") {};
|
|
13738
|
+
var SamvaApi = class extends HttpApi.make("SamvaApi").annotate(OpenApi.Title, "Samva API").annotate(OpenApi.Version, "1.0.0").annotate(OpenApi.Description, "Samva is the email API for your app. Send transactional email in one typed call. Delivery events and customer replies come back as signed webhooks, and replies thread to the email they answer.").annotate(OpenApi.Servers, [{ url: "https://api.samva.dev" }]).add(AnalyticsGroup, APIKeysGroup, AttachmentsGroup, BrandsGroup, CampaignsGroup, ContactGroupsGroup, ContactsGroup, ConversationsGroup, CustomFieldsGroup, EmailGroup, ExtensionInstallationsGroup, ExtensionsGroup, FeedbackGroup, MailboxesGroup, MediaGroup, MessagesGroup, ScheduledMessagesGroup, NamespacesGroup, OperationsGroup, OrganizationsGroup, SubscriptionsGroup, TemplatesGroup, UnsubscribeGroupsGroup, WebhooksGroup, WhoamiGroup) {};
|
|
13671
13739
|
//#endregion
|
|
13672
13740
|
//#region src/effect/internal/client.ts
|
|
13673
13741
|
const DEFAULT_BASE_URL = "https://api.samva.dev";
|
|
@@ -13721,6 +13789,6 @@ const layer = (config) => Layer.effect(Service, make(config));
|
|
|
13721
13789
|
const layerFetch = (config) => layer(config).pipe(Layer.provide(FetchHttpClient.layer));
|
|
13722
13790
|
const raw = Effect.map(Service, (client) => client.raw);
|
|
13723
13791
|
//#endregion
|
|
13724
|
-
export {
|
|
13792
|
+
export { SendFeedback as A, MailboxSendConflictError as C, RateLimitedError as D, PaymentRequiredError as E, UpdateBrand as F, UpdateTemplatePayload as I, UpdateWebhookPayload as L, TestWebhookPayload as M, TrackingRecipientEmail as N, ResourceNotFoundError as O, UnauthorizedError as P, ValidationError as R, MailboxChannelUnsupportedError as S, OnboardingReviewRequiredError as T, ExternalServiceError as _, AnalyticsQueryError as a, GatewayTimeoutError as b, BillingProviderError as c, ConflictError as d, CreateBrand as f, EmailChannelError as g, DeliveryUnavailableError as h, raw as i, SenderNotReadyError as j, SamvaApi as k, BrandAddressRequiredError as l, CreateWebhookPayload as m, layer as n, ApiKeysCreateRequestJson as o, CreateTemplatePayload as p, layerFetch as r, ApiKeysUpdateRequestJson as s, Service as t, CampaignFooterRequiredError as u, FlagDisabledError as v, MailboxSendRefusedError as w, InternalError as x, ForbiddenError as y };
|
|
13725
13793
|
|
|
13726
|
-
//# sourceMappingURL=client-
|
|
13794
|
+
//# sourceMappingURL=client-BMUew5Wp.js.map
|