@unlimited-messaging/sdk 0.1.26 → 0.1.28
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unlimited-messaging/sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.28",
|
|
4
4
|
"description": "TypeScript / Node.js SDK for the Unlimited Messaging API — send and receive WhatsApp messages programmatically",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"types": "src/index.d.ts",
|
|
@@ -83,7 +83,7 @@ export declare namespace Accounts {
|
|
|
83
83
|
* ```
|
|
84
84
|
*
|
|
85
85
|
* Failures answer `422` with `context.code`: `AUTH_FAILED` (wrong password, or an app password is
|
|
86
|
-
* required), `OAUTH_REQUIRED`, `HOST_UNREACHABLE`, `TLS_ERROR
|
|
86
|
+
* required), `OAUTH_REQUIRED`, `HOST_UNREACHABLE`, `TLS_ERROR`.
|
|
87
87
|
* When the password changes, or the server starts refusing it (status `INACTIVE`), send the new one
|
|
88
88
|
* with `PUT /account/{accountId}/email`.
|
|
89
89
|
*
|
|
@@ -93,10 +93,8 @@ export declare namespace Accounts {
|
|
|
93
93
|
* both channels too:
|
|
94
94
|
*
|
|
95
95
|
* - **WhatsApp**: the `add-account` tool shows the QR code in the chat, to scan like above.
|
|
96
|
-
* - **Email**: `add-email-account`
|
|
97
|
-
* themselves
|
|
98
|
-
* address and password (or app password) in the chat instead: the tool finds the servers and
|
|
99
|
-
* connects the mailbox directly.
|
|
96
|
+
* - **Email**: `add-email-account` gives the link to the dashboard, where the user types the password
|
|
97
|
+
* themselves: it never goes through the conversation.
|
|
100
98
|
*/
|
|
101
99
|
export declare class Accounts {
|
|
102
100
|
protected readonly _options: Accounts.Options;
|
|
@@ -187,7 +185,7 @@ export declare class Accounts {
|
|
|
187
185
|
/**
|
|
188
186
|
* **Protection**: Protected endpoint. Allowed roles: USER, ADMIN. Required scopes: OTHER:READ, OTHER:WRITE
|
|
189
187
|
*
|
|
190
|
-
* Tests the credentials and connects the mailbox as an EMAIL account. There is no QR code or challenge: the account is ACTIVE as soon as this returns. Its id is then the `accountId` to send email from with POST /message, and incoming email arrives as `message.received` webhooks. Gmail, iCloud and Yahoo require an app password. Same error codes as POST /account/email/test
|
|
188
|
+
* Tests the credentials and connects the mailbox as an EMAIL account. There is no QR code or challenge: the account is ACTIVE as soon as this returns. Its id is then the `accountId` to send email from with POST /message, and incoming email arrives as `message.received` webhooks. Gmail, iCloud and Yahoo require an app password. Same error codes as POST /account/email/test. A mailbox already connected elsewhere (on another of your accounts or on another user) connects anyway as its own account; connecting an address you already have reuses that account with the new credentials.
|
|
191
189
|
*
|
|
192
190
|
* @param {UnlimitedMessagingApi.AccountConnectEmailRequest} request
|
|
193
191
|
* @param {Accounts.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -116,7 +116,7 @@ const errors = __importStar(require("../../../../errors/index"));
|
|
|
116
116
|
* ```
|
|
117
117
|
*
|
|
118
118
|
* Failures answer `422` with `context.code`: `AUTH_FAILED` (wrong password, or an app password is
|
|
119
|
-
* required), `OAUTH_REQUIRED`, `HOST_UNREACHABLE`, `TLS_ERROR
|
|
119
|
+
* required), `OAUTH_REQUIRED`, `HOST_UNREACHABLE`, `TLS_ERROR`.
|
|
120
120
|
* When the password changes, or the server starts refusing it (status `INACTIVE`), send the new one
|
|
121
121
|
* with `PUT /account/{accountId}/email`.
|
|
122
122
|
*
|
|
@@ -126,10 +126,8 @@ const errors = __importStar(require("../../../../errors/index"));
|
|
|
126
126
|
* both channels too:
|
|
127
127
|
*
|
|
128
128
|
* - **WhatsApp**: the `add-account` tool shows the QR code in the chat, to scan like above.
|
|
129
|
-
* - **Email**: `add-email-account`
|
|
130
|
-
* themselves
|
|
131
|
-
* address and password (or app password) in the chat instead: the tool finds the servers and
|
|
132
|
-
* connects the mailbox directly.
|
|
129
|
+
* - **Email**: `add-email-account` gives the link to the dashboard, where the user types the password
|
|
130
|
+
* themselves: it never goes through the conversation.
|
|
133
131
|
*/
|
|
134
132
|
class Accounts {
|
|
135
133
|
constructor(_options) {
|
|
@@ -481,7 +479,7 @@ class Accounts {
|
|
|
481
479
|
/**
|
|
482
480
|
* **Protection**: Protected endpoint. Allowed roles: USER, ADMIN. Required scopes: OTHER:READ, OTHER:WRITE
|
|
483
481
|
*
|
|
484
|
-
* Tests the credentials and connects the mailbox as an EMAIL account. There is no QR code or challenge: the account is ACTIVE as soon as this returns. Its id is then the `accountId` to send email from with POST /message, and incoming email arrives as `message.received` webhooks. Gmail, iCloud and Yahoo require an app password. Same error codes as POST /account/email/test
|
|
482
|
+
* Tests the credentials and connects the mailbox as an EMAIL account. There is no QR code or challenge: the account is ACTIVE as soon as this returns. Its id is then the `accountId` to send email from with POST /message, and incoming email arrives as `message.received` webhooks. Gmail, iCloud and Yahoo require an app password. Same error codes as POST /account/email/test. A mailbox already connected elsewhere (on another of your accounts or on another user) connects anyway as its own account; connecting an address you already have reuses that account with the new credentials.
|
|
485
483
|
*
|
|
486
484
|
* @param {UnlimitedMessagingApi.AccountConnectEmailRequest} request
|
|
487
485
|
* @param {Accounts.RequestOptions} requestOptions - Request-specific configuration.
|