agentmail 0.3.5 → 0.3.6
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/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/wrapper/WebsocketsClient.js +7 -4
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/dist/esm/wrapper/WebsocketsClient.mjs +7 -4
- package/dist/llms-full.txt +5151 -965
- package/package.json +1 -1
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
|
|
|
43
43
|
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
44
|
"X-Fern-Language": "JavaScript",
|
|
45
45
|
"X-Fern-SDK-Name": "agentmail",
|
|
46
|
-
"X-Fern-SDK-Version": "0.3.
|
|
47
|
-
"User-Agent": "agentmail/0.3.
|
|
46
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
47
|
+
"User-Agent": "agentmail/0.3.6",
|
|
48
48
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
49
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
50
|
}, options === null || options === void 0 ? void 0 : options.headers);
|
package/dist/cjs/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.3.
|
|
1
|
+
export declare const SDK_VERSION = "0.3.6";
|
package/dist/cjs/version.js
CHANGED
|
@@ -57,17 +57,20 @@ class WebsocketsClient extends Client_js_1.WebsocketsClient {
|
|
|
57
57
|
});
|
|
58
58
|
return __awaiter(this, arguments, void 0, function* (args = {}) {
|
|
59
59
|
var _a, _b, _c;
|
|
60
|
+
let connectArgs = args;
|
|
60
61
|
if (this._getPaymentCredentials) {
|
|
61
62
|
const wsUrl = core.url.join((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.AgentMailEnvironment.Prod)
|
|
62
63
|
.websockets, "/v0");
|
|
63
64
|
const credentials = yield this._getPaymentCredentials(wsUrl);
|
|
64
|
-
|
|
65
|
+
connectArgs = Object.assign(Object.assign({}, args), { queryParams: Object.assign(Object.assign({}, credentials), args.queryParams) });
|
|
65
66
|
}
|
|
66
|
-
if (!args.apiKey) {
|
|
67
|
+
else if (!args.apiKey) {
|
|
67
68
|
const apiKey = (_c = (yield core.Supplier.get(this._options.apiKey))) !== null && _c !== void 0 ? _c : process.env.AGENTMAIL_API_KEY;
|
|
68
|
-
|
|
69
|
+
connectArgs = Object.assign(Object.assign({}, args), { apiKey });
|
|
69
70
|
}
|
|
70
|
-
|
|
71
|
+
const socket = yield _super.connect.call(this, connectArgs);
|
|
72
|
+
yield socket.waitForOpen();
|
|
73
|
+
return socket;
|
|
71
74
|
});
|
|
72
75
|
}
|
|
73
76
|
}
|
package/dist/esm/BaseClient.mjs
CHANGED
|
@@ -6,8 +6,8 @@ export function normalizeClientOptions(options) {
|
|
|
6
6
|
const headers = mergeHeaders({
|
|
7
7
|
"X-Fern-Language": "JavaScript",
|
|
8
8
|
"X-Fern-SDK-Name": "agentmail",
|
|
9
|
-
"X-Fern-SDK-Version": "0.3.
|
|
10
|
-
"User-Agent": "agentmail/0.3.
|
|
9
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
10
|
+
"User-Agent": "agentmail/0.3.6",
|
|
11
11
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
12
12
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
13
13
|
}, options === null || options === void 0 ? void 0 : options.headers);
|
package/dist/esm/version.d.mts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.3.
|
|
1
|
+
export declare const SDK_VERSION = "0.3.6";
|
package/dist/esm/version.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const SDK_VERSION = "0.3.
|
|
1
|
+
export const SDK_VERSION = "0.3.6";
|
|
@@ -21,17 +21,20 @@ export class WebsocketsClient extends FernWebsocketsClient {
|
|
|
21
21
|
});
|
|
22
22
|
return __awaiter(this, arguments, void 0, function* (args = {}) {
|
|
23
23
|
var _a, _b, _c;
|
|
24
|
+
let connectArgs = args;
|
|
24
25
|
if (this._getPaymentCredentials) {
|
|
25
26
|
const wsUrl = core.url.join((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.AgentMailEnvironment.Prod)
|
|
26
27
|
.websockets, "/v0");
|
|
27
28
|
const credentials = yield this._getPaymentCredentials(wsUrl);
|
|
28
|
-
|
|
29
|
+
connectArgs = Object.assign(Object.assign({}, args), { queryParams: Object.assign(Object.assign({}, credentials), args.queryParams) });
|
|
29
30
|
}
|
|
30
|
-
if (!args.apiKey) {
|
|
31
|
+
else if (!args.apiKey) {
|
|
31
32
|
const apiKey = (_c = (yield core.Supplier.get(this._options.apiKey))) !== null && _c !== void 0 ? _c : process.env.AGENTMAIL_API_KEY;
|
|
32
|
-
|
|
33
|
+
connectArgs = Object.assign(Object.assign({}, args), { apiKey });
|
|
33
34
|
}
|
|
34
|
-
|
|
35
|
+
const socket = yield _super.connect.call(this, connectArgs);
|
|
36
|
+
yield socket.waitForOpen();
|
|
37
|
+
return socket;
|
|
35
38
|
});
|
|
36
39
|
}
|
|
37
40
|
}
|