@smartlyqofficial/node 0.1.18 → 0.1.20

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 CHANGED
@@ -160,6 +160,10 @@ All methods below are available on the client. Full request/response documentati
160
160
  | `sq.automations.activate(automationId)` | `POST /automations/{automation_id}/activate` | Activate automation |
161
161
  | `sq.automations.deactivate(automationId)` | `POST /automations/{automation_id}/deactivate` | Pause automation |
162
162
  | `sq.automations.trigger(automationId, body?)` | `POST /automations/{automation_id}/trigger` | Trigger automation |
163
+ | `sq.automations.duplicate(automationId)` | `POST /automations/{automation_id}/duplicate` | Duplicate an automation |
164
+ | `sq.automations.listVersions(automationId)` | `GET /automations/{automation_id}/versions` | List automation versions |
165
+ | `sq.automations.getVersion(automationId, version)` | `GET /automations/{automation_id}/versions/{version}` | Get one automation version |
166
+ | `sq.automations.restoreVersion(automationId, version)` | `POST /automations/{automation_id}/versions/{version}/restore` | Restore an automation version |
163
167
  | `sq.automations.listRuns(automationId, query?)` | `GET /automations/{automation_id}/runs` | List runs |
164
168
  | `sq.automations.getRun(automationId, runId)` | `GET /automations/{automation_id}/runs/{run_id}` | Get run |
165
169
 
@@ -185,6 +189,9 @@ All methods below are available on the client. Full request/response documentati
185
189
  | `sq.comments.list(query?)` | `GET /social/comments` | List comments |
186
190
  | `sq.comments.replyTo(commentId, body)` | `POST /social/comments/{comment_id}/reply` | Reply to a comment |
187
191
  | `sq.comments.hide(commentId)` | `POST /social/comments/{comment_id}/hide` | Hide or unhide a comment |
192
+ | `sq.comments.moderate(commentId, body)` | `POST /social/comments/{comment_id}/moderate` | Approve or reject a comment |
193
+ | `sq.comments.like(commentId)` | `POST /social/comments/{comment_id}/like` | Like a comment |
194
+ | `sq.comments.unlike(commentId)` | `DELETE /social/comments/{comment_id}/like` | Unlike a comment |
188
195
  | `sq.comments.delete(commentId)` | `DELETE /social/comments/{comment_id}` | Delete a comment |
189
196
  | `sq.comments.getPost(postId)` | `GET /social/comments/{post_id}` | Get one post's comments (threaded) |
190
197
 
@@ -250,6 +257,7 @@ All methods below are available on the client. Full request/response documentati
250
257
  | `sq.messages.list(conversationId, query?)` | `GET /social/conversations/{conversation_id}/messages` | List messages in a conversation |
251
258
  | `sq.messages.send(conversationId, body)` | `POST /social/conversations/{conversation_id}/messages` | Send a direct message |
252
259
  | `sq.messages.markConversationRead(conversationId)` | `POST /social/conversations/{conversation_id}/read` | Mark a conversation read |
260
+ | `sq.messages.delete(conversationId, messageId)` | `DELETE /social/conversations/{conversation_id}/messages/{message_id}` | Delete a sent message |
253
261
  | `sq.messages.reactTo(conversationId, messageId, body)` | `POST /social/conversations/{conversation_id}/messages/{message_id}/reactions` | React to a message |
254
262
  | `sq.messages.removeReaction(conversationId, messageId)` | `DELETE /social/conversations/{conversation_id}/messages/{message_id}/reactions` | Remove a message reaction |
255
263
 
package/dist/index.cjs CHANGED
@@ -355,6 +355,22 @@ var AutomationsResource = class {
355
355
  trigger(automationId, body, options) {
356
356
  return this._client.request("POST", `/automations/${encodeURIComponent(automationId)}/trigger`, { body, options });
357
357
  }
358
+ /** Duplicate an automation `POST /automations/{automation_id}/duplicate` */
359
+ duplicate(automationId, options) {
360
+ return this._client.request("POST", `/automations/${encodeURIComponent(automationId)}/duplicate`, { options });
361
+ }
362
+ /** List automation versions `GET /automations/{automation_id}/versions` */
363
+ listVersions(automationId, options) {
364
+ return this._client.request("GET", `/automations/${encodeURIComponent(automationId)}/versions`, { options });
365
+ }
366
+ /** Get one automation version `GET /automations/{automation_id}/versions/{version}` */
367
+ getVersion(automationId, version, options) {
368
+ return this._client.request("GET", `/automations/${encodeURIComponent(automationId)}/versions/${encodeURIComponent(version)}`, { options });
369
+ }
370
+ /** Restore an automation version `POST /automations/{automation_id}/versions/{version}/restore` */
371
+ restoreVersion(automationId, version, options) {
372
+ return this._client.request("POST", `/automations/${encodeURIComponent(automationId)}/versions/${encodeURIComponent(version)}/restore`, { options });
373
+ }
358
374
  /** List runs `GET /automations/{automation_id}/runs` */
359
375
  listRuns(automationId, query, options) {
360
376
  return this._client.request("GET", `/automations/${encodeURIComponent(automationId)}/runs`, { query, options });
@@ -425,6 +441,18 @@ var CommentsResource = class {
425
441
  hide(commentId, options) {
426
442
  return this._client.request("POST", `/social/comments/${encodeURIComponent(commentId)}/hide`, { options });
427
443
  }
444
+ /** Approve or reject a comment `POST /social/comments/{comment_id}/moderate` */
445
+ moderate(commentId, body, options) {
446
+ return this._client.request("POST", `/social/comments/${encodeURIComponent(commentId)}/moderate`, { body, options });
447
+ }
448
+ /** Like a comment `POST /social/comments/{comment_id}/like` */
449
+ like(commentId, options) {
450
+ return this._client.request("POST", `/social/comments/${encodeURIComponent(commentId)}/like`, { options });
451
+ }
452
+ /** Unlike a comment `DELETE /social/comments/{comment_id}/like` */
453
+ unlike(commentId, options) {
454
+ return this._client.request("DELETE", `/social/comments/${encodeURIComponent(commentId)}/like`, { options });
455
+ }
428
456
  /** Delete a comment `DELETE /social/comments/{comment_id}` */
429
457
  delete(commentId, options) {
430
458
  return this._client.request("DELETE", `/social/comments/${encodeURIComponent(commentId)}`, { options });
@@ -595,6 +623,10 @@ var MessagesResource = class {
595
623
  markConversationRead(conversationId, options) {
596
624
  return this._client.request("POST", `/social/conversations/${encodeURIComponent(conversationId)}/read`, { options });
597
625
  }
626
+ /** Delete a sent message `DELETE /social/conversations/{conversation_id}/messages/{message_id}` */
627
+ delete(conversationId, messageId, options) {
628
+ return this._client.request("DELETE", `/social/conversations/${encodeURIComponent(conversationId)}/messages/${encodeURIComponent(messageId)}`, { options });
629
+ }
598
630
  /** React to a message `POST /social/conversations/{conversation_id}/messages/{message_id}/reactions` */
599
631
  reactTo(conversationId, messageId, body, options) {
600
632
  return this._client.request("POST", `/social/conversations/${encodeURIComponent(conversationId)}/messages/${encodeURIComponent(messageId)}/reactions`, { body, options });