agentmail 0.0.78 → 0.1.1
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 +5 -2
- package/dist/cjs/Client.js +2 -2
- package/dist/cjs/api/resources/apiKeys/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/apiKeys/client/Client.js +62 -52
- package/dist/cjs/api/resources/domains/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/domains/client/Client.js +62 -52
- package/dist/cjs/api/resources/drafts/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/drafts/client/Client.js +83 -70
- package/dist/cjs/api/resources/events/types/Bounce.d.ts +1 -0
- package/dist/cjs/api/resources/events/types/Complaint.d.ts +1 -0
- package/dist/cjs/api/resources/events/types/Delivery.d.ts +1 -0
- package/dist/cjs/api/resources/events/types/Reject.d.ts +1 -0
- package/dist/cjs/api/resources/events/types/Send.d.ts +1 -0
- package/dist/cjs/api/resources/inboxes/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/inboxes/client/Client.js +62 -52
- package/dist/cjs/api/resources/inboxes/resources/drafts/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/inboxes/resources/drafts/client/Client.js +83 -70
- package/dist/cjs/api/resources/inboxes/resources/messages/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/inboxes/resources/messages/client/Client.js +83 -70
- package/dist/cjs/api/resources/inboxes/resources/threads/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/inboxes/resources/threads/client/Client.js +83 -70
- package/dist/cjs/api/resources/pods/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/pods/client/Client.js +62 -52
- package/dist/cjs/api/resources/pods/resources/domains/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/pods/resources/domains/client/Client.js +83 -70
- package/dist/cjs/api/resources/pods/resources/drafts/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/pods/resources/drafts/client/Client.js +83 -70
- package/dist/cjs/api/resources/pods/resources/inboxes/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/pods/resources/inboxes/client/Client.js +83 -70
- package/dist/cjs/api/resources/pods/resources/threads/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/pods/resources/threads/client/Client.js +83 -70
- package/dist/cjs/api/resources/threads/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/threads/client/Client.js +83 -70
- package/dist/cjs/api/resources/webhooks/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/webhooks/client/Client.js +62 -52
- package/dist/cjs/core/exports.d.ts +2 -0
- package/dist/cjs/core/exports.js +18 -0
- package/dist/cjs/core/index.d.ts +2 -0
- package/dist/cjs/core/index.js +2 -0
- package/dist/cjs/core/pagination/Page.d.ts +33 -0
- package/dist/cjs/core/pagination/Page.js +101 -0
- package/dist/cjs/core/pagination/exports.d.ts +1 -0
- package/dist/cjs/core/pagination/exports.js +2 -0
- package/dist/cjs/core/pagination/index.d.ts +1 -0
- package/dist/cjs/core/pagination/index.js +5 -0
- package/dist/cjs/core/utils/index.d.ts +1 -0
- package/dist/cjs/core/utils/index.js +5 -0
- package/dist/cjs/core/utils/setObjectProperty.d.ts +11 -0
- package/dist/cjs/core/utils/setObjectProperty.js +42 -0
- package/dist/cjs/core/websocket/exports.d.ts +8 -0
- package/dist/cjs/core/websocket/exports.js +2 -0
- package/dist/cjs/exports.d.ts +1 -0
- package/dist/cjs/exports.js +17 -0
- package/dist/cjs/index.d.ts +1 -0
- package/dist/cjs/index.js +4 -0
- package/dist/cjs/serialization/resources/events/types/Bounce.d.ts +2 -0
- package/dist/cjs/serialization/resources/events/types/Bounce.js +2 -0
- package/dist/cjs/serialization/resources/events/types/Complaint.d.ts +2 -0
- package/dist/cjs/serialization/resources/events/types/Complaint.js +2 -0
- package/dist/cjs/serialization/resources/events/types/Delivery.d.ts +2 -0
- package/dist/cjs/serialization/resources/events/types/Delivery.js +2 -0
- package/dist/cjs/serialization/resources/events/types/Reject.d.ts +2 -0
- package/dist/cjs/serialization/resources/events/types/Reject.js +2 -0
- package/dist/cjs/serialization/resources/events/types/Send.d.ts +2 -0
- package/dist/cjs/serialization/resources/events/types/Send.js +2 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/api/resources/apiKeys/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/apiKeys/client/Client.mjs +62 -52
- package/dist/esm/api/resources/domains/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/domains/client/Client.mjs +62 -52
- package/dist/esm/api/resources/drafts/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/drafts/client/Client.mjs +83 -70
- package/dist/esm/api/resources/events/types/Bounce.d.mts +1 -0
- package/dist/esm/api/resources/events/types/Complaint.d.mts +1 -0
- package/dist/esm/api/resources/events/types/Delivery.d.mts +1 -0
- package/dist/esm/api/resources/events/types/Reject.d.mts +1 -0
- package/dist/esm/api/resources/events/types/Send.d.mts +1 -0
- package/dist/esm/api/resources/inboxes/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/inboxes/client/Client.mjs +62 -52
- package/dist/esm/api/resources/inboxes/resources/drafts/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/inboxes/resources/drafts/client/Client.mjs +83 -70
- package/dist/esm/api/resources/inboxes/resources/messages/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/inboxes/resources/messages/client/Client.mjs +83 -70
- package/dist/esm/api/resources/inboxes/resources/threads/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/inboxes/resources/threads/client/Client.mjs +83 -70
- package/dist/esm/api/resources/pods/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/pods/client/Client.mjs +62 -52
- package/dist/esm/api/resources/pods/resources/domains/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/pods/resources/domains/client/Client.mjs +83 -70
- package/dist/esm/api/resources/pods/resources/drafts/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/pods/resources/drafts/client/Client.mjs +83 -70
- package/dist/esm/api/resources/pods/resources/inboxes/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/pods/resources/inboxes/client/Client.mjs +83 -70
- package/dist/esm/api/resources/pods/resources/threads/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/pods/resources/threads/client/Client.mjs +83 -70
- package/dist/esm/api/resources/threads/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/threads/client/Client.mjs +83 -70
- package/dist/esm/api/resources/webhooks/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/webhooks/client/Client.mjs +62 -52
- package/dist/esm/core/exports.d.mts +2 -0
- package/dist/esm/core/exports.mjs +2 -0
- package/dist/esm/core/index.d.mts +2 -0
- package/dist/esm/core/index.mjs +2 -0
- package/dist/esm/core/pagination/Page.d.mts +33 -0
- package/dist/esm/core/pagination/Page.mjs +97 -0
- package/dist/esm/core/pagination/exports.d.mts +1 -0
- package/dist/esm/core/pagination/exports.mjs +1 -0
- package/dist/esm/core/pagination/index.d.mts +1 -0
- package/dist/esm/core/pagination/index.mjs +1 -0
- package/dist/esm/core/utils/index.d.mts +1 -0
- package/dist/esm/core/utils/index.mjs +1 -0
- package/dist/esm/core/utils/setObjectProperty.d.mts +11 -0
- package/dist/esm/core/utils/setObjectProperty.mjs +39 -0
- package/dist/esm/core/websocket/exports.d.mts +8 -0
- package/dist/esm/core/websocket/exports.mjs +1 -0
- package/dist/esm/exports.d.mts +1 -0
- package/dist/esm/exports.mjs +1 -0
- package/dist/esm/index.d.mts +1 -0
- package/dist/esm/index.mjs +1 -0
- package/dist/esm/serialization/resources/events/types/Bounce.d.mts +2 -0
- package/dist/esm/serialization/resources/events/types/Bounce.mjs +2 -0
- package/dist/esm/serialization/resources/events/types/Complaint.d.mts +2 -0
- package/dist/esm/serialization/resources/events/types/Complaint.mjs +2 -0
- package/dist/esm/serialization/resources/events/types/Delivery.d.mts +2 -0
- package/dist/esm/serialization/resources/events/types/Delivery.mjs +2 -0
- package/dist/esm/serialization/resources/events/types/Reject.d.mts +2 -0
- package/dist/esm/serialization/resources/events/types/Reject.mjs +2 -0
- package/dist/esm/serialization/resources/events/types/Send.d.mts +2 -0
- package/dist/esm/serialization/resources/events/types/Send.mjs +2 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +196 -28
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
var __await = (this && this.__await) || function (v) { return this instanceof __await ? (this.v = v, this) : new __await(v); }
|
|
11
|
+
var __asyncGenerator = (this && this.__asyncGenerator) || function (thisArg, _arguments, generator) {
|
|
12
|
+
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
13
|
+
var g = generator.apply(thisArg, _arguments || []), i, q = [];
|
|
14
|
+
return i = Object.create((typeof AsyncIterator === "function" ? AsyncIterator : Object).prototype), verb("next"), verb("throw"), verb("return", awaitReturn), i[Symbol.asyncIterator] = function () { return this; }, i;
|
|
15
|
+
function awaitReturn(f) { return function (v) { return Promise.resolve(v).then(f, reject); }; }
|
|
16
|
+
function verb(n, f) { if (g[n]) { i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; if (f) i[n] = f(i[n]); } }
|
|
17
|
+
function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
|
|
18
|
+
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
|
|
19
|
+
function fulfill(value) { resume("next", value); }
|
|
20
|
+
function reject(value) { resume("throw", value); }
|
|
21
|
+
function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
|
|
22
|
+
};
|
|
23
|
+
var __asyncValues = (this && this.__asyncValues) || function (o) {
|
|
24
|
+
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
25
|
+
var m = o[Symbol.asyncIterator], i;
|
|
26
|
+
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
|
|
27
|
+
function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
|
|
28
|
+
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* A page of results from a paginated API.
|
|
32
|
+
*
|
|
33
|
+
* @template T The type of the items in the page.
|
|
34
|
+
* @template R The type of the API response.
|
|
35
|
+
*/
|
|
36
|
+
export class Page {
|
|
37
|
+
constructor({ response, rawResponse, hasNextPage, getItems, loadPage, }) {
|
|
38
|
+
this.response = response;
|
|
39
|
+
this.rawResponse = rawResponse;
|
|
40
|
+
this.data = getItems(response);
|
|
41
|
+
this._hasNextPage = hasNextPage;
|
|
42
|
+
this.getItems = getItems;
|
|
43
|
+
this.loadNextPage = loadPage;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Retrieves the next page
|
|
47
|
+
* @returns this
|
|
48
|
+
*/
|
|
49
|
+
getNextPage() {
|
|
50
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
51
|
+
const { data, rawResponse } = yield this.loadNextPage(this.response).withRawResponse();
|
|
52
|
+
this.response = data;
|
|
53
|
+
this.rawResponse = rawResponse;
|
|
54
|
+
this.data = this.getItems(this.response);
|
|
55
|
+
return this;
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* @returns whether there is a next page to load
|
|
60
|
+
*/
|
|
61
|
+
hasNextPage() {
|
|
62
|
+
return this._hasNextPage(this.response);
|
|
63
|
+
}
|
|
64
|
+
iterMessages() {
|
|
65
|
+
return __asyncGenerator(this, arguments, function* iterMessages_1() {
|
|
66
|
+
for (const item of this.data) {
|
|
67
|
+
yield yield __await(item);
|
|
68
|
+
}
|
|
69
|
+
while (this.hasNextPage()) {
|
|
70
|
+
yield __await(this.getNextPage());
|
|
71
|
+
for (const item of this.data) {
|
|
72
|
+
yield yield __await(item);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
[Symbol.asyncIterator]() {
|
|
78
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
79
|
+
var _b, e_1, _c, _d;
|
|
80
|
+
try {
|
|
81
|
+
for (var _e = true, _f = __asyncValues(this.iterMessages()), _g; _g = yield __await(_f.next()), _b = _g.done, !_b; _e = true) {
|
|
82
|
+
_d = _g.value;
|
|
83
|
+
_e = false;
|
|
84
|
+
const message = _d;
|
|
85
|
+
yield yield __await(message);
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
89
|
+
finally {
|
|
90
|
+
try {
|
|
91
|
+
if (!_e && !_b && (_c = _f.return)) yield __await(_c.call(_f));
|
|
92
|
+
}
|
|
93
|
+
finally { if (e_1) throw e_1.error; }
|
|
94
|
+
}
|
|
95
|
+
});
|
|
96
|
+
}
|
|
97
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type { Page } from "./Page.mjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Page } from "./Page.mjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Page } from "./Page.mjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { setObjectProperty } from "./setObjectProperty.mjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { setObjectProperty } from "./setObjectProperty.mjs";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sets the value at path of object. If a portion of path doesn’t exist it’s created. This is
|
|
3
|
+
* inspired by Lodash's set function, but is simplified to accommodate our use case.
|
|
4
|
+
* For more details, see https://lodash.com/docs/4.17.15#set.
|
|
5
|
+
*
|
|
6
|
+
* @param object The object to modify.
|
|
7
|
+
* @param path The path of the property to set.
|
|
8
|
+
* @param value The value to set.
|
|
9
|
+
* @return Returns object.
|
|
10
|
+
*/
|
|
11
|
+
export declare function setObjectProperty<T extends object>(object: T, path: string, value: any): T;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sets the value at path of object. If a portion of path doesn’t exist it’s created. This is
|
|
3
|
+
* inspired by Lodash's set function, but is simplified to accommodate our use case.
|
|
4
|
+
* For more details, see https://lodash.com/docs/4.17.15#set.
|
|
5
|
+
*
|
|
6
|
+
* @param object The object to modify.
|
|
7
|
+
* @param path The path of the property to set.
|
|
8
|
+
* @param value The value to set.
|
|
9
|
+
* @return Returns object.
|
|
10
|
+
*/
|
|
11
|
+
export function setObjectProperty(object, path, value) {
|
|
12
|
+
if (object == null) {
|
|
13
|
+
return object;
|
|
14
|
+
}
|
|
15
|
+
const keys = path.split(".");
|
|
16
|
+
if (keys.length === 0) {
|
|
17
|
+
// Invalid path; do nothing.
|
|
18
|
+
return object;
|
|
19
|
+
}
|
|
20
|
+
let current = object;
|
|
21
|
+
for (let i = 0; i < keys.length - 1; i++) {
|
|
22
|
+
const key = keys[i];
|
|
23
|
+
if (key == null) {
|
|
24
|
+
// Unreachable.
|
|
25
|
+
continue;
|
|
26
|
+
}
|
|
27
|
+
if (!current[key] || typeof current[key] !== "object") {
|
|
28
|
+
current[key] = {};
|
|
29
|
+
}
|
|
30
|
+
current = current[key];
|
|
31
|
+
}
|
|
32
|
+
const lastKey = keys[keys.length - 1];
|
|
33
|
+
if (lastKey == null) {
|
|
34
|
+
// Unreachable.
|
|
35
|
+
return object;
|
|
36
|
+
}
|
|
37
|
+
current[lastKey] = value;
|
|
38
|
+
return object;
|
|
39
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type * as events from "./events.mjs";
|
|
2
|
+
import type * as ws from "./ws.mjs";
|
|
3
|
+
export type ReconnectingWebSocket = typeof ws.ReconnectingWebSocket;
|
|
4
|
+
export declare namespace ReconnectingWebSocket {
|
|
5
|
+
type Event = events.Event;
|
|
6
|
+
type CloseEvent = events.CloseEvent;
|
|
7
|
+
type ErrorEvent = events.ErrorEvent;
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./core/exports.mjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./core/exports.mjs";
|
package/dist/esm/index.d.mts
CHANGED
|
@@ -3,4 +3,5 @@ export type { BaseClientOptions, BaseRequestOptions } from "./BaseClient.mjs";
|
|
|
3
3
|
export { AgentMailClient } from "./Client.mjs";
|
|
4
4
|
export { AgentMailEnvironment, type AgentMailEnvironmentUrls } from "./environments.mjs";
|
|
5
5
|
export { AgentMailError, AgentMailTimeoutError } from "./errors/index.mjs";
|
|
6
|
+
export * from "./exports.mjs";
|
|
6
7
|
export * as serialization from "./serialization/index.mjs";
|
package/dist/esm/index.mjs
CHANGED
|
@@ -2,4 +2,5 @@ export * as AgentMail from "./api/index.mjs";
|
|
|
2
2
|
export { AgentMailClient } from "./Client.mjs";
|
|
3
3
|
export { AgentMailEnvironment } from "./environments.mjs";
|
|
4
4
|
export { AgentMailError, AgentMailTimeoutError } from "./errors/index.mjs";
|
|
5
|
+
export * from "./exports.mjs";
|
|
5
6
|
export * as serialization from "./serialization/index.mjs";
|
|
@@ -3,12 +3,14 @@ import * as core from "../../../../core/index.mjs";
|
|
|
3
3
|
import type * as serializers from "../../../index.mjs";
|
|
4
4
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
5
5
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
6
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
6
7
|
import { Recipient } from "./Recipient.mjs";
|
|
7
8
|
import { Timestamp } from "./Timestamp.mjs";
|
|
8
9
|
export declare const Bounce: core.serialization.ObjectSchema<serializers.Bounce.Raw, AgentMail.Bounce>;
|
|
9
10
|
export declare namespace Bounce {
|
|
10
11
|
interface Raw {
|
|
11
12
|
inbox_id: InboxId.Raw;
|
|
13
|
+
thread_id: ThreadId.Raw;
|
|
12
14
|
message_id: MessageId.Raw;
|
|
13
15
|
timestamp: Timestamp.Raw;
|
|
14
16
|
type: string;
|
|
@@ -2,10 +2,12 @@
|
|
|
2
2
|
import * as core from "../../../../core/index.mjs";
|
|
3
3
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
4
4
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
5
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
5
6
|
import { Recipient } from "./Recipient.mjs";
|
|
6
7
|
import { Timestamp } from "./Timestamp.mjs";
|
|
7
8
|
export const Bounce = core.serialization.object({
|
|
8
9
|
inboxId: core.serialization.property("inbox_id", InboxId),
|
|
10
|
+
threadId: core.serialization.property("thread_id", ThreadId),
|
|
9
11
|
messageId: core.serialization.property("message_id", MessageId),
|
|
10
12
|
timestamp: Timestamp,
|
|
11
13
|
type: core.serialization.string(),
|
|
@@ -3,11 +3,13 @@ import * as core from "../../../../core/index.mjs";
|
|
|
3
3
|
import type * as serializers from "../../../index.mjs";
|
|
4
4
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
5
5
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
6
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
6
7
|
import { Timestamp } from "./Timestamp.mjs";
|
|
7
8
|
export declare const Complaint: core.serialization.ObjectSchema<serializers.Complaint.Raw, AgentMail.Complaint>;
|
|
8
9
|
export declare namespace Complaint {
|
|
9
10
|
interface Raw {
|
|
10
11
|
inbox_id: InboxId.Raw;
|
|
12
|
+
thread_id: ThreadId.Raw;
|
|
11
13
|
message_id: MessageId.Raw;
|
|
12
14
|
timestamp: Timestamp.Raw;
|
|
13
15
|
type: string;
|
|
@@ -2,9 +2,11 @@
|
|
|
2
2
|
import * as core from "../../../../core/index.mjs";
|
|
3
3
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
4
4
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
5
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
5
6
|
import { Timestamp } from "./Timestamp.mjs";
|
|
6
7
|
export const Complaint = core.serialization.object({
|
|
7
8
|
inboxId: core.serialization.property("inbox_id", InboxId),
|
|
9
|
+
threadId: core.serialization.property("thread_id", ThreadId),
|
|
8
10
|
messageId: core.serialization.property("message_id", MessageId),
|
|
9
11
|
timestamp: Timestamp,
|
|
10
12
|
type: core.serialization.string(),
|
|
@@ -3,11 +3,13 @@ import * as core from "../../../../core/index.mjs";
|
|
|
3
3
|
import type * as serializers from "../../../index.mjs";
|
|
4
4
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
5
5
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
6
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
6
7
|
import { Timestamp } from "./Timestamp.mjs";
|
|
7
8
|
export declare const Delivery: core.serialization.ObjectSchema<serializers.Delivery.Raw, AgentMail.Delivery>;
|
|
8
9
|
export declare namespace Delivery {
|
|
9
10
|
interface Raw {
|
|
10
11
|
inbox_id: InboxId.Raw;
|
|
12
|
+
thread_id: ThreadId.Raw;
|
|
11
13
|
message_id: MessageId.Raw;
|
|
12
14
|
timestamp: Timestamp.Raw;
|
|
13
15
|
recipients: string[];
|
|
@@ -2,9 +2,11 @@
|
|
|
2
2
|
import * as core from "../../../../core/index.mjs";
|
|
3
3
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
4
4
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
5
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
5
6
|
import { Timestamp } from "./Timestamp.mjs";
|
|
6
7
|
export const Delivery = core.serialization.object({
|
|
7
8
|
inboxId: core.serialization.property("inbox_id", InboxId),
|
|
9
|
+
threadId: core.serialization.property("thread_id", ThreadId),
|
|
8
10
|
messageId: core.serialization.property("message_id", MessageId),
|
|
9
11
|
timestamp: Timestamp,
|
|
10
12
|
recipients: core.serialization.list(core.serialization.string()),
|
|
@@ -3,11 +3,13 @@ import * as core from "../../../../core/index.mjs";
|
|
|
3
3
|
import type * as serializers from "../../../index.mjs";
|
|
4
4
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
5
5
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
6
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
6
7
|
import { Timestamp } from "./Timestamp.mjs";
|
|
7
8
|
export declare const Reject: core.serialization.ObjectSchema<serializers.Reject.Raw, AgentMail.Reject>;
|
|
8
9
|
export declare namespace Reject {
|
|
9
10
|
interface Raw {
|
|
10
11
|
inbox_id: InboxId.Raw;
|
|
12
|
+
thread_id: ThreadId.Raw;
|
|
11
13
|
message_id: MessageId.Raw;
|
|
12
14
|
timestamp: Timestamp.Raw;
|
|
13
15
|
reason: string;
|
|
@@ -2,9 +2,11 @@
|
|
|
2
2
|
import * as core from "../../../../core/index.mjs";
|
|
3
3
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
4
4
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
5
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
5
6
|
import { Timestamp } from "./Timestamp.mjs";
|
|
6
7
|
export const Reject = core.serialization.object({
|
|
7
8
|
inboxId: core.serialization.property("inbox_id", InboxId),
|
|
9
|
+
threadId: core.serialization.property("thread_id", ThreadId),
|
|
8
10
|
messageId: core.serialization.property("message_id", MessageId),
|
|
9
11
|
timestamp: Timestamp,
|
|
10
12
|
reason: core.serialization.string(),
|
|
@@ -3,11 +3,13 @@ import * as core from "../../../../core/index.mjs";
|
|
|
3
3
|
import type * as serializers from "../../../index.mjs";
|
|
4
4
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
5
5
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
6
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
6
7
|
import { Timestamp } from "./Timestamp.mjs";
|
|
7
8
|
export declare const Send: core.serialization.ObjectSchema<serializers.Send.Raw, AgentMail.Send>;
|
|
8
9
|
export declare namespace Send {
|
|
9
10
|
interface Raw {
|
|
10
11
|
inbox_id: InboxId.Raw;
|
|
12
|
+
thread_id: ThreadId.Raw;
|
|
11
13
|
message_id: MessageId.Raw;
|
|
12
14
|
timestamp: Timestamp.Raw;
|
|
13
15
|
recipients: string[];
|
|
@@ -2,9 +2,11 @@
|
|
|
2
2
|
import * as core from "../../../../core/index.mjs";
|
|
3
3
|
import { InboxId } from "../../inboxes/types/InboxId.mjs";
|
|
4
4
|
import { MessageId } from "../../messages/types/MessageId.mjs";
|
|
5
|
+
import { ThreadId } from "../../threads/types/ThreadId.mjs";
|
|
5
6
|
import { Timestamp } from "./Timestamp.mjs";
|
|
6
7
|
export const Send = core.serialization.object({
|
|
7
8
|
inboxId: core.serialization.property("inbox_id", InboxId),
|
|
9
|
+
threadId: core.serialization.property("thread_id", ThreadId),
|
|
8
10
|
messageId: core.serialization.property("message_id", MessageId),
|
|
9
11
|
timestamp: Timestamp,
|
|
10
12
|
recipients: core.serialization.list(core.serialization.string()),
|
package/dist/esm/version.d.mts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.
|
|
1
|
+
export declare const SDK_VERSION = "0.1.1";
|
package/dist/esm/version.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const SDK_VERSION = "0.
|
|
1
|
+
export const SDK_VERSION = "0.1.1";
|