@cstar.help/js 0.16.1 → 0.17.2
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 +100 -60
- package/dist/auth/index.d.cts +3 -398
- package/dist/auth/index.d.ts +3 -398
- package/dist/chat/index.cjs +427 -101
- package/dist/chat/index.d.cts +44 -92
- package/dist/chat/index.d.ts +44 -92
- package/dist/chat/index.js +427 -101
- package/dist/community/index.d.cts +4 -586
- package/dist/community/index.d.ts +4 -586
- package/dist/errors-b5A4wfAg.d.cts +398 -0
- package/dist/errors-b5A4wfAg.d.ts +398 -0
- package/dist/index.cjs +42 -23
- package/dist/index.d.cts +24 -802
- package/dist/index.d.ts +24 -802
- package/dist/index.js +42 -23
- package/dist/library/index.d.cts +3 -398
- package/dist/library/index.d.ts +3 -398
- package/dist/quickhelp/index.d.cts +3 -398
- package/dist/quickhelp/index.d.ts +3 -398
- package/dist/types-DF7GprCV.d.cts +190 -0
- package/dist/types-DF7GprCV.d.ts +190 -0
- package/dist/webhook/index.d.cts +2 -434
- package/dist/webhook/index.d.ts +2 -434
- package/dist/webhook/node.d.cts +4 -450
- package/dist/webhook/node.d.ts +4 -450
- package/dist/webhookEvents-1N2i2GcQ.d.cts +449 -0
- package/dist/webhookEvents-1N2i2GcQ.d.ts +449 -0
- package/package.json +4 -4
package/dist/index.d.cts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
import { W as WebhookEventType, a as WebhookEventDataMap } from './webhookEvents-1N2i2GcQ.cjs';
|
|
2
|
+
export { b as WEBHOOK_EVENT_CATALOG, c as WEBHOOK_EVENT_SAMPLES, d as WebhookEvent } from './webhookEvents-1N2i2GcQ.cjs';
|
|
3
|
+
export { A as ApiErrorBody, C as CStarAuthenticationError, a as CStarConflictError, b as CStarError, c as CStarFeatureDisabledError, d as CStarNotFoundError, e as CStarPermissionError, f as CStarRateLimitError, h as CStarServerError, i as CStarValidationError, E as ErrorType } from './errors-b5A4wfAg.cjs';
|
|
4
|
+
|
|
1
5
|
/** Metadata: string key-value pairs. Max 50 keys, 40-char keys, 500-char values. */
|
|
2
6
|
type Metadata = Record<string, string>;
|
|
3
7
|
/** Standard pagination parameters accepted by list endpoints. */
|
|
@@ -66,6 +70,7 @@ interface ClientConfig {
|
|
|
66
70
|
teamId: string;
|
|
67
71
|
baseUrl?: string;
|
|
68
72
|
version?: string;
|
|
73
|
+
/** Retry count. POST/PATCH network and 5xx retries require an idempotency key. */
|
|
69
74
|
maxRetries?: number;
|
|
70
75
|
timeout?: number;
|
|
71
76
|
}
|
|
@@ -97,7 +102,8 @@ declare class HttpClient {
|
|
|
97
102
|
constructor(config: ClientConfig);
|
|
98
103
|
/**
|
|
99
104
|
* Make an authenticated request to the cStar API.
|
|
100
|
-
* Automatically retries
|
|
105
|
+
* Automatically retries rate limits and retry-safe failures. POST/PATCH
|
|
106
|
+
* network and 5xx failures require an idempotency key to avoid duplicate writes.
|
|
101
107
|
*/
|
|
102
108
|
request<T>(method: string, path: string, options?: FetchOptions): Promise<T>;
|
|
103
109
|
/**
|
|
@@ -239,7 +245,7 @@ declare class CStarRealtime {
|
|
|
239
245
|
connect(): void;
|
|
240
246
|
/**
|
|
241
247
|
* Open the EventSource with the given auth token.
|
|
242
|
-
*
|
|
248
|
+
* Secret keys reach this method only after exchanging for an SSE token.
|
|
243
249
|
*/
|
|
244
250
|
private connectWithToken;
|
|
245
251
|
/** Stop listening and clean up all resources. */
|
|
@@ -373,6 +379,8 @@ declare class Subscription$1<T = unknown> {
|
|
|
373
379
|
private destroyed;
|
|
374
380
|
/** Generation counter to prevent stale refresh() from overwriting SSE updates. */
|
|
375
381
|
private generation;
|
|
382
|
+
/** Replay events against the initial snapshot instead of discarding that snapshot. */
|
|
383
|
+
private initialEvents;
|
|
376
384
|
constructor(realtime: CStarRealtime, fetchFn: () => Promise<ListResponse<T>>, resourcePath: string, filterFn?: ((item: T) => boolean) | undefined);
|
|
377
385
|
/** Current data array (updated in real-time). */
|
|
378
386
|
get data(): T[];
|
|
@@ -590,454 +598,6 @@ declare class ArticlesResource extends BaseResource<Article, ArticleListParams,
|
|
|
590
598
|
constructor(client: HttpClient);
|
|
591
599
|
}
|
|
592
600
|
|
|
593
|
-
/** Every webhook event type cStar can dispatch. */
|
|
594
|
-
type WebhookEventType = 'agent.preferences_updated' | 'article.created' | 'article.deleted' | 'article.published' | 'article.updated' | 'boss.damaged' | 'boss.defeated' | 'boss.spawned' | 'community_post.commented' | 'community_post.created' | 'community_post.deleted' | 'community_post.status_changed' | 'community_post.updated' | 'community_post.voted' | 'customer.created' | 'customer.deleted' | 'customer.updated' | 'customer_group.created' | 'customer_group.deleted' | 'customer_group.updated' | 'player.achievement_unlocked' | 'player.level_up' | 'player.quest_completed' | 'player.streak_milestone' | 'player.xp_gained' | 'social.high_five_sent' | 'social.one_up_sent' | 'survey.submitted' | 'team.preferences_updated' | 'ticket.assigned' | 'ticket.closed' | 'ticket.created' | 'ticket.deleted' | 'ticket.message_added' | 'ticket.updated';
|
|
595
|
-
/** Payload for `agent.preferences_updated` events. */
|
|
596
|
-
interface AgentPreferencesUpdatedPayload {
|
|
597
|
-
team_id: string;
|
|
598
|
-
member_id: string;
|
|
599
|
-
agent_id: string;
|
|
600
|
-
changed: Array<string>;
|
|
601
|
-
preferences: {
|
|
602
|
-
boringMode: boolean;
|
|
603
|
-
};
|
|
604
|
-
}
|
|
605
|
-
/** Payload for `article.created` events. */
|
|
606
|
-
interface ArticleCreatedPayload {
|
|
607
|
-
article: {
|
|
608
|
-
id: string;
|
|
609
|
-
title: string;
|
|
610
|
-
slug: string;
|
|
611
|
-
is_public: boolean;
|
|
612
|
-
created_at: string;
|
|
613
|
-
};
|
|
614
|
-
}
|
|
615
|
-
/** Payload for `article.deleted` events. */
|
|
616
|
-
interface ArticleDeletedPayload {
|
|
617
|
-
id: string;
|
|
618
|
-
}
|
|
619
|
-
/** Payload for `article.published` events. */
|
|
620
|
-
interface ArticlePublishedPayload {
|
|
621
|
-
article: {
|
|
622
|
-
id: string;
|
|
623
|
-
title: string;
|
|
624
|
-
slug: string;
|
|
625
|
-
is_public: boolean;
|
|
626
|
-
published_at: string;
|
|
627
|
-
};
|
|
628
|
-
}
|
|
629
|
-
/** Payload for `article.updated` events. */
|
|
630
|
-
interface ArticleUpdatedPayload {
|
|
631
|
-
article: {
|
|
632
|
-
id: string;
|
|
633
|
-
title: string;
|
|
634
|
-
slug: string;
|
|
635
|
-
is_public: boolean;
|
|
636
|
-
};
|
|
637
|
-
}
|
|
638
|
-
/** Payload for `boss.damaged` events. */
|
|
639
|
-
interface BossDamagedPayload {
|
|
640
|
-
boss: {
|
|
641
|
-
id: string;
|
|
642
|
-
current_hp: number;
|
|
643
|
-
};
|
|
644
|
-
damage: number;
|
|
645
|
-
by: {
|
|
646
|
-
agent_id: string;
|
|
647
|
-
name: string;
|
|
648
|
-
};
|
|
649
|
-
}
|
|
650
|
-
/** Payload for `boss.defeated` events. */
|
|
651
|
-
interface BossDefeatedPayload {
|
|
652
|
-
boss: {
|
|
653
|
-
id: string;
|
|
654
|
-
name: string;
|
|
655
|
-
};
|
|
656
|
-
final_blow_by: {
|
|
657
|
-
agent_id: string;
|
|
658
|
-
name: string;
|
|
659
|
-
};
|
|
660
|
-
team_xp_awarded: number;
|
|
661
|
-
}
|
|
662
|
-
/** Payload for `boss.spawned` events. */
|
|
663
|
-
interface BossSpawnedPayload {
|
|
664
|
-
boss: {
|
|
665
|
-
id: string;
|
|
666
|
-
name: string;
|
|
667
|
-
level: number;
|
|
668
|
-
max_hp: number;
|
|
669
|
-
};
|
|
670
|
-
}
|
|
671
|
-
/** Payload for `community_post.commented` events. */
|
|
672
|
-
interface CommunityPostCommentedPayload {
|
|
673
|
-
comment: {
|
|
674
|
-
id: string;
|
|
675
|
-
post_id: string;
|
|
676
|
-
content: string;
|
|
677
|
-
author_id: string;
|
|
678
|
-
created_at: string;
|
|
679
|
-
};
|
|
680
|
-
}
|
|
681
|
-
/** Payload for `community_post.created` events. */
|
|
682
|
-
interface CommunityPostCreatedPayload {
|
|
683
|
-
post: {
|
|
684
|
-
id: string;
|
|
685
|
-
prefixed_id: string;
|
|
686
|
-
title: string;
|
|
687
|
-
status: string;
|
|
688
|
-
visibility: string;
|
|
689
|
-
topic: string;
|
|
690
|
-
created_at: string;
|
|
691
|
-
};
|
|
692
|
-
}
|
|
693
|
-
/** Payload for `community_post.deleted` events. */
|
|
694
|
-
interface CommunityPostDeletedPayload {
|
|
695
|
-
post: {
|
|
696
|
-
id: string;
|
|
697
|
-
prefixed_id?: string;
|
|
698
|
-
title?: string;
|
|
699
|
-
};
|
|
700
|
-
}
|
|
701
|
-
/** Payload for `community_post.status_changed` events. */
|
|
702
|
-
interface CommunityPostStatusChangedPayload {
|
|
703
|
-
post: {
|
|
704
|
-
id: string;
|
|
705
|
-
title: string;
|
|
706
|
-
status: string;
|
|
707
|
-
visibility: string;
|
|
708
|
-
};
|
|
709
|
-
}
|
|
710
|
-
/** Payload for `community_post.updated` events. */
|
|
711
|
-
interface CommunityPostUpdatedPayload {
|
|
712
|
-
post: {
|
|
713
|
-
id: string;
|
|
714
|
-
title: string;
|
|
715
|
-
status: string;
|
|
716
|
-
visibility: string;
|
|
717
|
-
};
|
|
718
|
-
}
|
|
719
|
-
/** Payload for `community_post.voted` events. */
|
|
720
|
-
interface CommunityPostVotedPayload {
|
|
721
|
-
post: {
|
|
722
|
-
id: string;
|
|
723
|
-
vote_count: number;
|
|
724
|
-
};
|
|
725
|
-
voter: {
|
|
726
|
-
id: string;
|
|
727
|
-
};
|
|
728
|
-
direction: string;
|
|
729
|
-
}
|
|
730
|
-
/** Payload for `customer.created` events. */
|
|
731
|
-
interface CustomerCreatedPayload {
|
|
732
|
-
customer: {
|
|
733
|
-
id: string;
|
|
734
|
-
name: string;
|
|
735
|
-
email: string;
|
|
736
|
-
status: string;
|
|
737
|
-
tags: Array<string>;
|
|
738
|
-
created_at: string;
|
|
739
|
-
};
|
|
740
|
-
}
|
|
741
|
-
/** Payload for `customer.deleted` events. */
|
|
742
|
-
interface CustomerDeletedPayload {
|
|
743
|
-
id: string;
|
|
744
|
-
}
|
|
745
|
-
/** Payload for `customer.updated` events. */
|
|
746
|
-
interface CustomerUpdatedPayload {
|
|
747
|
-
customer: {
|
|
748
|
-
id: string;
|
|
749
|
-
name: string;
|
|
750
|
-
email: string;
|
|
751
|
-
status: string;
|
|
752
|
-
tags: Array<string>;
|
|
753
|
-
};
|
|
754
|
-
changes: {
|
|
755
|
-
tags: {
|
|
756
|
-
from: Array<string>;
|
|
757
|
-
to: Array<string>;
|
|
758
|
-
};
|
|
759
|
-
};
|
|
760
|
-
}
|
|
761
|
-
/** Payload for `customer_group.created` events. */
|
|
762
|
-
interface CustomerGroupCreatedPayload {
|
|
763
|
-
group: {
|
|
764
|
-
id: string;
|
|
765
|
-
name: string;
|
|
766
|
-
color: string;
|
|
767
|
-
member_count: number;
|
|
768
|
-
};
|
|
769
|
-
}
|
|
770
|
-
/** Payload for `customer_group.deleted` events. */
|
|
771
|
-
interface CustomerGroupDeletedPayload {
|
|
772
|
-
customer_group: {
|
|
773
|
-
id: string;
|
|
774
|
-
};
|
|
775
|
-
}
|
|
776
|
-
/** Payload for `customer_group.updated` events. */
|
|
777
|
-
interface CustomerGroupUpdatedPayload {
|
|
778
|
-
group: {
|
|
779
|
-
id: string;
|
|
780
|
-
name: string;
|
|
781
|
-
color: string;
|
|
782
|
-
member_count: number;
|
|
783
|
-
};
|
|
784
|
-
}
|
|
785
|
-
/** Payload for `player.achievement_unlocked` events. */
|
|
786
|
-
interface PlayerAchievementUnlockedPayload {
|
|
787
|
-
player: {
|
|
788
|
-
agent_id: string;
|
|
789
|
-
name: string;
|
|
790
|
-
};
|
|
791
|
-
achievement: {
|
|
792
|
-
id: string;
|
|
793
|
-
name: string;
|
|
794
|
-
xp: number;
|
|
795
|
-
};
|
|
796
|
-
}
|
|
797
|
-
/** Payload for `player.level_up` events. */
|
|
798
|
-
interface PlayerLevelUpPayload {
|
|
799
|
-
player: {
|
|
800
|
-
agent_id: string;
|
|
801
|
-
name: string;
|
|
802
|
-
};
|
|
803
|
-
level: {
|
|
804
|
-
from: number;
|
|
805
|
-
to: number;
|
|
806
|
-
};
|
|
807
|
-
title_unlocked: string;
|
|
808
|
-
}
|
|
809
|
-
/** Payload for `player.quest_completed` events. */
|
|
810
|
-
interface PlayerQuestCompletedPayload {
|
|
811
|
-
player: {
|
|
812
|
-
agent_id: string;
|
|
813
|
-
name: string;
|
|
814
|
-
};
|
|
815
|
-
quest: {
|
|
816
|
-
id: string;
|
|
817
|
-
name: string;
|
|
818
|
-
xp: number;
|
|
819
|
-
};
|
|
820
|
-
}
|
|
821
|
-
/** Payload for `player.streak_milestone` events. */
|
|
822
|
-
interface PlayerStreakMilestonePayload {
|
|
823
|
-
player: {
|
|
824
|
-
agent_id: string;
|
|
825
|
-
name: string;
|
|
826
|
-
};
|
|
827
|
-
streak_days: number;
|
|
828
|
-
milestone: number;
|
|
829
|
-
}
|
|
830
|
-
/** Payload for `player.xp_gained` events. */
|
|
831
|
-
interface PlayerXpGainedPayload {
|
|
832
|
-
player: {
|
|
833
|
-
agent_id: string;
|
|
834
|
-
name: string;
|
|
835
|
-
};
|
|
836
|
-
amount: number;
|
|
837
|
-
reason: string;
|
|
838
|
-
ticket_id: string;
|
|
839
|
-
}
|
|
840
|
-
/** Payload for `social.high_five_sent` events. */
|
|
841
|
-
interface SocialHighFiveSentPayload {
|
|
842
|
-
from_team: {
|
|
843
|
-
id: string;
|
|
844
|
-
name: string;
|
|
845
|
-
};
|
|
846
|
-
to_team: {
|
|
847
|
-
id: string;
|
|
848
|
-
name: string;
|
|
849
|
-
};
|
|
850
|
-
message: string;
|
|
851
|
-
}
|
|
852
|
-
/** Payload for `social.one_up_sent` events. */
|
|
853
|
-
interface SocialOneUpSentPayload {
|
|
854
|
-
from: {
|
|
855
|
-
agent_id: string;
|
|
856
|
-
name: string;
|
|
857
|
-
};
|
|
858
|
-
to: {
|
|
859
|
-
agent_id: string;
|
|
860
|
-
name: string;
|
|
861
|
-
};
|
|
862
|
-
ticket_id: string;
|
|
863
|
-
message: string;
|
|
864
|
-
}
|
|
865
|
-
/** Payload for `survey.submitted` events. */
|
|
866
|
-
interface SurveySubmittedPayload {
|
|
867
|
-
survey: {
|
|
868
|
-
id: string;
|
|
869
|
-
ticket_id: string;
|
|
870
|
-
score: number;
|
|
871
|
-
comment: string;
|
|
872
|
-
submitted_at: string;
|
|
873
|
-
};
|
|
874
|
-
customer: {
|
|
875
|
-
id: string;
|
|
876
|
-
email: string;
|
|
877
|
-
};
|
|
878
|
-
}
|
|
879
|
-
/** Payload for `team.preferences_updated` events. */
|
|
880
|
-
interface TeamPreferencesUpdatedPayload {
|
|
881
|
-
team_id: string;
|
|
882
|
-
changed: Array<string>;
|
|
883
|
-
preferences: {
|
|
884
|
-
bossBattlesEnabled: boolean;
|
|
885
|
-
};
|
|
886
|
-
}
|
|
887
|
-
/** Payload for `ticket.assigned` events. */
|
|
888
|
-
interface TicketAssignedPayload {
|
|
889
|
-
ticket: {
|
|
890
|
-
id: string;
|
|
891
|
-
prefixed_id: string;
|
|
892
|
-
};
|
|
893
|
-
assignee: {
|
|
894
|
-
id: string;
|
|
895
|
-
name: string;
|
|
896
|
-
email: string;
|
|
897
|
-
};
|
|
898
|
-
previous_assignee: null;
|
|
899
|
-
}
|
|
900
|
-
/** Payload for `ticket.closed` events. */
|
|
901
|
-
interface TicketClosedPayload {
|
|
902
|
-
ticket: {
|
|
903
|
-
id: string;
|
|
904
|
-
prefixed_id: string;
|
|
905
|
-
title: string;
|
|
906
|
-
status: string;
|
|
907
|
-
priority: string;
|
|
908
|
-
channel: string;
|
|
909
|
-
resolved_at: string;
|
|
910
|
-
};
|
|
911
|
-
changes?: Record<string, {
|
|
912
|
-
from: string;
|
|
913
|
-
to: string;
|
|
914
|
-
}>;
|
|
915
|
-
}
|
|
916
|
-
/** Payload for `ticket.created` events. */
|
|
917
|
-
interface TicketCreatedPayload {
|
|
918
|
-
ticket: {
|
|
919
|
-
id: string;
|
|
920
|
-
prefixed_id: string;
|
|
921
|
-
title: string;
|
|
922
|
-
status: string;
|
|
923
|
-
priority: string;
|
|
924
|
-
channel: string;
|
|
925
|
-
customer_id: string;
|
|
926
|
-
created_at: string;
|
|
927
|
-
};
|
|
928
|
-
customer: {
|
|
929
|
-
id: string;
|
|
930
|
-
name: string;
|
|
931
|
-
email: string;
|
|
932
|
-
};
|
|
933
|
-
}
|
|
934
|
-
/** Payload for `ticket.deleted` events. */
|
|
935
|
-
interface TicketDeletedPayload {
|
|
936
|
-
id: string;
|
|
937
|
-
}
|
|
938
|
-
/** Payload for `ticket.message_added` events. */
|
|
939
|
-
interface TicketMessageAddedPayload {
|
|
940
|
-
ticket: {
|
|
941
|
-
id: string;
|
|
942
|
-
dashboard_url: string | null;
|
|
943
|
-
};
|
|
944
|
-
message: {
|
|
945
|
-
id: string;
|
|
946
|
-
sender: string;
|
|
947
|
-
sender_name: string | null;
|
|
948
|
-
content: string;
|
|
949
|
-
created_at: string;
|
|
950
|
-
};
|
|
951
|
-
customer?: {
|
|
952
|
-
id: string;
|
|
953
|
-
name: string | null;
|
|
954
|
-
email: string | null;
|
|
955
|
-
};
|
|
956
|
-
}
|
|
957
|
-
/** Payload for `ticket.updated` events. */
|
|
958
|
-
interface TicketUpdatedPayload {
|
|
959
|
-
ticket: {
|
|
960
|
-
id: string;
|
|
961
|
-
prefixed_id: string;
|
|
962
|
-
title: string;
|
|
963
|
-
status: string;
|
|
964
|
-
priority: string;
|
|
965
|
-
channel: string;
|
|
966
|
-
};
|
|
967
|
-
changes?: Record<string, {
|
|
968
|
-
from: string;
|
|
969
|
-
to: string;
|
|
970
|
-
} | {
|
|
971
|
-
from: Array<string>;
|
|
972
|
-
to: Array<string>;
|
|
973
|
-
}>;
|
|
974
|
-
}
|
|
975
|
-
/** Maps each event type to its payload interface — used internally for the discriminated union. */
|
|
976
|
-
interface WebhookEventDataMap {
|
|
977
|
-
'agent.preferences_updated': AgentPreferencesUpdatedPayload;
|
|
978
|
-
'article.created': ArticleCreatedPayload;
|
|
979
|
-
'article.deleted': ArticleDeletedPayload;
|
|
980
|
-
'article.published': ArticlePublishedPayload;
|
|
981
|
-
'article.updated': ArticleUpdatedPayload;
|
|
982
|
-
'boss.damaged': BossDamagedPayload;
|
|
983
|
-
'boss.defeated': BossDefeatedPayload;
|
|
984
|
-
'boss.spawned': BossSpawnedPayload;
|
|
985
|
-
'community_post.commented': CommunityPostCommentedPayload;
|
|
986
|
-
'community_post.created': CommunityPostCreatedPayload;
|
|
987
|
-
'community_post.deleted': CommunityPostDeletedPayload;
|
|
988
|
-
'community_post.status_changed': CommunityPostStatusChangedPayload;
|
|
989
|
-
'community_post.updated': CommunityPostUpdatedPayload;
|
|
990
|
-
'community_post.voted': CommunityPostVotedPayload;
|
|
991
|
-
'customer.created': CustomerCreatedPayload;
|
|
992
|
-
'customer.deleted': CustomerDeletedPayload;
|
|
993
|
-
'customer.updated': CustomerUpdatedPayload;
|
|
994
|
-
'customer_group.created': CustomerGroupCreatedPayload;
|
|
995
|
-
'customer_group.deleted': CustomerGroupDeletedPayload;
|
|
996
|
-
'customer_group.updated': CustomerGroupUpdatedPayload;
|
|
997
|
-
'player.achievement_unlocked': PlayerAchievementUnlockedPayload;
|
|
998
|
-
'player.level_up': PlayerLevelUpPayload;
|
|
999
|
-
'player.quest_completed': PlayerQuestCompletedPayload;
|
|
1000
|
-
'player.streak_milestone': PlayerStreakMilestonePayload;
|
|
1001
|
-
'player.xp_gained': PlayerXpGainedPayload;
|
|
1002
|
-
'social.high_five_sent': SocialHighFiveSentPayload;
|
|
1003
|
-
'social.one_up_sent': SocialOneUpSentPayload;
|
|
1004
|
-
'survey.submitted': SurveySubmittedPayload;
|
|
1005
|
-
'team.preferences_updated': TeamPreferencesUpdatedPayload;
|
|
1006
|
-
'ticket.assigned': TicketAssignedPayload;
|
|
1007
|
-
'ticket.closed': TicketClosedPayload;
|
|
1008
|
-
'ticket.created': TicketCreatedPayload;
|
|
1009
|
-
'ticket.deleted': TicketDeletedPayload;
|
|
1010
|
-
'ticket.message_added': TicketMessageAddedPayload;
|
|
1011
|
-
'ticket.updated': TicketUpdatedPayload;
|
|
1012
|
-
}
|
|
1013
|
-
/** A webhook event delivered to your endpoint. */
|
|
1014
|
-
interface WebhookEvent<T extends WebhookEventType = WebhookEventType> {
|
|
1015
|
-
/** Unique event ID (idempotency key). */
|
|
1016
|
-
id: string;
|
|
1017
|
-
/** Event type. */
|
|
1018
|
-
type: T;
|
|
1019
|
-
/** When the event was created (ISO 8601). */
|
|
1020
|
-
created_at: string;
|
|
1021
|
-
/** Team that owns this event. */
|
|
1022
|
-
team_id: string;
|
|
1023
|
-
/** Event-specific payload. */
|
|
1024
|
-
data: WebhookEventDataMap[T];
|
|
1025
|
-
}
|
|
1026
|
-
/**
|
|
1027
|
-
* Stable representative payloads for each event type. Useful for testing
|
|
1028
|
-
* your endpoint against realistic shapes without having to trigger a real
|
|
1029
|
-
* event. Mirrors the dashboard's event catalog.
|
|
1030
|
-
*/
|
|
1031
|
-
declare const WEBHOOK_EVENT_SAMPLES: {
|
|
1032
|
-
[K in WebhookEventType]: WebhookEventDataMap[K];
|
|
1033
|
-
};
|
|
1034
|
-
/** Static metadata about every event — labels, descriptions, categories. */
|
|
1035
|
-
declare const WEBHOOK_EVENT_CATALOG: Record<WebhookEventType, {
|
|
1036
|
-
label: string;
|
|
1037
|
-
description: string;
|
|
1038
|
-
category: string;
|
|
1039
|
-
}>;
|
|
1040
|
-
|
|
1041
601
|
type WebhookEventData<T extends WebhookEventType> = WebhookEventDataMap[T];
|
|
1042
602
|
|
|
1043
603
|
/** A cStar webhook endpoint. */
|
|
@@ -2205,10 +1765,21 @@ interface ImportCreateParams {
|
|
|
2205
1765
|
resource: 'tickets' | 'customers' | 'articles';
|
|
2206
1766
|
/**
|
|
2207
1767
|
* Records to import. Flat objects with the per-entity fields you want
|
|
2208
|
-
* to set
|
|
1768
|
+
* to set, e.g. `[{ name: 'Jane', email: 'jane@example.com' }]` for
|
|
2209
1769
|
* `resource: 'customers'`. Each record is treated as a create. Server
|
|
2210
1770
|
* also accepts the wrapped internal shape `{ data, action, existingId? }`
|
|
2211
1771
|
* if you need to drive updates from the SDK.
|
|
1772
|
+
*
|
|
1773
|
+
* Ticket imports include details only, without conversation messages,
|
|
1774
|
+
* private notes or attachments. Ticket create/update records with nonempty
|
|
1775
|
+
* arrays at `messages`, `_messages`, `comments`, `audits`, `conversations`, `threads`,
|
|
1776
|
+
* `_embedded.threads`, `conversation_parts`, or
|
|
1777
|
+
* `conversation_parts.conversation_parts`, on the record or its `data`
|
|
1778
|
+
* object, cause HTTP 400 before any records in that request are written.
|
|
1779
|
+
* A truthy `source.body` paired with an array at `conversation_parts` or
|
|
1780
|
+
* `conversation_parts.conversation_parts` is also rejected, even if that
|
|
1781
|
+
* array is empty. Empty history without this initial-message shape,
|
|
1782
|
+
* customFields/metadata and wrapped records with `action: 'skip'` are allowed.
|
|
2212
1783
|
*/
|
|
2213
1784
|
records: Record<string, unknown>[];
|
|
2214
1785
|
/** How to handle duplicates. Defaults to `'overwrite'`. */
|
|
@@ -3159,6 +2730,7 @@ declare class OfflineQueue {
|
|
|
3159
2730
|
private autoFlushEnabled;
|
|
3160
2731
|
private onlineHandler;
|
|
3161
2732
|
private readonly useLocalStorage;
|
|
2733
|
+
private readonly storageKey;
|
|
3162
2734
|
constructor(httpClient: HttpClient, options?: OfflineQueueOptions);
|
|
3163
2735
|
/** Queue a mutation for later execution. Returns a queue item ID. */
|
|
3164
2736
|
enqueue(method: string, path: string, body: Record<string, unknown>): string;
|
|
@@ -3185,356 +2757,6 @@ declare class OfflineQueue {
|
|
|
3185
2757
|
private loadFromStorage;
|
|
3186
2758
|
}
|
|
3187
2759
|
|
|
3188
|
-
/**
|
|
3189
|
-
* Error classes for the cStar SDK.
|
|
3190
|
-
*
|
|
3191
|
-
* NEW-v3-01 — Cross-subpath instanceof identity.
|
|
3192
|
-
*
|
|
3193
|
-
* Each public subpath (`/library`, `/auth`, `/community`, `/quickhelp`, ...)
|
|
3194
|
-
* is bundled as a separate tsup entry with `splitting: false`, so each one
|
|
3195
|
-
* carries its own copy of this module. Without deduplication, errors thrown
|
|
3196
|
-
* by `LibraryClient` carry the LibraryClient-bundled `CStarError` class —
|
|
3197
|
-
* not the one a consumer imports from `@cstar.help/js`. That makes
|
|
3198
|
-
* `instanceof CStarError` checks fail silently, invalidating every "did the
|
|
3199
|
-
* SDK throw a typed cStar error?" branch in user code.
|
|
3200
|
-
*
|
|
3201
|
-
* Fix: register each class on a `Symbol.for(...)` slot of `globalThis`. The
|
|
3202
|
-
* symbol is realm-shared, so every bundled copy of this module resolves to
|
|
3203
|
-
* the SAME class identity at runtime — the first copy to load wins, and all
|
|
3204
|
-
* subsequent copies surface the canonical class via the same slot. The
|
|
3205
|
-
* inline `Impl` definitions are only used as the seed for the very first
|
|
3206
|
-
* copy to register. Internal `parseError` / `parsePublicError` reference the
|
|
3207
|
-
* EXPORTED canonical names so instances they construct also land on the
|
|
3208
|
-
* canonical class.
|
|
3209
|
-
*/
|
|
3210
|
-
/** Error type constants matching the cStar API. */
|
|
3211
|
-
declare const ErrorType: {
|
|
3212
|
-
readonly AUTHENTICATION_ERROR: "authentication_error";
|
|
3213
|
-
readonly PERMISSION_ERROR: "permission_error";
|
|
3214
|
-
readonly INVALID_REQUEST_ERROR: "invalid_request_error";
|
|
3215
|
-
readonly NOT_FOUND_ERROR: "not_found_error";
|
|
3216
|
-
readonly CONFLICT_ERROR: "conflict_error";
|
|
3217
|
-
readonly RATE_LIMIT_ERROR: "rate_limit_error";
|
|
3218
|
-
readonly FEATURE_NOT_CONFIGURED: "feature_not_configured";
|
|
3219
|
-
readonly API_ERROR: "api_error";
|
|
3220
|
-
readonly SERVER_ERROR: "server_error";
|
|
3221
|
-
};
|
|
3222
|
-
/** Shape of the error object returned by the cStar API. */
|
|
3223
|
-
interface ApiErrorBody {
|
|
3224
|
-
type: string;
|
|
3225
|
-
code: string;
|
|
3226
|
-
message: string;
|
|
3227
|
-
param?: string;
|
|
3228
|
-
doc_url: string;
|
|
3229
|
-
request_id?: string;
|
|
3230
|
-
feature?: string;
|
|
3231
|
-
enable_url?: string;
|
|
3232
|
-
}
|
|
3233
|
-
/** Base error class for all cStar API errors. */
|
|
3234
|
-
declare const CStarErrorImpl: {
|
|
3235
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3236
|
-
readonly type: string;
|
|
3237
|
-
readonly code: string;
|
|
3238
|
-
readonly param?: string;
|
|
3239
|
-
readonly docUrl: string;
|
|
3240
|
-
readonly requestId?: string;
|
|
3241
|
-
readonly statusCode: number;
|
|
3242
|
-
name: string;
|
|
3243
|
-
message: string;
|
|
3244
|
-
stack?: string;
|
|
3245
|
-
};
|
|
3246
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3247
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3248
|
-
stackTraceLimit: number;
|
|
3249
|
-
};
|
|
3250
|
-
declare const CStarAuthenticationErrorImpl: {
|
|
3251
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3252
|
-
readonly type: string;
|
|
3253
|
-
readonly code: string;
|
|
3254
|
-
readonly param?: string;
|
|
3255
|
-
readonly docUrl: string;
|
|
3256
|
-
readonly requestId?: string;
|
|
3257
|
-
readonly statusCode: number;
|
|
3258
|
-
name: string;
|
|
3259
|
-
message: string;
|
|
3260
|
-
stack?: string;
|
|
3261
|
-
};
|
|
3262
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3263
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3264
|
-
stackTraceLimit: number;
|
|
3265
|
-
};
|
|
3266
|
-
declare const CStarRateLimitErrorImpl: {
|
|
3267
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody, retryAfter?: number): {
|
|
3268
|
-
readonly retryAfter: number;
|
|
3269
|
-
readonly type: string;
|
|
3270
|
-
readonly code: string;
|
|
3271
|
-
readonly param?: string;
|
|
3272
|
-
readonly docUrl: string;
|
|
3273
|
-
readonly requestId?: string;
|
|
3274
|
-
readonly statusCode: number;
|
|
3275
|
-
name: string;
|
|
3276
|
-
message: string;
|
|
3277
|
-
stack?: string;
|
|
3278
|
-
};
|
|
3279
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3280
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3281
|
-
stackTraceLimit: number;
|
|
3282
|
-
};
|
|
3283
|
-
declare const CStarNotFoundErrorImpl: {
|
|
3284
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3285
|
-
readonly type: string;
|
|
3286
|
-
readonly code: string;
|
|
3287
|
-
readonly param?: string;
|
|
3288
|
-
readonly docUrl: string;
|
|
3289
|
-
readonly requestId?: string;
|
|
3290
|
-
readonly statusCode: number;
|
|
3291
|
-
name: string;
|
|
3292
|
-
message: string;
|
|
3293
|
-
stack?: string;
|
|
3294
|
-
};
|
|
3295
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3296
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3297
|
-
stackTraceLimit: number;
|
|
3298
|
-
};
|
|
3299
|
-
declare const CStarValidationErrorImpl: {
|
|
3300
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3301
|
-
readonly type: string;
|
|
3302
|
-
readonly code: string;
|
|
3303
|
-
readonly param?: string;
|
|
3304
|
-
readonly docUrl: string;
|
|
3305
|
-
readonly requestId?: string;
|
|
3306
|
-
readonly statusCode: number;
|
|
3307
|
-
name: string;
|
|
3308
|
-
message: string;
|
|
3309
|
-
stack?: string;
|
|
3310
|
-
};
|
|
3311
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3312
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3313
|
-
stackTraceLimit: number;
|
|
3314
|
-
};
|
|
3315
|
-
declare const CStarPermissionErrorImpl: {
|
|
3316
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3317
|
-
readonly type: string;
|
|
3318
|
-
readonly code: string;
|
|
3319
|
-
readonly param?: string;
|
|
3320
|
-
readonly docUrl: string;
|
|
3321
|
-
readonly requestId?: string;
|
|
3322
|
-
readonly statusCode: number;
|
|
3323
|
-
name: string;
|
|
3324
|
-
message: string;
|
|
3325
|
-
stack?: string;
|
|
3326
|
-
};
|
|
3327
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3328
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3329
|
-
stackTraceLimit: number;
|
|
3330
|
-
};
|
|
3331
|
-
declare const CStarConflictErrorImpl: {
|
|
3332
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3333
|
-
readonly type: string;
|
|
3334
|
-
readonly code: string;
|
|
3335
|
-
readonly param?: string;
|
|
3336
|
-
readonly docUrl: string;
|
|
3337
|
-
readonly requestId?: string;
|
|
3338
|
-
readonly statusCode: number;
|
|
3339
|
-
name: string;
|
|
3340
|
-
message: string;
|
|
3341
|
-
stack?: string;
|
|
3342
|
-
};
|
|
3343
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3344
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3345
|
-
stackTraceLimit: number;
|
|
3346
|
-
};
|
|
3347
|
-
declare const CStarServerErrorImpl: {
|
|
3348
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3349
|
-
readonly type: string;
|
|
3350
|
-
readonly code: string;
|
|
3351
|
-
readonly param?: string;
|
|
3352
|
-
readonly docUrl: string;
|
|
3353
|
-
readonly requestId?: string;
|
|
3354
|
-
readonly statusCode: number;
|
|
3355
|
-
name: string;
|
|
3356
|
-
message: string;
|
|
3357
|
-
stack?: string;
|
|
3358
|
-
};
|
|
3359
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3360
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3361
|
-
stackTraceLimit: number;
|
|
3362
|
-
};
|
|
3363
|
-
declare const CStarFeatureDisabledErrorImpl: {
|
|
3364
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3365
|
-
readonly feature: string;
|
|
3366
|
-
readonly enableUrl: string;
|
|
3367
|
-
readonly type: string;
|
|
3368
|
-
readonly code: string;
|
|
3369
|
-
readonly param?: string;
|
|
3370
|
-
readonly docUrl: string;
|
|
3371
|
-
readonly requestId?: string;
|
|
3372
|
-
readonly statusCode: number;
|
|
3373
|
-
name: string;
|
|
3374
|
-
message: string;
|
|
3375
|
-
stack?: string;
|
|
3376
|
-
};
|
|
3377
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3378
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3379
|
-
stackTraceLimit: number;
|
|
3380
|
-
};
|
|
3381
|
-
declare const CStarError: {
|
|
3382
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3383
|
-
readonly type: string;
|
|
3384
|
-
readonly code: string;
|
|
3385
|
-
readonly param?: string;
|
|
3386
|
-
readonly docUrl: string;
|
|
3387
|
-
readonly requestId?: string;
|
|
3388
|
-
readonly statusCode: number;
|
|
3389
|
-
name: string;
|
|
3390
|
-
message: string;
|
|
3391
|
-
stack?: string;
|
|
3392
|
-
};
|
|
3393
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3394
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3395
|
-
stackTraceLimit: number;
|
|
3396
|
-
};
|
|
3397
|
-
type CStarError = InstanceType<typeof CStarErrorImpl>;
|
|
3398
|
-
declare const CStarAuthenticationError: {
|
|
3399
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3400
|
-
readonly type: string;
|
|
3401
|
-
readonly code: string;
|
|
3402
|
-
readonly param?: string;
|
|
3403
|
-
readonly docUrl: string;
|
|
3404
|
-
readonly requestId?: string;
|
|
3405
|
-
readonly statusCode: number;
|
|
3406
|
-
name: string;
|
|
3407
|
-
message: string;
|
|
3408
|
-
stack?: string;
|
|
3409
|
-
};
|
|
3410
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3411
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3412
|
-
stackTraceLimit: number;
|
|
3413
|
-
};
|
|
3414
|
-
type CStarAuthenticationError = InstanceType<typeof CStarAuthenticationErrorImpl>;
|
|
3415
|
-
declare const CStarRateLimitError: {
|
|
3416
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody, retryAfter?: number): {
|
|
3417
|
-
readonly retryAfter: number;
|
|
3418
|
-
readonly type: string;
|
|
3419
|
-
readonly code: string;
|
|
3420
|
-
readonly param?: string;
|
|
3421
|
-
readonly docUrl: string;
|
|
3422
|
-
readonly requestId?: string;
|
|
3423
|
-
readonly statusCode: number;
|
|
3424
|
-
name: string;
|
|
3425
|
-
message: string;
|
|
3426
|
-
stack?: string;
|
|
3427
|
-
};
|
|
3428
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3429
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3430
|
-
stackTraceLimit: number;
|
|
3431
|
-
};
|
|
3432
|
-
type CStarRateLimitError = InstanceType<typeof CStarRateLimitErrorImpl>;
|
|
3433
|
-
declare const CStarNotFoundError: {
|
|
3434
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3435
|
-
readonly type: string;
|
|
3436
|
-
readonly code: string;
|
|
3437
|
-
readonly param?: string;
|
|
3438
|
-
readonly docUrl: string;
|
|
3439
|
-
readonly requestId?: string;
|
|
3440
|
-
readonly statusCode: number;
|
|
3441
|
-
name: string;
|
|
3442
|
-
message: string;
|
|
3443
|
-
stack?: string;
|
|
3444
|
-
};
|
|
3445
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3446
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3447
|
-
stackTraceLimit: number;
|
|
3448
|
-
};
|
|
3449
|
-
type CStarNotFoundError = InstanceType<typeof CStarNotFoundErrorImpl>;
|
|
3450
|
-
declare const CStarValidationError: {
|
|
3451
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3452
|
-
readonly type: string;
|
|
3453
|
-
readonly code: string;
|
|
3454
|
-
readonly param?: string;
|
|
3455
|
-
readonly docUrl: string;
|
|
3456
|
-
readonly requestId?: string;
|
|
3457
|
-
readonly statusCode: number;
|
|
3458
|
-
name: string;
|
|
3459
|
-
message: string;
|
|
3460
|
-
stack?: string;
|
|
3461
|
-
};
|
|
3462
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3463
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3464
|
-
stackTraceLimit: number;
|
|
3465
|
-
};
|
|
3466
|
-
type CStarValidationError = InstanceType<typeof CStarValidationErrorImpl>;
|
|
3467
|
-
declare const CStarPermissionError: {
|
|
3468
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3469
|
-
readonly type: string;
|
|
3470
|
-
readonly code: string;
|
|
3471
|
-
readonly param?: string;
|
|
3472
|
-
readonly docUrl: string;
|
|
3473
|
-
readonly requestId?: string;
|
|
3474
|
-
readonly statusCode: number;
|
|
3475
|
-
name: string;
|
|
3476
|
-
message: string;
|
|
3477
|
-
stack?: string;
|
|
3478
|
-
};
|
|
3479
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3480
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3481
|
-
stackTraceLimit: number;
|
|
3482
|
-
};
|
|
3483
|
-
type CStarPermissionError = InstanceType<typeof CStarPermissionErrorImpl>;
|
|
3484
|
-
declare const CStarConflictError: {
|
|
3485
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3486
|
-
readonly type: string;
|
|
3487
|
-
readonly code: string;
|
|
3488
|
-
readonly param?: string;
|
|
3489
|
-
readonly docUrl: string;
|
|
3490
|
-
readonly requestId?: string;
|
|
3491
|
-
readonly statusCode: number;
|
|
3492
|
-
name: string;
|
|
3493
|
-
message: string;
|
|
3494
|
-
stack?: string;
|
|
3495
|
-
};
|
|
3496
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3497
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3498
|
-
stackTraceLimit: number;
|
|
3499
|
-
};
|
|
3500
|
-
type CStarConflictError = InstanceType<typeof CStarConflictErrorImpl>;
|
|
3501
|
-
declare const CStarServerError: {
|
|
3502
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3503
|
-
readonly type: string;
|
|
3504
|
-
readonly code: string;
|
|
3505
|
-
readonly param?: string;
|
|
3506
|
-
readonly docUrl: string;
|
|
3507
|
-
readonly requestId?: string;
|
|
3508
|
-
readonly statusCode: number;
|
|
3509
|
-
name: string;
|
|
3510
|
-
message: string;
|
|
3511
|
-
stack?: string;
|
|
3512
|
-
};
|
|
3513
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3514
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3515
|
-
stackTraceLimit: number;
|
|
3516
|
-
};
|
|
3517
|
-
type CStarServerError = InstanceType<typeof CStarServerErrorImpl>;
|
|
3518
|
-
declare const CStarFeatureDisabledError: {
|
|
3519
|
-
new (messageOrStatus: string | number, body?: ApiErrorBody): {
|
|
3520
|
-
readonly feature: string;
|
|
3521
|
-
readonly enableUrl: string;
|
|
3522
|
-
readonly type: string;
|
|
3523
|
-
readonly code: string;
|
|
3524
|
-
readonly param?: string;
|
|
3525
|
-
readonly docUrl: string;
|
|
3526
|
-
readonly requestId?: string;
|
|
3527
|
-
readonly statusCode: number;
|
|
3528
|
-
name: string;
|
|
3529
|
-
message: string;
|
|
3530
|
-
stack?: string;
|
|
3531
|
-
};
|
|
3532
|
-
captureStackTrace(targetObject: object, constructorOpt?: Function): void;
|
|
3533
|
-
prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
|
|
3534
|
-
stackTraceLimit: number;
|
|
3535
|
-
};
|
|
3536
|
-
type CStarFeatureDisabledError = InstanceType<typeof CStarFeatureDisabledErrorImpl>;
|
|
3537
|
-
|
|
3538
2760
|
/** Configuration for the CStarClient. */
|
|
3539
2761
|
interface CStarClientConfig {
|
|
3540
2762
|
/** Your API key (sk_live_*, sk_test_*, pk_live_*, or pk_test_*). */
|
|
@@ -3688,4 +2910,4 @@ declare class CStarClient {
|
|
|
3688
2910
|
get lastMeta(): LastMeta;
|
|
3689
2911
|
}
|
|
3690
2912
|
|
|
3691
|
-
export { type Achievement, type AchievementListParams, type ActivityEvent, type ActivityListParams, type AiAction, type AiActionParams, type AiActionResult, type AnalyticsOverview, type AnalyticsParams, type
|
|
2913
|
+
export { type Achievement, type AchievementListParams, type ActivityEvent, type ActivityListParams, type AiAction, type AiActionParams, type AiActionResult, type AnalyticsOverview, type AnalyticsParams, type ApiResponse, type Article, type ArticleCreateParams, type ArticleListParams, type ArticleUpdateParams, type Attachment, type AttachmentListParams, type AuditLogEntry, type AuditLogListParams, type AutomationAction, type AutomationCondition, type AutomationConditions, type AutomationCreateParams, type AutomationExecution, type AutomationExecutionListParams, type AutomationListParams, type AutomationRule, type AutomationTestResult, type AutomationUpdateParams, type BillingPortal, type BillingPortalParams, type Boss, type BossDamageParams, type BossDamageResult, type BossDefeat, type BossDefeatListParams, type BossSpawnParams, type BulkDeleteParams, type BulkResult, type BulkUpdateParams, type BusinessHours, type BusinessHoursUpdateParams, CStarClient, type CStarClientConfig, CStarRealtime, type Category, type CategoryCreateParams, type CategoryListParams, type CategoryUpdateParams, type CommunityComment, type CommunityCommentCreateParams, type CommunityPost, type CommunityPostCreateParams, type CommunityPostListParams, type CommunityPostUpdateParams, type CommunityTopic, type ConnectionHandler, type Cosmetic, type CosmeticPreferences, type CsatSettings, type CsatSettingsUpdateParams, type CsatStats, type CsatSurvey, type CsatSurveyCreateParams, type CsatSurveyListParams, type CustomField, type CustomFieldCreateParams, type CustomFieldListParams, type CustomFieldUpdateParams, type Customer, type CustomerCreateParams, type CustomerGroup, type CustomerGroupAddMembersParams, type CustomerGroupAddResult, type CustomerGroupCreateParams, type CustomerGroupListParams, type CustomerGroupMemberListParams, type CustomerGroupMembersResult, type CustomerGroupRemoveResult, type CustomerGroupUpdateParams, type CustomerListParams, type CustomerUpdateParams, type DeleteResponse, type ErrorHandler, type EventHandler, type ExportCreateParams, type ExportResult, type GameConfig, type HighFive, type HighFiveCanSend, type HighFiveCreateParams, type HighFiveListParams, type ImportCreateParams, type ImportLog, type ImportLogListParams, type ImportResult, type Invite, type InviteCreateParams, type InviteListParams, type LeaderboardEntry, type LeaderboardParams, type ListResponse, type Member, type MemberListParams, type MemberUpdateParams, type Mention, type MentionListParams, type MentionUnreadCount, type Message, type MessageCreateParams, type Metadata, type Notification, type NotificationListParams, OfflineQueue, type OfflineQueueOptions, type OneUp, type OneUpCreateParams, type OneUpListParams, type OneUpRemaining, type PaginationInfo, type PaginationParams, type Player, type Puzzle, type PuzzleCompleteParams, type PuzzleCompleteResult, type PuzzleStreak, type Quest, type QueueItem, type QueueResult, type QuickReply, type QuickReplyCreateParams, type QuickReplyUpdateParams, type RealtimeEvent, type RealtimeOptions, type RequestOptions, type SavedView, type SearchParams, type SearchResult, type Season, type SeasonStats, type SkillAllocateParams, type SkillAllocateResult, type SkillTree, type SlaMetrics, type SlaMetricsParams, type SlaRule, type SlaRuleCreateParams, type SlaRuleListParams, type SlaRuleUpdateParams, type StatusCreateParams, type StatusUpdateParams, Subscription$1 as Subscription, type Tag, type TagListParams, type TeamSettings, type TeamSettingsUpdateParams, type Ticket, type TicketCreateParams, type TicketCustomerSummary, type TicketListParams, type TicketStatus, type TicketUpdateParams, type TopicCustomField, type UnreadCount, type ViewCreateParams, type ViewExecuteParams, type ViewListParams, type ViewUpdateParams, type Webhook, type WebhookCreateParams, type WebhookEventData, WebhookEventType, type WebhookListParams, type WebhookListener, type WebhookListenerParams, type WebhookSubscribeParams, type WebhookSubscription, type WebhookTestResult, type WebhookTriggerTestParams, type WebhookTriggerTestResult, type WebhookUpdateParams, type WidgetSettings, type WidgetSettingsUpdateParams };
|