@heymantle/core-api-client 0.2.3 → 0.3.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/dist/index.d.mts +888 -74
- package/dist/index.d.ts +888 -74
- package/dist/index.js +35 -14
- package/dist/index.mjs +35 -14
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -568,6 +568,9 @@ var DealsResource = class extends BaseResource {
|
|
|
568
568
|
|
|
569
569
|
// src/resources/docs.ts
|
|
570
570
|
var DocsResource = class extends BaseResource {
|
|
571
|
+
async getTree(params) {
|
|
572
|
+
return this.unwrap(this.api.GET("/docs/tree", { params: { query: params } }));
|
|
573
|
+
}
|
|
571
574
|
async listCollections(params) {
|
|
572
575
|
return this.unwrap(this.api.GET("/docs/collections", { params: { query: params } }));
|
|
573
576
|
}
|
|
@@ -580,6 +583,9 @@ var DocsResource = class extends BaseResource {
|
|
|
580
583
|
async createGroup(data) {
|
|
581
584
|
return this.unwrap(this.api.POST("/docs/groups", { body: data }));
|
|
582
585
|
}
|
|
586
|
+
async generatePage(data) {
|
|
587
|
+
return this.unwrap(this.api.POST("/docs/pages/generate", { body: data }));
|
|
588
|
+
}
|
|
583
589
|
async listPages(params) {
|
|
584
590
|
return this.unwrap(this.api.GET("/docs/pages", { params: { query: params } }));
|
|
585
591
|
}
|
|
@@ -589,6 +595,18 @@ var DocsResource = class extends BaseResource {
|
|
|
589
595
|
async listRepositories(params) {
|
|
590
596
|
return this.unwrap(this.api.GET("/docs/repositories", { params: { query: params } }));
|
|
591
597
|
}
|
|
598
|
+
async archivePage(pageId) {
|
|
599
|
+
return this.unwrap(this.api.POST("/docs/pages/{page_id}/archive", { params: { path: { page_id: pageId } } }));
|
|
600
|
+
}
|
|
601
|
+
async unarchivePage(pageId) {
|
|
602
|
+
return this.unwrap(this.api.DELETE("/docs/pages/{page_id}/archive", { params: { path: { page_id: pageId } } }));
|
|
603
|
+
}
|
|
604
|
+
async publishPage(pageId, data) {
|
|
605
|
+
return this.unwrap(this.api.POST("/docs/pages/{page_id}/publish", { params: { path: { page_id: pageId } }, body: data }));
|
|
606
|
+
}
|
|
607
|
+
async unpublishPage(pageId) {
|
|
608
|
+
return this.unwrap(this.api.DELETE("/docs/pages/{page_id}/publish", { params: { path: { page_id: pageId } } }));
|
|
609
|
+
}
|
|
592
610
|
async updateCollection(collectionId, data) {
|
|
593
611
|
return this.unwrap(this.api.PUT("/docs/collections/{collection_id}", { params: { path: { collection_id: collectionId } }, body: data }));
|
|
594
612
|
}
|
|
@@ -610,9 +628,15 @@ var DocsResource = class extends BaseResource {
|
|
|
610
628
|
async deletePage(pageId) {
|
|
611
629
|
return this.unwrap(this.api.DELETE("/docs/pages/{page_id}", { params: { path: { page_id: pageId } } }));
|
|
612
630
|
}
|
|
631
|
+
async getStatus(jobKey) {
|
|
632
|
+
return this.unwrap(this.api.GET("/docs/pages/generate/status/{jobKey}", { params: { path: { jobKey } } }));
|
|
633
|
+
}
|
|
613
634
|
async getRepository(docId, params) {
|
|
614
635
|
return this.unwrap(this.api.GET("/docs/repositories/{id}", { params: { path: { id: docId }, query: params } }));
|
|
615
636
|
}
|
|
637
|
+
async regeneratePage(pageId, data) {
|
|
638
|
+
return this.unwrap(this.api.POST("/docs/pages/{page_id}/generate", { params: { path: { page_id: pageId } }, body: data }));
|
|
639
|
+
}
|
|
616
640
|
};
|
|
617
641
|
|
|
618
642
|
// src/resources/email-unsubscribe-groups.ts
|
|
@@ -620,7 +644,7 @@ var EmailUnsubscribeGroupsResource = class extends BaseResource {
|
|
|
620
644
|
async list() {
|
|
621
645
|
return this.unwrap(this.api.GET("/email/unsubscribe_groups"));
|
|
622
646
|
}
|
|
623
|
-
async
|
|
647
|
+
async deleteMember(groupId, memberId) {
|
|
624
648
|
return this.unwrap(this.api.DELETE("/email/unsubscribe_groups/{id}/members/{member_id}", { params: { path: { id: groupId, member_id: memberId } } }));
|
|
625
649
|
}
|
|
626
650
|
async listMembers(groupId) {
|
|
@@ -629,6 +653,9 @@ var EmailUnsubscribeGroupsResource = class extends BaseResource {
|
|
|
629
653
|
async createMember(groupId, data) {
|
|
630
654
|
return this.unwrap(this.api.POST("/email/unsubscribe_groups/{id}/members", { params: { path: { id: groupId } }, body: data }));
|
|
631
655
|
}
|
|
656
|
+
async deleteMembers(groupId, params) {
|
|
657
|
+
return this.unwrap(this.api.DELETE("/email/unsubscribe_groups/{id}/members", { params: { path: { id: groupId }, query: params } }));
|
|
658
|
+
}
|
|
632
659
|
};
|
|
633
660
|
|
|
634
661
|
// src/resources/entities.ts
|
|
@@ -649,7 +676,7 @@ var FlowExtensionsResource = class extends BaseResource {
|
|
|
649
676
|
async listTriggers() {
|
|
650
677
|
return this.unwrap(this.api.GET("/flow/extensions/triggers"));
|
|
651
678
|
}
|
|
652
|
-
async
|
|
679
|
+
async createTriggerByHandle(data) {
|
|
653
680
|
return this.unwrap(this.api.POST("/flow/extensions/triggers", { body: data }));
|
|
654
681
|
}
|
|
655
682
|
async validateSchema(data) {
|
|
@@ -764,10 +791,10 @@ var MeetingsResource = class extends BaseResource {
|
|
|
764
791
|
async updateAttendee(meetingId, attendeeId, data) {
|
|
765
792
|
return this.unwrap(this.api.PUT("/meetings/{id}/attendees/{attendeeId}", { params: { path: { id: meetingId, attendeeId } }, body: data }));
|
|
766
793
|
}
|
|
767
|
-
async
|
|
794
|
+
async getTranscription(meetingId) {
|
|
768
795
|
return this.unwrap(this.api.GET("/meetings/{id}/transcribe", { params: { path: { id: meetingId } } }));
|
|
769
796
|
}
|
|
770
|
-
async
|
|
797
|
+
async transcribe(meetingId, data) {
|
|
771
798
|
return this.unwrap(this.api.POST("/meetings/{id}/transcribe", { params: { path: { id: meetingId } }, body: data }));
|
|
772
799
|
}
|
|
773
800
|
async transcribeUpload(meetingId, data) {
|
|
@@ -1029,17 +1056,11 @@ var WebhooksResource = class extends BaseResource {
|
|
|
1029
1056
|
|
|
1030
1057
|
// src/resources/agents.ts
|
|
1031
1058
|
var AgentsResource = class extends BaseResource {
|
|
1032
|
-
async list() {
|
|
1033
|
-
return this.unwrap(this.
|
|
1034
|
-
}
|
|
1035
|
-
async get(agentId) {
|
|
1036
|
-
return this.unwrap(this.untypedApi.GET("/agents/{id}", { params: { path: { id: agentId } } }));
|
|
1037
|
-
}
|
|
1038
|
-
async create(params) {
|
|
1039
|
-
return this.unwrap(this.untypedApi.POST("/agents", { body: params }));
|
|
1059
|
+
async list(params) {
|
|
1060
|
+
return this.unwrap(this.api.GET("/agents", { params: { query: params } }));
|
|
1040
1061
|
}
|
|
1041
|
-
async findOrCreate(
|
|
1042
|
-
return this.unwrap(this.
|
|
1062
|
+
async findOrCreate(data) {
|
|
1063
|
+
return this.unwrap(this.api.POST("/agents", { body: data }));
|
|
1043
1064
|
}
|
|
1044
1065
|
};
|
|
1045
1066
|
|
package/dist/index.mjs
CHANGED
|
@@ -485,6 +485,9 @@ var DealsResource = class extends BaseResource {
|
|
|
485
485
|
|
|
486
486
|
// src/resources/docs.ts
|
|
487
487
|
var DocsResource = class extends BaseResource {
|
|
488
|
+
async getTree(params) {
|
|
489
|
+
return this.unwrap(this.api.GET("/docs/tree", { params: { query: params } }));
|
|
490
|
+
}
|
|
488
491
|
async listCollections(params) {
|
|
489
492
|
return this.unwrap(this.api.GET("/docs/collections", { params: { query: params } }));
|
|
490
493
|
}
|
|
@@ -497,6 +500,9 @@ var DocsResource = class extends BaseResource {
|
|
|
497
500
|
async createGroup(data) {
|
|
498
501
|
return this.unwrap(this.api.POST("/docs/groups", { body: data }));
|
|
499
502
|
}
|
|
503
|
+
async generatePage(data) {
|
|
504
|
+
return this.unwrap(this.api.POST("/docs/pages/generate", { body: data }));
|
|
505
|
+
}
|
|
500
506
|
async listPages(params) {
|
|
501
507
|
return this.unwrap(this.api.GET("/docs/pages", { params: { query: params } }));
|
|
502
508
|
}
|
|
@@ -506,6 +512,18 @@ var DocsResource = class extends BaseResource {
|
|
|
506
512
|
async listRepositories(params) {
|
|
507
513
|
return this.unwrap(this.api.GET("/docs/repositories", { params: { query: params } }));
|
|
508
514
|
}
|
|
515
|
+
async archivePage(pageId) {
|
|
516
|
+
return this.unwrap(this.api.POST("/docs/pages/{page_id}/archive", { params: { path: { page_id: pageId } } }));
|
|
517
|
+
}
|
|
518
|
+
async unarchivePage(pageId) {
|
|
519
|
+
return this.unwrap(this.api.DELETE("/docs/pages/{page_id}/archive", { params: { path: { page_id: pageId } } }));
|
|
520
|
+
}
|
|
521
|
+
async publishPage(pageId, data) {
|
|
522
|
+
return this.unwrap(this.api.POST("/docs/pages/{page_id}/publish", { params: { path: { page_id: pageId } }, body: data }));
|
|
523
|
+
}
|
|
524
|
+
async unpublishPage(pageId) {
|
|
525
|
+
return this.unwrap(this.api.DELETE("/docs/pages/{page_id}/publish", { params: { path: { page_id: pageId } } }));
|
|
526
|
+
}
|
|
509
527
|
async updateCollection(collectionId, data) {
|
|
510
528
|
return this.unwrap(this.api.PUT("/docs/collections/{collection_id}", { params: { path: { collection_id: collectionId } }, body: data }));
|
|
511
529
|
}
|
|
@@ -527,9 +545,15 @@ var DocsResource = class extends BaseResource {
|
|
|
527
545
|
async deletePage(pageId) {
|
|
528
546
|
return this.unwrap(this.api.DELETE("/docs/pages/{page_id}", { params: { path: { page_id: pageId } } }));
|
|
529
547
|
}
|
|
548
|
+
async getStatus(jobKey) {
|
|
549
|
+
return this.unwrap(this.api.GET("/docs/pages/generate/status/{jobKey}", { params: { path: { jobKey } } }));
|
|
550
|
+
}
|
|
530
551
|
async getRepository(docId, params) {
|
|
531
552
|
return this.unwrap(this.api.GET("/docs/repositories/{id}", { params: { path: { id: docId }, query: params } }));
|
|
532
553
|
}
|
|
554
|
+
async regeneratePage(pageId, data) {
|
|
555
|
+
return this.unwrap(this.api.POST("/docs/pages/{page_id}/generate", { params: { path: { page_id: pageId } }, body: data }));
|
|
556
|
+
}
|
|
533
557
|
};
|
|
534
558
|
|
|
535
559
|
// src/resources/email-unsubscribe-groups.ts
|
|
@@ -537,7 +561,7 @@ var EmailUnsubscribeGroupsResource = class extends BaseResource {
|
|
|
537
561
|
async list() {
|
|
538
562
|
return this.unwrap(this.api.GET("/email/unsubscribe_groups"));
|
|
539
563
|
}
|
|
540
|
-
async
|
|
564
|
+
async deleteMember(groupId, memberId) {
|
|
541
565
|
return this.unwrap(this.api.DELETE("/email/unsubscribe_groups/{id}/members/{member_id}", { params: { path: { id: groupId, member_id: memberId } } }));
|
|
542
566
|
}
|
|
543
567
|
async listMembers(groupId) {
|
|
@@ -546,6 +570,9 @@ var EmailUnsubscribeGroupsResource = class extends BaseResource {
|
|
|
546
570
|
async createMember(groupId, data) {
|
|
547
571
|
return this.unwrap(this.api.POST("/email/unsubscribe_groups/{id}/members", { params: { path: { id: groupId } }, body: data }));
|
|
548
572
|
}
|
|
573
|
+
async deleteMembers(groupId, params) {
|
|
574
|
+
return this.unwrap(this.api.DELETE("/email/unsubscribe_groups/{id}/members", { params: { path: { id: groupId }, query: params } }));
|
|
575
|
+
}
|
|
549
576
|
};
|
|
550
577
|
|
|
551
578
|
// src/resources/entities.ts
|
|
@@ -566,7 +593,7 @@ var FlowExtensionsResource = class extends BaseResource {
|
|
|
566
593
|
async listTriggers() {
|
|
567
594
|
return this.unwrap(this.api.GET("/flow/extensions/triggers"));
|
|
568
595
|
}
|
|
569
|
-
async
|
|
596
|
+
async createTriggerByHandle(data) {
|
|
570
597
|
return this.unwrap(this.api.POST("/flow/extensions/triggers", { body: data }));
|
|
571
598
|
}
|
|
572
599
|
async validateSchema(data) {
|
|
@@ -681,10 +708,10 @@ var MeetingsResource = class extends BaseResource {
|
|
|
681
708
|
async updateAttendee(meetingId, attendeeId, data) {
|
|
682
709
|
return this.unwrap(this.api.PUT("/meetings/{id}/attendees/{attendeeId}", { params: { path: { id: meetingId, attendeeId } }, body: data }));
|
|
683
710
|
}
|
|
684
|
-
async
|
|
711
|
+
async getTranscription(meetingId) {
|
|
685
712
|
return this.unwrap(this.api.GET("/meetings/{id}/transcribe", { params: { path: { id: meetingId } } }));
|
|
686
713
|
}
|
|
687
|
-
async
|
|
714
|
+
async transcribe(meetingId, data) {
|
|
688
715
|
return this.unwrap(this.api.POST("/meetings/{id}/transcribe", { params: { path: { id: meetingId } }, body: data }));
|
|
689
716
|
}
|
|
690
717
|
async transcribeUpload(meetingId, data) {
|
|
@@ -946,17 +973,11 @@ var WebhooksResource = class extends BaseResource {
|
|
|
946
973
|
|
|
947
974
|
// src/resources/agents.ts
|
|
948
975
|
var AgentsResource = class extends BaseResource {
|
|
949
|
-
async list() {
|
|
950
|
-
return this.unwrap(this.
|
|
951
|
-
}
|
|
952
|
-
async get(agentId) {
|
|
953
|
-
return this.unwrap(this.untypedApi.GET("/agents/{id}", { params: { path: { id: agentId } } }));
|
|
954
|
-
}
|
|
955
|
-
async create(params) {
|
|
956
|
-
return this.unwrap(this.untypedApi.POST("/agents", { body: params }));
|
|
976
|
+
async list(params) {
|
|
977
|
+
return this.unwrap(this.api.GET("/agents", { params: { query: params } }));
|
|
957
978
|
}
|
|
958
|
-
async findOrCreate(
|
|
959
|
-
return this.unwrap(this.
|
|
979
|
+
async findOrCreate(data) {
|
|
980
|
+
return this.unwrap(this.api.POST("/agents", { body: data }));
|
|
960
981
|
}
|
|
961
982
|
};
|
|
962
983
|
|