@serve.zone/interfaces 20.1.0 → 20.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/changelog.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # Changelog
2
2
 
3
+ ## 2026-07-29 - 20.2.0
4
+
5
+ ### Features
6
+
7
+ - add CoreMail data and request contracts (coremail)
8
+ - Export CoreMail shared data models, transfer grants, desired-state structures, reconciliation status, and limits
9
+ - Add CoreMail TypedRequest interfaces for workload authentication, outbound submissions, inbound delivery handling, reconciliation, and gateway handoffs
10
+ - Document CoreMail authority, transfer, and desired-state constraints with contract coverage
11
+ - Bump @api.global/typedrequest-interfaces to ^4.0.0
12
+
3
13
  ## 2026-07-29 - 20.1.0
4
14
 
5
15
  ### Features
@@ -3,7 +3,7 @@
3
3
  */
4
4
  export const commitinfo = {
5
5
  name: '@serve.zone/interfaces',
6
- version: '20.1.0',
6
+ version: '20.2.0',
7
7
  description: 'Shared TypeScript interfaces and TypedRequest contracts for the serve.zone ecosystem.'
8
8
  };
9
9
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMDBfY29tbWl0aW5mb19kYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvMDBfY29tbWl0aW5mb19kYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0sVUFBVSxHQUFHO0lBQ3hCLElBQUksRUFBRSx3QkFBd0I7SUFDOUIsT0FBTyxFQUFFLFFBQVE7SUFDakIsV0FBVyxFQUFFLHVGQUF1RjtDQUNyRyxDQUFBIn0=
@@ -0,0 +1,216 @@
1
+ /**
2
+ * Shared CoreMail contracts.
3
+ *
4
+ * Workload authority is always derived from an authenticated transport
5
+ * session. Application-facing request DTOs therefore carry message or
6
+ * delivery identifiers only and never caller-selected tenant, service, or
7
+ * binding authority.
8
+ */
9
+ export type TCoreMailSha256 = `sha256:${string}`;
10
+ export type TCoreMailCapability = 'outbound' | 'inbound';
11
+ export type TCoreMailBindingState = 'active' | 'disabled';
12
+ export type TCoreMailCredentialState = 'current' | 'retiring';
13
+ export type TCoreMailPartKind = 'text' | 'html' | 'attachment';
14
+ export type TCoreMailTransferMethod = 'PUT' | 'GET';
15
+ export type TCoreMailSubmissionState = 'preparing' | 'uploading' | 'ready' | 'accepted' | 'queued' | 'delivering' | 'delivered' | 'deferred' | 'failed' | 'deadLettered';
16
+ export type TCoreMailInboundDeliveryState = 'pending' | 'fetching' | 'fetched' | 'acknowledged';
17
+ export type TCoreMailInboundAckOutcome = 'processed' | 'discarded';
18
+ export type TCoreMailRecipientAction = 'accept' | 'reject' | 'defer';
19
+ export type TCoreMailReconciliationState = 'applying' | 'ready' | 'failed';
20
+ export type TCoreMailErrorCode = 'AUTHENTICATION_FAILED' | 'AUTHENTICATION_EXPIRED' | 'AUTHORITY_REVOKED' | 'CAPABILITY_DENIED' | 'NOT_FOUND' | 'INVALID_REQUEST' | 'INVALID_MAILBOX' | 'INVALID_SENDER' | 'INVALID_RECIPIENT' | 'INVALID_HEADER' | 'PAYLOAD_LIMIT_EXCEEDED' | 'IDEMPOTENCY_CONFLICT' | 'STATE_CONFLICT' | 'TRANSFER_GRANT_EXPIRED' | 'TRANSFER_GRANT_REPLAYED' | 'TRANSFER_LENGTH_MISMATCH' | 'TRANSFER_DIGEST_MISMATCH' | 'TRANSFER_ENCODING_UNSUPPORTED' | 'OBJECT_INTEGRITY_CONFLICT' | 'DELIVERY_NOT_FETCHED' | 'GATEWAY_UNAVAILABLE' | 'RECONCILIATION_FENCE_MISMATCH';
21
+ export interface ICoreMailErrorData {
22
+ code: TCoreMailErrorCode;
23
+ retryable: boolean;
24
+ retryAfterMs?: number;
25
+ }
26
+ export interface ICoreMailMailbox {
27
+ address: string;
28
+ displayName?: string;
29
+ }
30
+ export interface ICoreMailEnvelope {
31
+ mailFrom: string;
32
+ rcptTo: string[];
33
+ }
34
+ export interface ICoreMailHeader {
35
+ name: string;
36
+ value: string;
37
+ }
38
+ export interface ICoreMailContentDescriptor {
39
+ partId: string;
40
+ kind: TCoreMailPartKind;
41
+ contentType: string;
42
+ filename?: string;
43
+ contentId?: string;
44
+ sha256: TCoreMailSha256;
45
+ lengthBytes: number;
46
+ }
47
+ export interface ICoreMailOutboundMessageDescriptor {
48
+ sender: ICoreMailMailbox;
49
+ recipients: {
50
+ to: ICoreMailMailbox[];
51
+ cc?: ICoreMailMailbox[];
52
+ bcc?: ICoreMailMailbox[];
53
+ };
54
+ replyTo?: ICoreMailMailbox;
55
+ subject: string;
56
+ /** Ordered headers. Transport-owned MIME headers are not accepted here. */
57
+ headers?: ICoreMailHeader[];
58
+ /** Ordered body and attachment descriptors. Bytes move through bounded HTTP transfers. */
59
+ parts: ICoreMailContentDescriptor[];
60
+ }
61
+ export interface ICoreMailTransferGrant {
62
+ grantId: string;
63
+ method: TCoreMailTransferMethod;
64
+ /** Same-origin path. Callers use the authenticated CoreMail or gateway endpoint they already hold. */
65
+ path: string;
66
+ /** One-time bearer capability. It must never be logged or persisted by a consumer. */
67
+ bearerToken: string;
68
+ sha256: TCoreMailSha256;
69
+ lengthBytes: number;
70
+ contentType: string;
71
+ expiresAt: number;
72
+ }
73
+ export interface ICoreMailUploadGrant extends ICoreMailTransferGrant {
74
+ method: 'PUT';
75
+ }
76
+ export interface ICoreMailDownloadGrant extends ICoreMailTransferGrant {
77
+ method: 'GET';
78
+ }
79
+ export interface ICoreMailPartStatus {
80
+ partId: string;
81
+ state: 'missing' | 'uploading' | 'complete' | 'failed';
82
+ sha256: TCoreMailSha256;
83
+ lengthBytes: number;
84
+ }
85
+ export interface ICoreMailSubmission {
86
+ submissionId: string;
87
+ idempotencyKey: string;
88
+ submissionDigest: TCoreMailSha256;
89
+ state: TCoreMailSubmissionState;
90
+ parts: ICoreMailPartStatus[];
91
+ transportMessageId?: string;
92
+ attempts: number;
93
+ nextAttemptAt?: number;
94
+ acceptedAt?: number;
95
+ deliveredAt?: number;
96
+ createdAt: number;
97
+ updatedAt: number;
98
+ }
99
+ export interface ICoreMailInboundDelivery {
100
+ deliveryId: string;
101
+ transportDeliveryId: string;
102
+ state: TCoreMailInboundDeliveryState;
103
+ envelope: ICoreMailEnvelope;
104
+ rawMime: {
105
+ sha256: TCoreMailSha256;
106
+ lengthBytes: number;
107
+ contentType: 'message/rfc822';
108
+ };
109
+ messageId?: string;
110
+ subject?: string;
111
+ receivedAt: number;
112
+ updatedAt: number;
113
+ }
114
+ export interface ICoreMailBindingCredentialVerifier {
115
+ credentialId: string;
116
+ version: number;
117
+ state: TCoreMailCredentialState;
118
+ /** Password-verifier string only. Plaintext credential material is never part of desired state. */
119
+ verificationHash: string;
120
+ acceptUntil?: number;
121
+ }
122
+ export interface ICoreMailBindingDesiredState {
123
+ schemaVersion: 1;
124
+ bindingId: string;
125
+ serviceId: string;
126
+ tenantId: string;
127
+ revision: number;
128
+ state: TCoreMailBindingState;
129
+ capabilities: TCoreMailCapability[];
130
+ credentials: ICoreMailBindingCredentialVerifier[];
131
+ allowedSenders: string[];
132
+ inboundRecipients: string[];
133
+ defaultSender?: string;
134
+ limits?: {
135
+ messagesPerMinute?: number;
136
+ messagesPerDay?: number;
137
+ maxPendingInbound?: number;
138
+ };
139
+ }
140
+ export interface ICoreMailGatewayDesiredState {
141
+ endpointUrl: string;
142
+ credentialId: string;
143
+ credentialVersion: number;
144
+ /** Key in CoreMail's resolved runtime secret material, never a plaintext value. */
145
+ credentialSecretKey: string;
146
+ }
147
+ export interface ICoreMailDesiredState {
148
+ schemaVersion: 1;
149
+ configEpoch: number;
150
+ bindings: ICoreMailBindingDesiredState[];
151
+ gateway: ICoreMailGatewayDesiredState;
152
+ }
153
+ export interface ICoreMailReplicaIdentity {
154
+ taskId: string;
155
+ serviceId: string;
156
+ rolloutId: string;
157
+ rolloutGeneration: number;
158
+ imageDigest: TCoreMailSha256;
159
+ }
160
+ export interface ICoreMailBindingReconciliationStatus {
161
+ bindingId: string;
162
+ revision: number;
163
+ state: TCoreMailBindingState;
164
+ activeSessionsByCredentialVersion: Array<{
165
+ version: number;
166
+ count: number;
167
+ }>;
168
+ }
169
+ export interface ICoreMailReconciliationStatus {
170
+ replica: ICoreMailReplicaIdentity;
171
+ state: TCoreMailReconciliationState;
172
+ appliedConfigEpoch: number;
173
+ appliedDesiredStateDigest: TCoreMailSha256;
174
+ bindings: ICoreMailBindingReconciliationStatus[];
175
+ updatedAt: number;
176
+ errorCode?: TCoreMailErrorCode;
177
+ }
178
+ export interface ICoreMailRecipientResolution {
179
+ recipient: string;
180
+ action: TCoreMailRecipientAction;
181
+ /** Opaque, short-lived handle returned only for accepted recipients. */
182
+ routingHandle?: string;
183
+ smtpCode?: number;
184
+ message?: string;
185
+ }
186
+ export interface ICoreMailGatewayMessageDescriptor {
187
+ envelope: ICoreMailEnvelope;
188
+ rawMime: {
189
+ sha256: TCoreMailSha256;
190
+ lengthBytes: number;
191
+ contentType: 'message/rfc822';
192
+ };
193
+ }
194
+ export interface ICoreMailGatewayOutboundStatus {
195
+ transportMessageId: string;
196
+ state: Extract<TCoreMailSubmissionState, 'accepted' | 'queued' | 'delivering' | 'delivered' | 'deferred' | 'failed' | 'deadLettered'>;
197
+ attempts: number;
198
+ nextAttemptAt?: number;
199
+ smtpCode?: number;
200
+ updatedAt: number;
201
+ }
202
+ export declare const coreMailLimits: Readonly<{
203
+ readonly controlMessageBytes: number;
204
+ readonly desiredStateBytes: number;
205
+ readonly textPartBytes: number;
206
+ readonly htmlPartBytes: number;
207
+ readonly attachmentCount: 16;
208
+ readonly attachmentBytes: number;
209
+ readonly aggregateAttachmentBytes: number;
210
+ readonly mimeFramingBytes: number;
211
+ readonly serializedMimeBytes: number;
212
+ readonly transferGrantTtlMs: number;
213
+ readonly transferHeaderTimeoutMs: number;
214
+ readonly transferIdleTimeoutMs: number;
215
+ readonly transferOverallTimeoutMs: number;
216
+ }>;
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Shared CoreMail contracts.
3
+ *
4
+ * Workload authority is always derived from an authenticated transport
5
+ * session. Application-facing request DTOs therefore carry message or
6
+ * delivery identifiers only and never caller-selected tenant, service, or
7
+ * binding authority.
8
+ */
9
+ export const coreMailLimits = Object.freeze({
10
+ controlMessageBytes: 64 * 1024,
11
+ desiredStateBytes: 8 * 1024 * 1024,
12
+ textPartBytes: 1 * 1024 * 1024,
13
+ htmlPartBytes: 2 * 1024 * 1024,
14
+ attachmentCount: 16,
15
+ attachmentBytes: 10 * 1024 * 1024,
16
+ aggregateAttachmentBytes: 17 * 1024 * 1024,
17
+ mimeFramingBytes: 512 * 1024,
18
+ serializedMimeBytes: 30 * 1024 * 1024,
19
+ transferGrantTtlMs: 5 * 60 * 1000,
20
+ transferHeaderTimeoutMs: 10 * 1000,
21
+ transferIdleTimeoutMs: 15 * 1000,
22
+ transferOverallTimeoutMs: 2 * 60 * 1000,
23
+ });
24
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29yZW1haWwuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi90cy9kYXRhL2NvcmVtYWlsLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7Ozs7O0dBT0c7QUErUEgsTUFBTSxDQUFDLE1BQU0sY0FBYyxHQUFHLE1BQU0sQ0FBQyxNQUFNLENBQUM7SUFDMUMsbUJBQW1CLEVBQUUsRUFBRSxHQUFHLElBQUk7SUFDOUIsaUJBQWlCLEVBQUUsQ0FBQyxHQUFHLElBQUksR0FBRyxJQUFJO0lBQ2xDLGFBQWEsRUFBRSxDQUFDLEdBQUcsSUFBSSxHQUFHLElBQUk7SUFDOUIsYUFBYSxFQUFFLENBQUMsR0FBRyxJQUFJLEdBQUcsSUFBSTtJQUM5QixlQUFlLEVBQUUsRUFBRTtJQUNuQixlQUFlLEVBQUUsRUFBRSxHQUFHLElBQUksR0FBRyxJQUFJO0lBQ2pDLHdCQUF3QixFQUFFLEVBQUUsR0FBRyxJQUFJLEdBQUcsSUFBSTtJQUMxQyxnQkFBZ0IsRUFBRSxHQUFHLEdBQUcsSUFBSTtJQUM1QixtQkFBbUIsRUFBRSxFQUFFLEdBQUcsSUFBSSxHQUFHLElBQUk7SUFDckMsa0JBQWtCLEVBQUUsQ0FBQyxHQUFHLEVBQUUsR0FBRyxJQUFJO0lBQ2pDLHVCQUF1QixFQUFFLEVBQUUsR0FBRyxJQUFJO0lBQ2xDLHFCQUFxQixFQUFFLEVBQUUsR0FBRyxJQUFJO0lBQ2hDLHdCQUF3QixFQUFFLENBQUMsR0FBRyxFQUFFLEdBQUcsSUFBSTtDQUMvQixDQUFDLENBQUMifQ==
@@ -1,6 +1,7 @@
1
1
  export * from './cloudlyconfig.js';
