@smartlyqofficial/node 0.1.27 → 0.1.29
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 +42 -0
- package/dist/index.cjs +120 -0
- package/dist/index.d.cts +796 -2
- package/dist/index.d.ts +796 -2
- package/dist/index.js +116 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -489,6 +489,27 @@ var AutomationsResource = class {
|
|
|
489
489
|
return this._client.request("GET", `/automations/${encodeURIComponent(automationId)}/runs/${encodeURIComponent(runId)}`, { options });
|
|
490
490
|
}
|
|
491
491
|
};
|
|
492
|
+
var CalendarResource = class {
|
|
493
|
+
constructor(_client) {
|
|
494
|
+
this._client = _client;
|
|
495
|
+
}
|
|
496
|
+
/** List booking pages `GET /calendar/event-types` */
|
|
497
|
+
listEventTypes(options) {
|
|
498
|
+
return this._client.request("GET", "/calendar/event-types", { options });
|
|
499
|
+
}
|
|
500
|
+
/** List open slots `GET /calendar/slots` */
|
|
501
|
+
listSlots(query, options) {
|
|
502
|
+
return this._client.request("GET", "/calendar/slots", { query, options });
|
|
503
|
+
}
|
|
504
|
+
/** Take a booking `POST /calendar/bookings` */
|
|
505
|
+
createBooking(body, options) {
|
|
506
|
+
return this._client.request("POST", "/calendar/bookings", { body, options });
|
|
507
|
+
}
|
|
508
|
+
/** Cancel a booking `POST /calendar/bookings/{id}/cancel` */
|
|
509
|
+
cancelBooking(id, body, options) {
|
|
510
|
+
return this._client.request("POST", `/calendar/bookings/${encodeURIComponent(id)}/cancel`, { body, options });
|
|
511
|
+
}
|
|
512
|
+
};
|
|
492
513
|
var ChatbotsResource = class {
|
|
493
514
|
constructor(_client) {
|
|
494
515
|
this._client = _client;
|
|
@@ -605,6 +626,39 @@ var CrmResource = class {
|
|
|
605
626
|
return this._client.request("GET", `/contacts/${encodeURIComponent(id)}/channels`, { options });
|
|
606
627
|
}
|
|
607
628
|
};
|
|
629
|
+
var CrmCompaniesResource = class {
|
|
630
|
+
constructor(_client) {
|
|
631
|
+
this._client = _client;
|
|
632
|
+
}
|
|
633
|
+
/** List companies `GET /companies` */
|
|
634
|
+
list(query, options) {
|
|
635
|
+
return this._client.request("GET", "/companies", { query, options });
|
|
636
|
+
}
|
|
637
|
+
/** Create a company `POST /companies` */
|
|
638
|
+
create(body, options) {
|
|
639
|
+
return this._client.request("POST", "/companies", { body, options });
|
|
640
|
+
}
|
|
641
|
+
/** Get a company `GET /companies/{id}` */
|
|
642
|
+
get(id, options) {
|
|
643
|
+
return this._client.request("GET", `/companies/${encodeURIComponent(id)}`, { options });
|
|
644
|
+
}
|
|
645
|
+
/** Update a company `PATCH /companies/{id}` */
|
|
646
|
+
update(id, body, options) {
|
|
647
|
+
return this._client.request("PATCH", `/companies/${encodeURIComponent(id)}`, { body, options });
|
|
648
|
+
}
|
|
649
|
+
/** Delete a company `DELETE /companies/{id}` */
|
|
650
|
+
delete(id, options) {
|
|
651
|
+
return this._client.request("DELETE", `/companies/${encodeURIComponent(id)}`, { options });
|
|
652
|
+
}
|
|
653
|
+
/** Link a contact to a company `POST /companies/{id}/contacts` */
|
|
654
|
+
linkContact(id, body, options) {
|
|
655
|
+
return this._client.request("POST", `/companies/${encodeURIComponent(id)}/contacts`, { body, options });
|
|
656
|
+
}
|
|
657
|
+
/** Unlink a contact from a company `DELETE /companies/{id}/contacts` */
|
|
658
|
+
unlinkContact(id, body, options) {
|
|
659
|
+
return this._client.request("DELETE", `/companies/${encodeURIComponent(id)}/contacts`, { body, options });
|
|
660
|
+
}
|
|
661
|
+
};
|
|
608
662
|
var ContactsResource = class {
|
|
609
663
|
constructor(_client) {
|
|
610
664
|
this._client = _client;
|
|
@@ -712,6 +766,60 @@ var OpportunitiesResource = class {
|
|
|
712
766
|
return this._client.request("POST", `/opportunities/${encodeURIComponent(id)}/status`, { body, options });
|
|
713
767
|
}
|
|
714
768
|
};
|
|
769
|
+
var CrmTagsResource = class {
|
|
770
|
+
constructor(_client) {
|
|
771
|
+
this._client = _client;
|
|
772
|
+
}
|
|
773
|
+
/** List tags `GET /tags` */
|
|
774
|
+
list(options) {
|
|
775
|
+
return this._client.request("GET", "/tags", { options });
|
|
776
|
+
}
|
|
777
|
+
/** Create a tag `POST /tags` */
|
|
778
|
+
create(body, options) {
|
|
779
|
+
return this._client.request("POST", "/tags", { body, options });
|
|
780
|
+
}
|
|
781
|
+
/** Rename a tag `POST /tags/rename` */
|
|
782
|
+
rename(body, options) {
|
|
783
|
+
return this._client.request("POST", "/tags/rename", { body, options });
|
|
784
|
+
}
|
|
785
|
+
/** Merge tags `POST /tags/merge` */
|
|
786
|
+
merge(body, options) {
|
|
787
|
+
return this._client.request("POST", "/tags/merge", { body, options });
|
|
788
|
+
}
|
|
789
|
+
/** Delete a tag `POST /tags/delete` */
|
|
790
|
+
delete(body, options) {
|
|
791
|
+
return this._client.request("POST", "/tags/delete", { body, options });
|
|
792
|
+
}
|
|
793
|
+
};
|
|
794
|
+
var CrmTasksResource = class {
|
|
795
|
+
constructor(_client) {
|
|
796
|
+
this._client = _client;
|
|
797
|
+
}
|
|
798
|
+
/** List tasks `GET /tasks` */
|
|
799
|
+
list(query, options) {
|
|
800
|
+
return this._client.request("GET", "/tasks", { query, options });
|
|
801
|
+
}
|
|
802
|
+
/** Create a task `POST /tasks` */
|
|
803
|
+
create(body, options) {
|
|
804
|
+
return this._client.request("POST", "/tasks", { body, options });
|
|
805
|
+
}
|
|
806
|
+
/** Get a task `GET /tasks/{id}` */
|
|
807
|
+
get(id, options) {
|
|
808
|
+
return this._client.request("GET", `/tasks/${encodeURIComponent(id)}`, { options });
|
|
809
|
+
}
|
|
810
|
+
/** Update a task `PATCH /tasks/{id}` */
|
|
811
|
+
update(id, body, options) {
|
|
812
|
+
return this._client.request("PATCH", `/tasks/${encodeURIComponent(id)}`, { body, options });
|
|
813
|
+
}
|
|
814
|
+
/** Delete a task `DELETE /tasks/{id}` */
|
|
815
|
+
delete(id, options) {
|
|
816
|
+
return this._client.request("DELETE", `/tasks/${encodeURIComponent(id)}`, { options });
|
|
817
|
+
}
|
|
818
|
+
/** Log time on a task `POST /tasks/{id}/time` */
|
|
819
|
+
logTime(id, body, options) {
|
|
820
|
+
return this._client.request("POST", `/tasks/${encodeURIComponent(id)}/time`, { body, options });
|
|
821
|
+
}
|
|
822
|
+
};
|
|
715
823
|
var MessagesResource = class {
|
|
716
824
|
constructor(_client) {
|
|
717
825
|
this._client = _client;
|
|
@@ -1705,13 +1813,17 @@ function createResources(client) {
|
|
|
1705
1813
|
articles: new ArticlesResource(client),
|
|
1706
1814
|
audio: new AudioResource(client),
|
|
1707
1815
|
automations: new AutomationsResource(client),
|
|
1816
|
+
calendar: new CalendarResource(client),
|
|
1708
1817
|
chatbots: new ChatbotsResource(client),
|
|
1709
1818
|
comments: new CommentsResource(client),
|
|
1710
1819
|
content: new ContentResource(client),
|
|
1711
1820
|
crm: new CrmResource(client),
|
|
1821
|
+
crmCompanies: new CrmCompaniesResource(client),
|
|
1712
1822
|
contacts: new ContactsResource(client),
|
|
1713
1823
|
customFields: new CustomFieldsResource(client),
|
|
1714
1824
|
opportunities: new OpportunitiesResource(client),
|
|
1825
|
+
crmTags: new CrmTagsResource(client),
|
|
1826
|
+
crmTasks: new CrmTasksResource(client),
|
|
1715
1827
|
messages: new MessagesResource(client),
|
|
1716
1828
|
images: new ImagesResource(client),
|
|
1717
1829
|
jobs: new JobsResource(client),
|
|
@@ -1747,13 +1859,17 @@ export {
|
|
|
1747
1859
|
ArticlesResource,
|
|
1748
1860
|
AudioResource,
|
|
1749
1861
|
AutomationsResource,
|
|
1862
|
+
CalendarResource,
|
|
1750
1863
|
CaptainResource,
|
|
1751
1864
|
ChatbotsResource,
|
|
1752
1865
|
CommentsResource,
|
|
1753
1866
|
ContactsResource,
|
|
1754
1867
|
ContentResource,
|
|
1755
1868
|
CoreClient,
|
|
1869
|
+
CrmCompaniesResource,
|
|
1756
1870
|
CrmResource,
|
|
1871
|
+
CrmTagsResource,
|
|
1872
|
+
CrmTasksResource,
|
|
1757
1873
|
CustomFieldsResource,
|
|
1758
1874
|
ImagesResource,
|
|
1759
1875
|
JobsResource,
|