crisp-api 9.3.1 → 9.5.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,6 +1,20 @@
1
1
  Changelog
2
2
  =========
3
3
 
4
+ ## v9.5.0
5
+
6
+ ### New Features
7
+
8
+ * Added support for the `message:acknowledge:ignored` RTM API event.
9
+
10
+ ## v9.4.0
11
+
12
+ ### Breaking Changes
13
+
14
+ * ⚠️ Changed the `verify` argument of the `CrispClient.website.inviteWebsiteOperator` method (to be a verification challenge).
15
+ * ⚠️ Changed the `verify` argument of the `CrispClient.website.deleteHelpdesk` method (to be a verification challenge).
16
+ * ⚠️ Changed the `verify` argument of the `CrispClient.website.deleteWebsite` method (to be a verification challenge).
17
+
4
18
  ## v9.3.1
5
19
 
6
20
  ### Breaking Changes
package/EXAMPLES.md CHANGED
@@ -948,7 +948,10 @@ https://docs.crisp.chat/references/rest-api/v1/#delete-helpdesk
948
948
 
949
949
  var websiteID = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc";
950
950
 
951
- var verify = "MySuperSecurePassword";
951
+ var verify = {
952
+ "method": "password",
953
+ "secret": "MySuperSecurePassword";
954
+ };
952
955
 
953
956
  CrispClient.website.deleteHelpdesk(websiteID, verify);
954
957
 
@@ -1581,7 +1584,10 @@ https://docs.crisp.chat/references/rest-api/v1/#delete-a-website
1581
1584
 
1582
1585
  var websiteID = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc";
1583
1586
 
1584
- var verify = "MySuperSecurePassword";
1587
+ var verify = {
1588
+ "method": "password",
1589
+ "secret": "MySuperSecurePassword";
1590
+ };
1585
1591
 
1586
1592
  CrispClient.website.deleteWebsite(websiteID, verify);
1587
1593
 
@@ -1736,7 +1742,11 @@ var websiteID = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc";
1736
1742
 
1737
1743
  var email = "julien@crisp.chat";
1738
1744
  var role = "member";
1739
- var verify = "MySuperSecurePassword";
1745
+
1746
+ var verify = {
1747
+ "method": "password",
1748
+ "secret": "MySuperSecurePassword";
1749
+ };
1740
1750
 
1741
1751
  CrispClient.website.inviteWebsiteOperator(websiteID, email, role, verify);
1742
1752
 
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2023 Crisp
3
+ Copyright (c) 2024 Crisp
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -4,9 +4,9 @@
4
4
 
5
5
  The Crisp API Node wrapper. Authenticate, send messages, fetch conversations, access your agent accounts from your JavaScript code.
6
6
 
7
- Copyright 2023 Crisp IM SAS. See LICENSE for copying information.
7
+ Copyright 2024 Crisp IM SAS. See LICENSE for copying information.
8
8
 
9
- * **📝 Implements**: [REST API Reference (V1)](https://docs.crisp.chat/references/rest-api/v1/) at revision: 27/08/2024
9
+ * **📝 Implements**: [REST API Reference (V1)](https://docs.crisp.chat/references/rest-api/v1/) at revision: 17/10/2024
10
10
  * **😘 Maintainers**: [@baptistejamin](https://github.com/baptistejamin), [@eliottvincent](https://github.com/eliottvincent), [@valeriansaliou](https://github.com/valeriansaliou)
11
11
 
12
12
  ## Installation
@@ -1457,7 +1457,10 @@ _👉 Notice: The `peopleID` argument can be an email or the `peopleID`._
1457
1457
  ```javascript
1458
1458
  var websiteID = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc";
1459
1459
 
1460
- var verify = "MySuperSecurePassword";
1460
+ var verify = {
1461
+ "method": "password",
1462
+ "secret": "MySuperSecurePassword";
1463
+ };
1461
1464
 
1462
1465
  CrispClient.website.deleteHelpdesk(websiteID, verify);
1463
1466
  ```
@@ -2309,7 +2312,10 @@ _👉 Notice: The `peopleID` argument can be an email or the `peopleID`._
2309
2312
  ```javascript
2310
2313
  var websiteID = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc";
2311
2314
 
2312
- var verify = "MySuperSecurePassword";
2315
+ var verify = {
2316
+ "method": "password",
2317
+ "secret": "MySuperSecurePassword";
2318
+ };
2313
2319
 
2314
2320
  CrispClient.website.deleteWebsite(websiteID, verify);
2315
2321
  ```
@@ -2504,7 +2510,11 @@ _👉 Notice: The `peopleID` argument can be an email or the `peopleID`._
2504
2510
 
2505
2511
  var email = "julien@crisp.chat";
2506
2512
  var role = "member";
2507
- var verify = "MySuperSecurePassword";
2513
+
2514
+ var verify = {
2515
+ "method": "password",
2516
+ "secret": "MySuperSecurePassword";
2517
+ };
2508
2518
 
2509
2519
  CrispClient.website.inviteWebsiteOperator(websiteID, email, role, verify);
2510
2520
  ```
@@ -3516,6 +3526,8 @@ Available events are listed below:
3516
3526
  * `message:acknowledge:read:received`
3517
3527
  * **Message Acknowledge Delivered** [`user`, `plugin`]:
3518
3528
  * `message:acknowledge:delivered`
3529
+ * **Message Acknowledge Ignored** [`user`, `plugin`]:
3530
+ * `message:acknowledge:ignored`
3519
3531
  * **Message Notify Unread Send** [`user`, `plugin`]:
3520
3532
  * `message:notify:unread:send`
3521
3533
  * **Message Notify Unread Received** [`user`, `plugin`]:
package/lib/crisp.js CHANGED
@@ -92,6 +92,7 @@ Crisp.DEFAULT_RTM_EVENTS = [
92
92
  "message:acknowledge:read:send",
93
93
  "message:acknowledge:read:received",
94
94
  "message:acknowledge:delivered",
95
+ "message:acknowledge:ignored",
95
96
  "message:notify:unread:send",
96
97
  "message:notify:unread:received",
97
98
 
@@ -67,7 +67,7 @@ function WebsiteBase(service, crisp) {
67
67
  * @public
68
68
  * @method deleteWebsite
69
69
  * @param {string} websiteID
70
- * @param {string} verify
70
+ * @param {object} verify
71
71
  * @return {Promise}
72
72
  */
73
73
  service.deleteWebsite = function(websiteID, verify) {
@@ -70,7 +70,7 @@ function WebsiteHelpdesk(service, crisp) {
70
70
  * @public
71
71
  * @method deleteHelpdesk
72
72
  * @param {string} websiteID
73
- * @param {string} verify
73
+ * @param {object} verify
74
74
  * @return {Promise}
75
75
  */
76
76
  service.deleteHelpdesk = function(websiteID, verify) {
@@ -105,7 +105,7 @@ function WebsiteOperator(service, crisp) {
105
105
  * @param {string} websiteID
106
106
  * @param {string} email
107
107
  * @param {string} role
108
- * @param {string} verify
108
+ * @param {object} verify
109
109
  * @return {Promise}
110
110
  */
111
111
  service.inviteWebsiteOperator = function(websiteID, email, role, verify) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "crisp-api",
3
3
  "description": "Crisp API wrapper for Node - official, maintained by Crisp",
4
- "version": "9.3.1",
4
+ "version": "9.5.0",
5
5
  "homepage": "https://github.com/crisp-im/node-crisp-api",
6
6
  "license": "MIT",
7
7
  "author": {