2
2
  export * from './cluster.js';
3
3
  export * from './config.js';
4
+ export * from './coremail.js';
4
5
  export * from './deployment.js';
5
6
  export * from './deploymentadoption.js';
6
7
  export * from './deploymentoperation.js';
@@ -1,6 +1,7 @@
1
1
  export * from './cloudlyconfig.js';
2
2
  export * from './cluster.js';
3
3
  export * from './config.js';
4
+ export * from './coremail.js';
4
5
  export * from './deployment.js';
5
6
  export * from './deploymentadoption.js';
6
7
  export * from './deploymentoperation.js';
@@ -35,4 +36,4 @@ export * from './traffic.js';
35
36
  export * from './user.js';
36
37
  export * from './version.js';
37
38
  export * from './webpush.js';
38
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi90cy9kYXRhL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGNBQWMsb0JBQW9CLENBQUM7QUFDbkMsY0FBYyxjQUFjLENBQUM7QUFDN0IsY0FBYyxhQUFhLENBQUM7QUFDNUIsY0FBYyxpQkFBaUIsQ0FBQztBQUN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NUIsY0FBYyxvQkFBb0IsQ0FBQztBQUNuQyxjQUFjLGNBQWMsQ0FBQztBQUM3QixjQUFjLFdBQVcsQ0FBQztBQUMxQixjQUFjLGNBQWMsQ0FBQztBQUM3QixjQUFjLGNBQWMsQ0FBQyJ9
@@ -0,0 +1,248 @@
1
+ import type * as plugins from '../plugins.js';
2
+ import type { ICoreMailEnvelope, ICoreMailDownloadGrant, ICoreMailGatewayMessageDescriptor, ICoreMailGatewayOutboundStatus, ICoreMailInboundDelivery, ICoreMailOutboundMessageDescriptor, ICoreMailRecipientResolution, ICoreMailReconciliationStatus, ICoreMailReplicaIdentity, ICoreMailSubmission, ICoreMailUploadGrant, TCoreMailInboundAckOutcome, TCoreMailSha256 } from '../data/coremail.js';
3
+ import type { IMailConnectionInfo } from '../data/mail.js';
4
+ export interface IReq_CoreMailAuthenticateWorkload extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailAuthenticateWorkload> {
5
+ method: 'coreMailAuthenticateWorkload';
6
+ request: {
7
+ bindingId: string;
8
+ credentialId: string;
9
+ credentialVersion: number;
10
+ credentialSecret: string;
11
+ };
12
+ response: {
13
+ authenticated: true;
14
+ credentialVersion: number;
15
+ capabilities: Array<'outbound' | 'inbound'>;
16
+ };
17
+ }
18
+ export interface IReq_CoreMailPrepareOutboundSubmission extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailPrepareOutboundSubmission> {
19
+ method: 'coreMailPrepareOutboundSubmission';
20
+ request: {
21
+ /** Required replay key. Authority is added by the authenticated server session. */
22
+ idempotencyKey: string;
23
+ message: ICoreMailOutboundMessageDescriptor;
24
+ };
25
+ response: {
26
+ submission: ICoreMailSubmission;
27
+ replayed: boolean;
28
+ };
29
+ }
30
+ export interface IReq_CoreMailPrepareOutboundPartUpload extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailPrepareOutboundPartUpload> {
31
+ method: 'coreMailPrepareOutboundPartUpload';
32
+ request: {
33
+ submissionId: string;
34
+ partId: string;
35
+ };
36
+ response: {
37
+ grant: ICoreMailUploadGrant;
38
+ };
39
+ }
40
+ export interface IReq_CoreMailCompleteOutboundPartUpload extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailCompleteOutboundPartUpload> {
41
+ method: 'coreMailCompleteOutboundPartUpload';
42
+ request: {
43
+ submissionId: string;
44
+ partId: string;
45
+ grantId: string;
46
+ sha256: TCoreMailSha256;
47
+ lengthBytes: number;
48
+ };
49
+ response: {
50
+ submission: ICoreMailSubmission;
51
+ };
52
+ }
53
+ export interface IReq_CoreMailFinalizeOutboundSubmission extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailFinalizeOutboundSubmission> {
54
+ method: 'coreMailFinalizeOutboundSubmission';
55
+ request: {
56
+ submissionId: string;
57
+ };
58
+ response: {
59
+ submission: ICoreMailSubmission;
60
+ };
61
+ }
62
+ export interface IReq_CoreMailGetOutboundSubmission extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGetOutboundSubmission> {
63
+ method: 'coreMailGetOutboundSubmission';
64
+ request: {
65
+ submissionId: string;
66
+ };
67
+ response: {
68
+ submission: ICoreMailSubmission;
69
+ };
70
+ }
71
+ export interface IReq_CoreMailListInboundDeliveries extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailListInboundDeliveries> {
72
+ method: 'coreMailListInboundDeliveries';
73
+ request: {
74
+ afterDeliveryId?: string;
75
+ limit: number;
76
+ };
77
+ response: {
78
+ deliveries: ICoreMailInboundDelivery[];
79
+ };
80
+ }
81
+ export interface IReq_CoreMailPrepareInboundFetch extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailPrepareInboundFetch> {
82
+ method: 'coreMailPrepareInboundFetch';
83
+ request: {
84
+ deliveryId: string;
85
+ };
86
+ response: {
87
+ grant: ICoreMailDownloadGrant;
88
+ };
89
+ }
90
+ export interface IReq_CoreMailCompleteInboundFetch extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailCompleteInboundFetch> {
91
+ method: 'coreMailCompleteInboundFetch';
92
+ request: {
93
+ deliveryId: string;
94
+ grantId: string;
95
+ sha256: TCoreMailSha256;
96
+ lengthBytes: number;
97
+ };
98
+ response: {
99
+ delivery: ICoreMailInboundDelivery;
100
+ };
101
+ }
102
+ export interface IReq_CoreMailAcknowledgeInboundDelivery extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailAcknowledgeInboundDelivery> {
103
+ method: 'coreMailAcknowledgeInboundDelivery';
104
+ request: {
105
+ deliveryId: string;
106
+ outcome: TCoreMailInboundAckOutcome;
107
+ };
108
+ response: {
109
+ delivery: ICoreMailInboundDelivery;
110
+ replayed: boolean;
111
+ };
112
+ }
113
+ export interface IReq_CoreMailAuthenticateControl extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailAuthenticateControl> {
114
+ method: 'coreMailAuthenticateControl';
115
+ request: {
116
+ credentialId: string;
117
+ credentialVersion: number;
118
+ credentialSecret: string;
119
+ };
120
+ response: {
121
+ authenticated: true;
122
+ replica: ICoreMailReplicaIdentity;
123
+ };
124
+ }
125
+ export interface IReq_CoreMailPrepareDesiredStateUpload extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailPrepareDesiredStateUpload> {
126
+ method: 'coreMailPrepareDesiredStateUpload';
127
+ request: {
128
+ expectedAppliedConfigEpoch: number;
129
+ configEpoch: number;
130
+ desiredStateDigest: TCoreMailSha256;
131
+ lengthBytes: number;
132
+ };
133
+ response: {
134
+ reconciliationId: string;
135
+ grant: ICoreMailUploadGrant;
136
+ replayed: boolean;
137
+ };
138
+ }
139
+ export interface IReq_CoreMailApplyDesiredState extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailApplyDesiredState> {
140
+ method: 'coreMailApplyDesiredState';
141
+ request: {
142
+ reconciliationId: string;
143
+ grantId: string;
144
+ desiredStateDigest: TCoreMailSha256;
145
+ lengthBytes: number;
146
+ };
147
+ response: {
148
+ status: ICoreMailReconciliationStatus;
149
+ };
150
+ }
151
+ export interface IReq_CoreMailGetReconciliationStatus extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGetReconciliationStatus> {
152
+ method: 'coreMailGetReconciliationStatus';
153
+ request: {
154
+ configEpoch: number;
155
+ desiredStateDigest: TCoreMailSha256;
156
+ };
157
+ response: {
158
+ status: ICoreMailReconciliationStatus;
159
+ };
160
+ }
161
+ export interface IReq_CoreMailGatewayAuthenticate extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayAuthenticate> {
162
+ method: 'coreMailGatewayAuthenticate';
163
+ request: {
164
+ credentialId: string;
165
+ credentialVersion: number;
166
+ credentialSecret: string;
167
+ };
168
+ response: {
169
+ authenticated: true;
170
+ credentialVersion: number;
171
+ };
172
+ }
173
+ export interface IReq_CoreMailGatewayResolveRecipients extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayResolveRecipients> {
174
+ method: 'coreMailGatewayResolveRecipients';
175
+ request: {
176
+ envelope: ICoreMailEnvelope;
177
+ recipients: string[];
178
+ source: IMailConnectionInfo;
179
+ };
180
+ response: {
181
+ resolutions: ICoreMailRecipientResolution[];
182
+ };
183
+ }
184
+ export interface IReq_CoreMailGatewayPrepareInboundHandoff extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayPrepareInboundHandoff> {
185
+ method: 'coreMailGatewayPrepareInboundHandoff';
186
+ request: {
187
+ transportDeliveryId: string;
188
+ routingHandles: string[];
189
+ message: ICoreMailGatewayMessageDescriptor;
190
+ source: IMailConnectionInfo;
191
+ };
192
+ response: {
193
+ handoffId: string;
194
+ grant?: ICoreMailUploadGrant;
195
+ replayed: boolean;
196
+ };
197
+ }
198
+ export interface IReq_CoreMailGatewayCompleteInboundHandoff extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayCompleteInboundHandoff> {
199
+ method: 'coreMailGatewayCompleteInboundHandoff';
200
+ request: {
201
+ handoffId: string;
202
+ grantId: string;
203
+ sha256: TCoreMailSha256;
204
+ lengthBytes: number;
205
+ };
206
+ response: {
207
+ accepted: true;
208
+ deliveryIds: string[];
209
+ replayed: boolean;
210
+ };
211
+ }
212
+ export interface IReq_CoreMailGatewayPrepareOutboundHandoff extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayPrepareOutboundHandoff> {
213
+ method: 'coreMailGatewayPrepareOutboundHandoff';
214
+ request: {
215
+ transportSubmissionId: string;
216
+ submissionDigest: TCoreMailSha256;
217
+ message: ICoreMailGatewayMessageDescriptor;
218
+ /** CoreMail-issued GET grant. dcrouter resolves the path against the authenticated peer. */
219
+ grant: ICoreMailDownloadGrant;
220
+ };
221
+ response: {
222
+ transportMessageId: string;
223
+ status: ICoreMailGatewayOutboundStatus;
224
+ replayed: boolean;
225
+ };
226
+ }
227
+ export interface IReq_CoreMailGatewayCompleteOutboundHandoff extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayCompleteOutboundHandoff> {
228
+ method: 'coreMailGatewayCompleteOutboundHandoff';
229
+ request: {
230
+ transportMessageId: string;
231
+ grantId: string;
232
+ sha256: TCoreMailSha256;
233
+ lengthBytes: number;
234
+ };
235
+ response: {
236
+ status: ICoreMailGatewayOutboundStatus;
237
+ replayed: boolean;
238
+ };
239
+ }
240
+ export interface IReq_CoreMailGatewayGetOutboundStatus extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IReq_CoreMailGatewayGetOutboundStatus> {
241
+ method: 'coreMailGatewayGetOutboundStatus';
242
+ request: {
243
+ transportMessageId: string;
244
+ };
245
+ response: {
246
+ status: ICoreMailGatewayOutboundStatus;
247
+ };
248
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29yZW1haWwuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi90cy9yZXF1ZXN0cy9jb3JlbWFpbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIn0=
@@ -6,6 +6,7 @@ import * as backupRequests from './backup.js';
6
6
  import * as certificateRequests from './certificate.js';
7
7
  import * as clusterRequests from './cluster.js';
8
8
  import * as configRequests from './config.js';
9
+ import * as coreMailRequests from './coremail.js';
9
10
  import * as corestoreRequests from './corestore.js';
10
11
  import * as deploymentRequests from './deployment.js';
11
12
  import * as dnsRequests from './dns.js';
@@ -33,7 +34,7 @@ import * as statusRequests from './status.js';
33
34
  import * as taskRequests from './task.js';
34
35
  import * as versionRequests from './version.js';
35
36
  import * as webPushRequests from './webpush.js';
36
- export { adminRequests as admin, appStoreRequests as appstore, baremetalRequests as baremetal, baseOsRequests as baseos, backupRequests as backup, certificateRequests as certificate, clusterRequests as cluster, configRequests as config, corestoreRequests as corestore, deploymentRequests as deployment, dnsRequests as dns, domainRequests as domain, externalRegistryRequests as externalRegistry, gatewayRequests as gateway, hostedAppRequests as hostedapp, identityRequests as identity, imageRequests as image, informRequests as inform, logRequests as log, mailRequests as mail, migrationRequests as migration, networkRequests as network, nodeRequests as node, platformRequests as platform, routingRequests as routing, secretRequests as secret, secretBundleRequests as secretbundle, secretGroupRequests as secretgroup, serverRequests as server, serviceRequests as service, settingsRequests as settings, statusRequests as status, taskRequests as task, versionRequests as version, webPushRequests as webpush, };
37
+ export { adminRequests as admin, appStoreRequests as appstore, baremetalRequests as baremetal, baseOsRequests as baseos, backupRequests as backup, certificateRequests as certificate, clusterRequests as cluster, configRequests as config, coreMailRequests as coremail, corestoreRequests as corestore, deploymentRequests as deployment, dnsRequests as dns, domainRequests as domain, externalRegistryRequests as externalRegistry, gatewayRequests as gateway, hostedAppRequests as hostedapp, identityRequests as identity, imageRequests as image, informRequests as inform, logRequests as log, mailRequests as mail, migrationRequests as migration, networkRequests as network, nodeRequests as node, platformRequests as platform, routingRequests as routing, secretRequests as secret, secretBundleRequests as secretbundle, secretGroupRequests as secretgroup, serverRequests as server, serviceRequests as service, settingsRequests as settings, statusRequests as status, taskRequests as task, versionRequests as version, webPushRequests as webpush, };
37
38
  export * from './inform.js';
38
39
  export * from './hostedapp.js';
39
40
  export * from './mail.js';
@@ -7,6 +7,7 @@ import * as backupRequests from './backup.js';
7
7
  import * as certificateRequests from './certificate.js';
8
8
  import * as clusterRequests from './cluster.js';
9
9
  import * as configRequests from './config.js';
10
+ import * as coreMailRequests from './coremail.js';
10
11
  import * as corestoreRequests from './corestore.js';
11
12
  import * as deploymentRequests from './deployment.js';
12
13
  import * as dnsRequests from './dns.js';
@@ -34,9 +35,9 @@ import * as statusRequests from './status.js';
34
35
  import * as taskRequests from './task.js';
35
36
  import * as versionRequests from './version.js';
36
37
  import * as webPushRequests from './webpush.js';
37
- export { adminRequests as admin, appStoreRequests as appstore, baremetalRequests as baremetal, baseOsRequests as baseos, backupRequests as backup, certificateRequests as certificate, clusterRequests as cluster, configRequests as config, corestoreRequests as corestore, deploymentRequests as deployment, dnsRequests as dns, domainRequests as domain, externalRegistryRequests as externalRegistry, gatewayRequests as gateway, hostedAppRequests as hostedapp, identityRequests as identity, imageRequests as image, informRequests as inform, logRequests as log, mailRequests as mail, migrationRequests as migration, networkRequests as network, nodeRequests as node, platformRequests as platform, routingRequests as routing, secretRequests as secret, secretBundleRequests as secretbundle, secretGroupRequests as secretgroup, serverRequests as server, serviceRequests as service, settingsRequests as settings, statusRequests as status, taskRequests as task, versionRequests as version, webPushRequests as webpush, };
38
+ export { adminRequests as admin, appStoreRequests as appstore, baremetalRequests as baremetal, baseOsRequests as baseos, backupRequests as backup, certificateRequests as certificate, clusterRequests as cluster, configRequests as config, coreMailRequests as coremail, corestoreRequests as corestore, deploymentRequests as deployment, dnsRequests as dns, domainRequests as domain, externalRegistryRequests as externalRegistry, gatewayRequests as gateway, hostedAppRequests as hostedapp, identityRequests as identity, imageRequests as image, informRequests as inform, logRequests as log, mailRequests as mail, migrationRequests as migration, networkRequests as network, nodeRequests as node, platformRequests as platform, routingRequests as routing, secretRequests as secret, secretBundleRequests as secretbundle, secretGroupRequests as secretgroup, serverRequests as server, serviceRequests as service, settingsRequests as settings, statusRequests as status, taskRequests as task, versionRequests as version, webPushRequests as webpush, };
38
39
  export * from './inform.js';
39
40
  export * from './hostedapp.js';
40
41
  export * from './mail.js';
41
42
  export * from './webpush.js';
42
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi90cy9yZXF1ZXN0cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEtBQUssT0FBTyxNQUFNLGVBQWUsQ0FBQztBQUV6QyxPQUFPLEtBQUssYUFBYSxNQUFNLFlBQVksQ0FBQztBQUM1QyxPQUFPLEtBQUssZ0JBQWdCLE1BQU0sZUFBZSxDQUFDO0FBQ2xELE9BQU8sS0FBSyxpQkFBaUIsTUFBTSxnQkFBZ0IsQ0FBQztBQUNwRCxPQUFPLEtBQUssY0FBYyxNQUFNLGFBQWEsQ0FBQztBQUM5QyxPQUFPLEtBQUssY0FBYyxNQUFNLGFBQWEsQ0FBQzt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V0FBVyxJQUFJLEdBQUcsRUFDbEIsWUFBWSxJQUFJLElBQUksRUFDcEIsaUJBQWlCLElBQUksU0FBUyxFQUM5QixlQUFlLElBQUksT0FBTyxFQUMxQixZQUFZLElBQUksSUFBSSxFQUNwQixnQkFBZ0IsSUFBSSxRQUFRLEVBQzVCLGVBQWUsSUFBSSxPQUFPLEVBQzFCLGNBQWMsSUFBSSxNQUFNLEVBQ3hCLG9CQUFvQixJQUFJLFlBQVksRUFDcEMsbUJBQW1CLElBQUksV0FBVyxFQUNsQyxjQUFjLElBQUksTUFBTSxFQUN4QixlQUFlLElBQUksT0FBTyxFQUMxQixnQkFBZ0IsSUFBSSxRQUFRLEVBQzVCLGNBQWMsSUFBSSxNQUFNLEVBQ3hCLFlBQVksSUFBSSxJQUFJLEVBQ3BCLGVBQWUsSUFBSSxPQUFPLEVBQzFCLGVBQWUsSUFBSSxPQUFPLEdBQzNCLENBQUM7QUFFRixjQUFjLGFBQWEsQ0FBQztBQUM1QixjQUFjLGdCQUFnQixDQUFDO0FBQy9CLGNBQWMsV0FBVyxDQUFDO0FBQzFCLGNBQWMsY0FBYyxDQUFDIn0=
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@serve.zone/interfaces",
3
- "version": "20.1.0",
3
+ "version": "20.2.0",
4
4
  "private": false,
5
5
  "description": "Shared TypeScript interfaces and TypedRequest contracts for the serve.zone ecosystem.",
6
6
  "exports": {
@@ -17,7 +17,7 @@
17
17
  "author": "Task Venture Capital GmbH",
18
18
  "license": "MIT",
19
19
  "dependencies": {
20
- "@api.global/typedrequest-interfaces": "^3.0.19",
20
+ "@api.global/typedrequest-interfaces": "^4.0.0",
21
21
  "@push.rocks/smartlog-interfaces": "^3.0.2",
22
22
  "@tsclass/tsclass": "^9.5.1"
23
23
  },
package/readme.md CHANGED
@@ -480,6 +480,35 @@ const provisioning: requests.gateway.IReq_ProvisionGatewayClientCredential['requ
480
480
 
481
481
  `getGatewayClientContext` returns effective live policy. A `gatewayClient` role necessarily includes the credential ID, bound client ID/type, and `policyGeneration`; consumers should reject admin/operator or mismatched contexts rather than falling back to a caller-supplied owner ID. `getGatewayClientMailOverview` provides an owner-scoped domain and recent-message summary. `getGatewayClientMailDomainCount` derives ownership exclusively from the authenticating gateway credential and returns `{ count: number }` for its distinct configured mail domains. Cloudly therefore uses only `dcrouterGatewayApiToken`; the former `dcrouterOpsApiToken` setting is not part of `data.ICloudlySettings`.
482
482
 
483
+ ### CoreMail contracts
484
+
485
+ `requests.coremail` is the shared contract boundary for authenticated workload
486
+ sessions, Coreflow reconciliation, and the CoreMail-to-dcrouter gateway
487
+ session. Only the three authentication handshakes carry reusable peer
488
+ credentials. Subsequent transfer operations may carry a scoped, short-lived,
489
+ one-time bearer capability, while every subsequent workload request derives
490
+ tenant, service, binding, capabilities, allowed senders, and credential version
491
+ from the server-owned TypedSocket peer.
492
+
493
+ Large content never travels inside TypedRequest JSON. Outbound body parts and
494
+ attachments use prepare/upload/complete operations with short-lived one-time
495
+ HTTP transfer grants. Inbound delivery uses bounded delivery listing followed
496
+ by prepare/fetch/complete and an explicit acknowledgement after the workload
497
+ has processed the exact byte count and SHA-256 digest. `data.coreMailLimits`
498
+ defines the 64 KiB control-frame boundary, bounded structured content, the
499
+ 30 MiB serialized MIME ceiling, transfer deadlines, and five-minute grant
500
+ lifetime.
501
+
502
+ Coreflow applies `data.ICoreMailDesiredState` with a config-epoch
503
+ compare-and-set fence. It stages the digest-fenced JSON snapshot through a
504
+ bounded one-time HTTP upload, then applies it by reconciliation ID, so a large
505
+ binding set never bypasses the 64 KiB control-frame boundary. Desired bindings
506
+ contain password verifiers and secret references only, never plaintext
507
+ workload or dcrouter credentials.
508
+ Reconciliation status carries the exact CoreMail task, rollout generation, and
509
+ image digest so Coreflow can correlate every response with its authoritative
510
+ current task roster.
511
+
483
512
  Request groups are exported by product area:
484
513
 
485
514
  - `requests.admin`
@@ -490,6 +519,7 @@ Request groups are exported by product area:
490
519
  - `requests.certificate`
491
520
  - `requests.cluster`
492
521
  - `requests.config`
522
+ - `requests.coremail`
493
523
  - `requests.corestore`
494
524
  - `requests.deployment`
495
525
  - `requests.dns`
@@ -3,6 +3,6 @@
3
3
  */
4
4
  export const commitinfo = {
5
5
  name: '@serve.zone/interfaces',
6
- version: '20.1.0',
6
+ version: '20.2.0',
7
7
  description: 'Shared TypeScript interfaces and TypedRequest contracts for the serve.zone ecosystem.'
8
8
  }
@@ -0,0 +1,277 @@
1
+ /**
2
+ * Shared CoreMail contracts.
3
+ *
4
+ * Workload authority is always derived from an authenticated transport
5
+ * session. Application-facing request DTOs therefore carry message or
6
+ * delivery identifiers only and never caller-selected tenant, service, or
7
+ * binding authority.
8
+ */
9
+
10
+ export type TCoreMailSha256 = `sha256:${string}`;
11
+
12
+ export type TCoreMailCapability = 'outbound' | 'inbound';
13
+ export type TCoreMailBindingState = 'active' | 'disabled';
14
+ export type TCoreMailCredentialState = 'current' | 'retiring';
15
+ export type TCoreMailPartKind = 'text' | 'html' | 'attachment';
16
+ export type TCoreMailTransferMethod = 'PUT' | 'GET';
17
+ export type TCoreMailSubmissionState =
18
+ | 'preparing'
19
+ | 'uploading'
20
+ | 'ready'
21
+ | 'accepted'
22
+ | 'queued'
23
+ | 'delivering'
24
+ | 'delivered'
25
+ | 'deferred'
26
+ | 'failed'
27
+ | 'deadLettered';
28
+ export type TCoreMailInboundDeliveryState = 'pending' | 'fetching' | 'fetched' | 'acknowledged';
29
+ export type TCoreMailInboundAckOutcome = 'processed' | 'discarded';
30
+ export type TCoreMailRecipientAction = 'accept' | 'reject' | 'defer';
31
+ export type TCoreMailReconciliationState = 'applying' | 'ready' | 'failed';
32
+
33
+ export type TCoreMailErrorCode =
34
+ | 'AUTHENTICATION_FAILED'
35
+ | 'AUTHENTICATION_EXPIRED'
36
+ | 'AUTHORITY_REVOKED'
37
+ | 'CAPABILITY_DENIED'
38
+ | 'NOT_FOUND'
39
+ | 'INVALID_REQUEST'
40
+ | 'INVALID_MAILBOX'
41
+ | 'INVALID_SENDER'
42
+ | 'INVALID_RECIPIENT'
43
+ | 'INVALID_HEADER'
44
+ | 'PAYLOAD_LIMIT_EXCEEDED'
45
+ | 'IDEMPOTENCY_CONFLICT'
46
+ | 'STATE_CONFLICT'
47
+ | 'TRANSFER_GRANT_EXPIRED'
48
+ | 'TRANSFER_GRANT_REPLAYED'
49
+ | 'TRANSFER_LENGTH_MISMATCH'
50
+ | 'TRANSFER_DIGEST_MISMATCH'
51
+ | 'TRANSFER_ENCODING_UNSUPPORTED'
52
+ | 'OBJECT_INTEGRITY_CONFLICT'
53
+ | 'DELIVERY_NOT_FETCHED'
54
+ | 'GATEWAY_UNAVAILABLE'
55
+ | 'RECONCILIATION_FENCE_MISMATCH';
56
+
57
+ export interface ICoreMailErrorData {
58
+ code: TCoreMailErrorCode;
59
+ retryable: boolean;
60
+ retryAfterMs?: number;
61
+ }
62
+
63
+ export interface ICoreMailMailbox {
64
+ address: string;
65
+ displayName?: string;
66
+ }
67
+
68
+ export interface ICoreMailEnvelope {
69
+ mailFrom: string;
70
+ rcptTo: string[];
71
+ }
72
+
73
+ export interface ICoreMailHeader {
74
+ name: string;
75
+ value: string;
76
+ }
77
+
78
+ export interface ICoreMailContentDescriptor {
79
+ partId: string;
80
+ kind: TCoreMailPartKind;
81
+ contentType: string;
82
+ filename?: string;
83
+ contentId?: string;
84
+ sha256: TCoreMailSha256;
85
+ lengthBytes: number;
86
+ }
87
+
88
+ export interface ICoreMailOutboundMessageDescriptor {
89
+ sender: ICoreMailMailbox;
90
+ recipients: {
91
+ to: ICoreMailMailbox[];
92
+ cc?: ICoreMailMailbox[];
93
+ bcc?: ICoreMailMailbox[];
94
+ };
95
+ replyTo?: ICoreMailMailbox;
96
+ subject: string;
97
+ /** Ordered headers. Transport-owned MIME headers are not accepted here. */
98
+ headers?: ICoreMailHeader[];
99
+ /** Ordered body and attachment descriptors. Bytes move through bounded HTTP transfers. */
100
+ parts: ICoreMailContentDescriptor[];
101
+ }
102
+
103
+ export interface ICoreMailTransferGrant {
104
+ grantId: string;
105
+ method: TCoreMailTransferMethod;
106
+ /** Same-origin path. Callers use the authenticated CoreMail or gateway endpoint they already hold. */
107
+ path: string;
108
+ /** One-time bearer capability. It must never be logged or persisted by a consumer. */
109
+ bearerToken: string;
110
+ sha256: TCoreMailSha256;
111
+ lengthBytes: number;
112
+ contentType: string;
113
+ expiresAt: number;
114
+ }
115
+
116
+ export interface ICoreMailUploadGrant extends ICoreMailTransferGrant {
117
+ method: 'PUT';
118
+ }
119
+
120
+ export interface ICoreMailDownloadGrant extends ICoreMailTransferGrant {
121
+ method: 'GET';
122
+ }
123
+
124
+ export interface ICoreMailPartStatus {
125
+ partId: string;
126
+ state: 'missing' | 'uploading' | 'complete' | 'failed';
127
+ sha256: TCoreMailSha256;
128
+ lengthBytes: number;
129
+ }
130
+
131
+ export interface ICoreMailSubmission {
132
+ submissionId: string;
133
+ idempotencyKey: string;
134
+ submissionDigest: TCoreMailSha256;
135
+ state: TCoreMailSubmissionState;
136
+ parts: ICoreMailPartStatus[];
137
+ transportMessageId?: string;
138
+ attempts: number;
139
+ nextAttemptAt?: number;
140
+ acceptedAt?: number;
141
+ deliveredAt?: number;
142
+ createdAt: number;
143
+ updatedAt: number;
144
+ }
145
+
146
+ export interface ICoreMailInboundDelivery {
147
+ deliveryId: string;
148
+ transportDeliveryId: string;
149
+ state: TCoreMailInboundDeliveryState;
150
+ envelope: ICoreMailEnvelope;
151
+ rawMime: {
152
+ sha256: TCoreMailSha256;
153
+ lengthBytes: number;
154
+ contentType: 'message/rfc822';
155
+ };
156
+ messageId?: string;
157
+ subject?: string;
158
+ receivedAt: number;
159
+ updatedAt: number;
160
+ }
161
+
162
+ export interface ICoreMailBindingCredentialVerifier {
163
+ credentialId: string;
164
+ version: number;
165
+ state: TCoreMailCredentialState;
166
+ /** Password-verifier string only. Plaintext credential material is never part of desired state. */
167
+ verificationHash: string;
168
+ acceptUntil?: number;
169
+ }
170
+
171
+ export interface ICoreMailBindingDesiredState {
172
+ schemaVersion: 1;
173
+ bindingId: string;
174
+ serviceId: string;
175
+ tenantId: string;
176
+ revision: number;
177
+ state: TCoreMailBindingState;
178
+ capabilities: TCoreMailCapability[];
179
+ credentials: ICoreMailBindingCredentialVerifier[];
180
+ allowedSenders: string[];
181
+ inboundRecipients: string[];
182
+ defaultSender?: string;
183
+ limits?: {
184
+ messagesPerMinute?: number;
185
+ messagesPerDay?: number;
186
+ maxPendingInbound?: number;
187
+ };
188
+ }
189
+
190
+ export interface ICoreMailGatewayDesiredState {
191
+ endpointUrl: string;
192
+ credentialId: string;
193
+ credentialVersion: number;
194
+ /** Key in CoreMail's resolved runtime secret material, never a plaintext value. */
195
+ credentialSecretKey: string;
196
+ }
197
+
198
+ export interface ICoreMailDesiredState {
199
+ schemaVersion: 1;
200
+ configEpoch: number;
201
+ bindings: ICoreMailBindingDesiredState[];
202
+ gateway: ICoreMailGatewayDesiredState;
203
+ }
204
+
205
+ export interface ICoreMailReplicaIdentity {
206
+ taskId: string;
207
+ serviceId: string;
208
+ rolloutId: string;
209
+ rolloutGeneration: number;
210
+ imageDigest: TCoreMailSha256;
211
+ }
212
+
213
+ export interface ICoreMailBindingReconciliationStatus {
214
+ bindingId: string;
215
+ revision: number;
216
+ state: TCoreMailBindingState;
217
+ activeSessionsByCredentialVersion: Array<{
218
+ version: number;
219
+ count: number;
220
+ }>;
221
+ }
222
+
223
+ export interface ICoreMailReconciliationStatus {
224
+ replica: ICoreMailReplicaIdentity;
225
+ state: TCoreMailReconciliationState;
226
+ appliedConfigEpoch: number;
227
+ appliedDesiredStateDigest: TCoreMailSha256;
228
+ bindings: ICoreMailBindingReconciliationStatus[];
229
+ updatedAt: number;
230
+ errorCode?: TCoreMailErrorCode;
231
+ }
232
+
233
+ export interface ICoreMailRecipientResolution {
234
+ recipient: string;
235
+ action: TCoreMailRecipientAction;
236
+ /** Opaque, short-lived handle returned only for accepted recipients. */
237
+ routingHandle?: string;
238
+ smtpCode?: number;
239
+ message?: string;
240
+ }
241
+
242
+ export interface ICoreMailGatewayMessageDescriptor {
243
+ envelope: ICoreMailEnvelope;
244
+ rawMime: {
245
+ sha256: TCoreMailSha256;
246
+ lengthBytes: number;
247
+ contentType: 'message/rfc822';
248
+ };
249
+ }
250
+
251
+ export interface ICoreMailGatewayOutboundStatus {
252
+ transportMessageId: string;
253
+ state: Extract<
254
+ TCoreMailSubmissionState,
255
+ 'accepted' | 'queued' | 'delivering' | 'delivered' | 'deferred' | 'failed' | 'deadLettered'
256
+ >;
257
+ attempts: number;
258
+ nextAttemptAt?: number;
259
+ smtpCode?: number;
260
+ updatedAt: number;
261
+ }
262
+
263
+ export const coreMailLimits = Object.freeze({
264
+ controlMessageBytes: 64 * 1024,
265
+ desiredStateBytes: 8 * 1024 * 1024,
266
+ textPartBytes: 1 * 1024 * 1024,
267
+ htmlPartBytes: 2 * 1024 * 1024,
268
+ attachmentCount: 16,
269
+ attachmentBytes: 10 * 1024 * 1024,
270
+ aggregateAttachmentBytes: 17 * 1024 * 1024,
271
+ mimeFramingBytes: 512 * 1024,
272
+ serializedMimeBytes: 30 * 1024 * 1024,
273
+ transferGrantTtlMs: 5 * 60 * 1000,
274
+ transferHeaderTimeoutMs: 10 * 1000,
275
+ transferIdleTimeoutMs: 15 * 1000,
276
+ transferOverallTimeoutMs: 2 * 60 * 1000,
277
+ } as const);
package/ts/data/index.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  export * from './cloudlyconfig.js';
2
2
  export * from './cluster.js';
3
3
  export * from './config.js';
4
+ export * from './coremail.js';
4
5
  export * from './deployment.js';
5
6
  export * from './deploymentadoption.js';
6
7
  export * from './deploymentoperation.js';
@@ -0,0 +1,346 @@
1
+ import type * as plugins from '../plugins.js';
2
+ import type {
3
+ ICoreMailEnvelope,
4
+ ICoreMailDownloadGrant,
5
+ ICoreMailGatewayMessageDescriptor,
6
+ ICoreMailGatewayOutboundStatus,
7
+ ICoreMailInboundDelivery,
8
+ ICoreMailOutboundMessageDescriptor,
9
+ ICoreMailRecipientResolution,
10
+ ICoreMailReconciliationStatus,
11
+ ICoreMailReplicaIdentity,
12
+ ICoreMailSubmission,
13
+ ICoreMailUploadGrant,
14
+ TCoreMailInboundAckOutcome,
15
+ TCoreMailSha256,
16
+ } from '../data/coremail.js';
17
+ import type { IMailConnectionInfo } from '../data/mail.js';
18
+
19
+ export interface IReq_CoreMailAuthenticateWorkload extends plugins.typedrequestInterfaces.implementsTR<
20
+ plugins.typedrequestInterfaces.ITypedRequest,
21
+ IReq_CoreMailAuthenticateWorkload
22
+ > {
23
+ method: 'coreMailAuthenticateWorkload';
24
+ request: {
25
+ bindingId: string;
26
+ credentialId: string;
27
+ credentialVersion: number;
28
+ credentialSecret: string;
29
+ };
30
+ response: {
31
+ authenticated: true;
32
+ credentialVersion: number;
33
+ capabilities: Array<'outbound' | 'inbound'>;
34
+ };
35
+ }
36
+
37
+ export interface IReq_CoreMailPrepareOutboundSubmission extends plugins.typedrequestInterfaces.implementsTR<
38
+ plugins.typedrequestInterfaces.ITypedRequest,
39
+ IReq_CoreMailPrepareOutboundSubmission
40
+ > {
41
+ method: 'coreMailPrepareOutboundSubmission';
42
+ request: {
43
+ /** Required replay key. Authority is added by the authenticated server session. */
44
+ idempotencyKey: string;
45
+ message: ICoreMailOutboundMessageDescriptor;
46
+ };
47
+ response: {
48
+ submission: ICoreMailSubmission;
49
+ replayed: boolean;
50
+ };
51
+ }
52
+
53
+ export interface IReq_CoreMailPrepareOutboundPartUpload extends plugins.typedrequestInterfaces.implementsTR<
54
+ plugins.typedrequestInterfaces.ITypedRequest,
55
+ IReq_CoreMailPrepareOutboundPartUpload
56
+ > {
57
+ method: 'coreMailPrepareOutboundPartUpload';
58
+ request: {
59
+ submissionId: string;
60
+ partId: string;
61
+ };
62
+ response: {
63
+ grant: ICoreMailUploadGrant;
64
+ };
65
+ }
66
+
67
+ export interface IReq_CoreMailCompleteOutboundPartUpload extends plugins.typedrequestInterfaces.implementsTR<
68
+ plugins.typedrequestInterfaces.ITypedRequest,
69
+ IReq_CoreMailCompleteOutboundPartUpload
70
+ > {
71
+ method: 'coreMailCompleteOutboundPartUpload';
72
+ request: {
73
+ submissionId: string;
74
+ partId: string;
75
+ grantId: string;
76
+ sha256: TCoreMailSha256;
77
+ lengthBytes: number;
78
+ };
79
+ response: {
80
+ submission: ICoreMailSubmission;
81
+ };
82
+ }
83
+
84
+ export interface IReq_CoreMailFinalizeOutboundSubmission extends plugins.typedrequestInterfaces.implementsTR<
85
+ plugins.typedrequestInterfaces.ITypedRequest,
86
+ IReq_CoreMailFinalizeOutboundSubmission
87
+ > {
88
+ method: 'coreMailFinalizeOutboundSubmission';
89
+ request: {
90
+ submissionId: string;
91
+ };
92
+ response: {
93
+ submission: ICoreMailSubmission;
94
+ };
95
+ }
96
+
97
+ export interface IReq_CoreMailGetOutboundSubmission extends plugins.typedrequestInterfaces.implementsTR<
98
+ plugins.typedrequestInterfaces.ITypedRequest,
99
+ IReq_CoreMailGetOutboundSubmission
100
+ > {
101
+ method: 'coreMailGetOutboundSubmission';
102
+ request: {
103
+ submissionId: string;
104
+ };
105
+ response: {
106
+ submission: ICoreMailSubmission;
107
+ };
108
+ }
109
+
110
+ export interface IReq_CoreMailListInboundDeliveries extends plugins.typedrequestInterfaces.implementsTR<
111
+ plugins.typedrequestInterfaces.ITypedRequest,
112
+ IReq_CoreMailListInboundDeliveries
113
+ > {
114
+ method: 'coreMailListInboundDeliveries';
115
+ request: {
116
+ afterDeliveryId?: string;
117
+ limit: number;
118
+ };
119
+ response: {
120
+ deliveries: ICoreMailInboundDelivery[];
121
+ };
122
+ }
123
+
124
+ export interface IReq_CoreMailPrepareInboundFetch extends plugins.typedrequestInterfaces.implementsTR<
125
+ plugins.typedrequestInterfaces.ITypedRequest,
126
+ IReq_CoreMailPrepareInboundFetch
127
+ > {
128
+ method: 'coreMailPrepareInboundFetch';
129
+ request: {
130
+ deliveryId: string;
131
+ };
132
+ response: {
133
+ grant: ICoreMailDownloadGrant;
134
+ };
135
+ }
136
+
137
+ export interface IReq_CoreMailCompleteInboundFetch extends plugins.typedrequestInterfaces.implementsTR<
138
+ plugins.typedrequestInterfaces.ITypedRequest,
139
+ IReq_CoreMailCompleteInboundFetch
140
+ > {
141
+ method: 'coreMailCompleteInboundFetch';
142
+ request: {
143
+ deliveryId: string;
144
+ grantId: string;
145
+ sha256: TCoreMailSha256;
146
+ lengthBytes: number;
147
+ };
148
+ response: {
149
+ delivery: ICoreMailInboundDelivery;
150
+ };
151
+ }
152
+
153
+ export interface IReq_CoreMailAcknowledgeInboundDelivery extends plugins.typedrequestInterfaces.implementsTR<
154
+ plugins.typedrequestInterfaces.ITypedRequest,
155
+ IReq_CoreMailAcknowledgeInboundDelivery
156
+ > {
157
+ method: 'coreMailAcknowledgeInboundDelivery';
158
+ request: {
159
+ deliveryId: string;
160
+ outcome: TCoreMailInboundAckOutcome;
161
+ };
162
+ response: {
163
+ delivery: ICoreMailInboundDelivery;
164
+ replayed: boolean;
165
+ };
166
+ }
167
+
168
+ export interface IReq_CoreMailAuthenticateControl extends plugins.typedrequestInterfaces.implementsTR<
169
+ plugins.typedrequestInterfaces.ITypedRequest,
170
+ IReq_CoreMailAuthenticateControl
171
+ > {
172
+ method: 'coreMailAuthenticateControl';
173
+ request: {
174
+ credentialId: string;
175
+ credentialVersion: number;
176
+ credentialSecret: string;
177
+ };
178
+ response: {
179
+ authenticated: true;
180
+ replica: ICoreMailReplicaIdentity;
181
+ };
182
+ }
183
+
184
+ export interface IReq_CoreMailPrepareDesiredStateUpload extends plugins.typedrequestInterfaces.implementsTR<
185
+ plugins.typedrequestInterfaces.ITypedRequest,
186
+ IReq_CoreMailPrepareDesiredStateUpload
187
+ > {
188
+ method: 'coreMailPrepareDesiredStateUpload';
189
+ request: {
190
+ expectedAppliedConfigEpoch: number;
191
+ configEpoch: number;
192
+ desiredStateDigest: TCoreMailSha256;
193
+ lengthBytes: number;
194
+ };
195
+ response: {
196
+ reconciliationId: string;
197
+ grant: ICoreMailUploadGrant;
198
+ replayed: boolean;
199
+ };
200
+ }
201
+
202
+ export interface IReq_CoreMailApplyDesiredState extends plugins.typedrequestInterfaces.implementsTR<
203
+ plugins.typedrequestInterfaces.ITypedRequest,
204
+ IReq_CoreMailApplyDesiredState
205
+ > {
206
+ method: 'coreMailApplyDesiredState';
207
+ request: {
208
+ reconciliationId: string;
209
+ grantId: string;
210
+ desiredStateDigest: TCoreMailSha256;
211
+ lengthBytes: number;
212
+ };
213
+ response: {
214
+ status: ICoreMailReconciliationStatus;
215
+ };
216
+ }
217
+
218
+ export interface IReq_CoreMailGetReconciliationStatus extends plugins.typedrequestInterfaces.implementsTR<
219
+ plugins.typedrequestInterfaces.ITypedRequest,
220
+ IReq_CoreMailGetReconciliationStatus
221
+ > {
222
+ method: 'coreMailGetReconciliationStatus';
223
+ request: {
224
+ configEpoch: number;
225
+ desiredStateDigest: TCoreMailSha256;
226
+ };
227
+ response: {
228
+ status: ICoreMailReconciliationStatus;
229
+ };
230
+ }
231
+
232
+ export interface IReq_CoreMailGatewayAuthenticate extends plugins.typedrequestInterfaces.implementsTR<
233
+ plugins.typedrequestInterfaces.ITypedRequest,
234
+ IReq_CoreMailGatewayAuthenticate
235
+ > {
236
+ method: 'coreMailGatewayAuthenticate';
237
+ request: {
238
+ credentialId: string;
239
+ credentialVersion: number;
240
+ credentialSecret: string;
241
+ };
242
+ response: {
243
+ authenticated: true;
244
+ credentialVersion: number;
245
+ };
246
+ }
247
+
248
+ export interface IReq_CoreMailGatewayResolveRecipients extends plugins.typedrequestInterfaces.implementsTR<
249
+ plugins.typedrequestInterfaces.ITypedRequest,
250
+ IReq_CoreMailGatewayResolveRecipients
251
+ > {
252
+ method: 'coreMailGatewayResolveRecipients';
253
+ request: {
254
+ envelope: ICoreMailEnvelope;
255
+ recipients: string[];
256
+ source: IMailConnectionInfo;
257
+ };
258
+ response: {
259
+ resolutions: ICoreMailRecipientResolution[];
260
+ };
261
+ }
262
+
263
+ export interface IReq_CoreMailGatewayPrepareInboundHandoff extends plugins.typedrequestInterfaces.implementsTR<
264
+ plugins.typedrequestInterfaces.ITypedRequest,
265
+ IReq_CoreMailGatewayPrepareInboundHandoff
266
+ > {
267
+ method: 'coreMailGatewayPrepareInboundHandoff';
268
+ request: {
269
+ transportDeliveryId: string;
270
+ routingHandles: string[];
271
+ message: ICoreMailGatewayMessageDescriptor;
272
+ source: IMailConnectionInfo;
273
+ };
274
+ response: {
275
+ handoffId: string;
276
+ grant?: ICoreMailUploadGrant;
277
+ replayed: boolean;
278
+ };
279
+ }
280
+
281
+ export interface IReq_CoreMailGatewayCompleteInboundHandoff extends plugins.typedrequestInterfaces.implementsTR<
282
+ plugins.typedrequestInterfaces.ITypedRequest,
283
+ IReq_CoreMailGatewayCompleteInboundHandoff
284
+ > {
285
+ method: 'coreMailGatewayCompleteInboundHandoff';
286
+ request: {
287
+ handoffId: string;
288
+ grantId: string;
289
+ sha256: TCoreMailSha256;
290
+ lengthBytes: number;
291
+ };
292
+ response: {
293
+ accepted: true;
294
+ deliveryIds: string[];
295
+ replayed: boolean;
296
+ };
297
+ }
298
+
299
+ export interface IReq_CoreMailGatewayPrepareOutboundHandoff extends plugins.typedrequestInterfaces.implementsTR<
300
+ plugins.typedrequestInterfaces.ITypedRequest,
301
+ IReq_CoreMailGatewayPrepareOutboundHandoff
302
+ > {
303
+ method: 'coreMailGatewayPrepareOutboundHandoff';
304
+ request: {
305
+ transportSubmissionId: string;
306
+ submissionDigest: TCoreMailSha256;
307
+ message: ICoreMailGatewayMessageDescriptor;
308
+ /** CoreMail-issued GET grant. dcrouter resolves the path against the authenticated peer. */
309
+ grant: ICoreMailDownloadGrant;
310
+ };
311
+ response: {
312
+ transportMessageId: string;
313
+ status: ICoreMailGatewayOutboundStatus;
314
+ replayed: boolean;
315
+ };
316
+ }
317
+
318
+ export interface IReq_CoreMailGatewayCompleteOutboundHandoff extends plugins.typedrequestInterfaces.implementsTR<
319
+ plugins.typedrequestInterfaces.ITypedRequest,
320
+ IReq_CoreMailGatewayCompleteOutboundHandoff
321
+ > {
322
+ method: 'coreMailGatewayCompleteOutboundHandoff';
323
+ request: {
324
+ transportMessageId: string;
325
+ grantId: string;
326
+ sha256: TCoreMailSha256;
327
+ lengthBytes: number;
328
+ };
329
+ response: {
330
+ status: ICoreMailGatewayOutboundStatus;
331
+ replayed: boolean;
332
+ };
333
+ }
334
+
335
+ export interface IReq_CoreMailGatewayGetOutboundStatus extends plugins.typedrequestInterfaces.implementsTR<
336
+ plugins.typedrequestInterfaces.ITypedRequest,
337
+ IReq_CoreMailGatewayGetOutboundStatus
338
+ > {
339
+ method: 'coreMailGatewayGetOutboundStatus';
340
+ request: {
341
+ transportMessageId: string;
342
+ };
343
+ response: {
344
+ status: ICoreMailGatewayOutboundStatus;
345
+ };
346
+ }
@@ -8,6 +8,7 @@ import * as backupRequests from './backup.js';
8
8
  import * as certificateRequests from './certificate.js';
9
9
  import * as clusterRequests from './cluster.js';
10
10
  import * as configRequests from './config.js';
11
+ import * as coreMailRequests from './coremail.js';
11
12
  import * as corestoreRequests from './corestore.js';
12
13
  import * as deploymentRequests from './deployment.js';
13
14
  import * as dnsRequests from './dns.js';
@@ -45,6 +46,7 @@ export {
45
46
  certificateRequests as certificate,
46
47
  clusterRequests as cluster,
47
48
  configRequests as config,
49
+ coreMailRequests as coremail,
48
50
  corestoreRequests as corestore,
49
51
  deploymentRequests as deployment,
50
52
  dnsRequests as dns,