@graph8/sdk 0.5.3 → 0.7.1

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 CHANGED
@@ -1,5 +1,313 @@
1
1
  import { AnalyticsInterface } from '@jitsu/js';
2
2
 
3
+ interface Snippet {
4
+ write_key: string;
5
+ tracking_host: string;
6
+ domains: string[];
7
+ /** Ready-to-use React component import for @graph8/nextjs. */
8
+ react_snippet: string;
9
+ /** Vanilla JS script tag for non-React apps. */
10
+ script_tag: string;
11
+ /** Full configuration object (gtm/config.json). */
12
+ config: Record<string, unknown>;
13
+ }
14
+ /**
15
+ * Snippet API — fetch your org's graph8 tracking snippet programmatically, to
16
+ * embed the tracker into an app or a customer's site (the write key, a React
17
+ * component, a vanilla `<script>` tag, allowed domains, and the full config).
18
+ * Requires an API key (server-side). Built on the hardened HTTP core, so it
19
+ * throws a typed `G8Error` on failure and retries transient errors.
20
+ *
21
+ * Backed by `GET /api/v1/snippet`.
22
+ */
23
+ declare const createSnippetClient: (apiKey: string, apiUrl?: string) => {
24
+ /** Get your org's tracking snippet (write key + React/script-tag embeds + config). */
25
+ get(): Promise<Snippet>;
26
+ };
27
+
28
+ interface MarketplaceProfile {
29
+ id: string;
30
+ email: string;
31
+ first_name?: string | null;
32
+ last_name?: string | null;
33
+ marketplace_role?: string | null;
34
+ country_code?: string | null;
35
+ monthly_rate_usd?: string | null;
36
+ per_meeting_rate_usd?: string | null;
37
+ availability_status?: string | null;
38
+ bio?: string | null;
39
+ is_complete: boolean;
40
+ }
41
+ interface MarketplaceOffer {
42
+ id: string;
43
+ org_id: string;
44
+ org_name?: string | null;
45
+ sdr_id: string;
46
+ status: string;
47
+ monthly_rate_usd?: string | null;
48
+ per_meeting_rate_usd?: string | null;
49
+ created_at?: string | null;
50
+ }
51
+ interface MarketplaceHiring {
52
+ id: string;
53
+ org_id: string;
54
+ sdr_id: string;
55
+ status: string;
56
+ sdr_name?: string | null;
57
+ sdr_role?: string | null;
58
+ sdr_email?: string | null;
59
+ monthly_rate_usd?: string | null;
60
+ per_meeting_rate_usd?: string | null;
61
+ started_at?: string | null;
62
+ }
63
+ /**
64
+ * Marketplace API — for SDR/AE talent on the graph8 marketplace. View your
65
+ * profile, see pending hire offers and respond to them, and list your active
66
+ * hirings. Requires a personal API key (server-side). Built on the hardened
67
+ * HTTP core, so every method throws a typed `G8Error` on failure and retries
68
+ * transient errors.
69
+ *
70
+ * Backed by `/api/v1/marketplace`.
71
+ */
72
+ declare const createMarketplaceClient: (apiKey: string, apiUrl?: string) => {
73
+ /** Your own marketplace SDR profile. */
74
+ profile(): Promise<MarketplaceProfile>;
75
+ /** Pending hire offers you can accept or reject. */
76
+ offers(): Promise<{
77
+ offers: MarketplaceOffer[];
78
+ count: number;
79
+ }>;
80
+ /** Accept a pending hire offer (by hiring id). */
81
+ acceptOffer(hiringId: string): Promise<Record<string, unknown>>;
82
+ /** Reject a pending hire offer (by hiring id). */
83
+ rejectOffer(hiringId: string): Promise<Record<string, unknown>>;
84
+ /** Your active hiring contracts. */
85
+ hirings(): Promise<{
86
+ hirings: MarketplaceHiring[];
87
+ count: number;
88
+ }>;
89
+ };
90
+
91
+ interface AgencyInfo {
92
+ agency_org_id: string;
93
+ agency_org_name: string | null;
94
+ is_agency: boolean;
95
+ client_count: number;
96
+ /** Request header to set when operating a client org (e.g. "X-Target-Org-Id"). */
97
+ target_header: string;
98
+ }
99
+ interface AgencyClient {
100
+ /** Pass this as the `X-Target-Org-Id` header to operate this client org. */
101
+ org_id: string;
102
+ }
103
+ /**
104
+ * Agency API — for agency-scoped API keys (minted with `is_agency: true`).
105
+ * Discover the agency credential and the client orgs it may operate. To act on a
106
+ * client org, set the `X-Target-Org-Id` header (see `target_header`) to that
107
+ * client's `org_id` on your subsequent requests. Requires an agency API key
108
+ * (server-side); a non-agency key gets a `403`.
109
+ *
110
+ * Built on the hardened HTTP core (typed `G8Error` + retries). Backed by
111
+ * `/api/v1/agency`.
112
+ */
113
+ declare const createAgencyClient: (apiKey: string, apiUrl?: string) => {
114
+ /** Describe the agency credential: agency org + authorized client count. */
115
+ me(): Promise<AgencyInfo>;
116
+ /** List the client orgs this agency key may target via `X-Target-Org-Id`. */
117
+ clients(): Promise<{
118
+ data: AgencyClient[];
119
+ }>;
120
+ };
121
+
122
+ /** Filter operators supported by open-data search. */
123
+ type SearchOperator = "any_of" | "contains" | "all_of" | "none_of" | "is_empty" | "is_not_empty" | "between" | "exists";
124
+ /** A single search filter condition (named to avoid colliding with enrich's `SearchFilter`). */
125
+ interface SearchCondition {
126
+ /** Field to filter on, e.g. "job_title", "country", "industry". */
127
+ field: string;
128
+ operator: SearchOperator;
129
+ /** Filter values (operator-dependent; e.g. `["VP", "Director"]` for any_of). */
130
+ value?: unknown[];
131
+ }
132
+ interface SearchParams {
133
+ /** Filter conditions, combined with AND. */
134
+ filters?: SearchCondition[];
135
+ /** Page number, 1-indexed (1-100). */
136
+ page?: number;
137
+ /** Results per page (1-100, default 25). */
138
+ limit?: number;
139
+ }
140
+ interface SearchSaveParams extends SearchParams {
141
+ /** Title for the new list the matched records are saved into. */
142
+ list_title: string;
143
+ /** Max records to save (1-10,000, default 1,000). */
144
+ max_results?: number;
145
+ }
146
+ interface SearchContactItem {
147
+ first_name?: string | null;
148
+ last_name?: string | null;
149
+ middle_name?: string | null;
150
+ work_email?: string | null;
151
+ personal_emails?: string | null;
152
+ direct_phone?: string | null;
153
+ mobile_phone?: string | null;
154
+ job_title?: string | null;
155
+ job_department?: string | null;
156
+ seniority_level?: string | null;
157
+ role?: string | null;
158
+ linkedin_url?: string | null;
159
+ linkedin_headline?: string | null;
160
+ city?: string | null;
161
+ state?: string | null;
162
+ country?: string | null;
163
+ company_name?: string | null;
164
+ company_domain?: string | null;
165
+ company_industry?: string | null;
166
+ company_employee_count?: string | null;
167
+ company_country?: string | null;
168
+ confidence_score?: number | null;
169
+ }
170
+ interface SearchCompanyItem {
171
+ name?: string | null;
172
+ domain?: string | null;
173
+ website?: string | null;
174
+ description?: string | null;
175
+ industry?: string | null;
176
+ industry_group?: string | null;
177
+ employee_count?: string | null;
178
+ revenue?: string | null;
179
+ founded_year?: number | null;
180
+ phone?: string | null;
181
+ address?: string | null;
182
+ city?: string | null;
183
+ state?: string | null;
184
+ country?: string | null;
185
+ zip?: number | null;
186
+ linkedin_url?: string | null;
187
+ linkedin_followers?: string | null;
188
+ facebook_url?: string | null;
189
+ twitter_url?: string | null;
190
+ crunchbase_url?: string | null;
191
+ logo_url?: string | null;
192
+ }
193
+ interface SearchSaveResult {
194
+ list_id: number;
195
+ list_title: string;
196
+ estimated_total: number;
197
+ status: string;
198
+ }
199
+ /**
200
+ * Search API — prospect the open-data graph for new contacts and companies by
201
+ * filter, and optionally save the matches straight into a list. Requires API
202
+ * key (server-side). Built on the hardened HTTP core, so every method throws a
203
+ * typed `G8Error` on failure and retries transient errors.
204
+ *
205
+ * Backed by `/api/v1/search`.
206
+ */
207
+ declare const createSearchClient: (apiKey: string, apiUrl?: string) => {
208
+ /** Search open-data contacts by filter. */
209
+ contacts(params?: SearchParams): Promise<{
210
+ data: SearchContactItem[];
211
+ }>;
212
+ /** Search open-data companies by filter. */
213
+ companies(params?: SearchParams): Promise<{
214
+ data: SearchCompanyItem[];
215
+ }>;
216
+ /** Search contacts and save the matches into a new list. */
217
+ saveContacts(params: SearchSaveParams): Promise<SearchSaveResult>;
218
+ /** Search companies and save the matches into a new list. */
219
+ saveCompanies(params: SearchSaveParams): Promise<SearchSaveResult>;
220
+ };
221
+
222
+ /** Ad platform an audience can sync to. */
223
+ type AudienceSyncPlatform = "meta" | "linkedin" | "google" | "x";
224
+ /** Sync mode: full mirror, or only ever add members. */
225
+ type AudienceSyncMode = "mirror" | "append_only";
226
+ interface AudienceSync {
227
+ id: number;
228
+ audience_id: number;
229
+ platform: string;
230
+ platform_audience_name: string | null;
231
+ mode: string;
232
+ refresh_cadence_hours: number;
233
+ is_active: boolean;
234
+ status: string | null;
235
+ last_sync_at: string | null;
236
+ created_at: string | null;
237
+ }
238
+ interface AudienceSyncCreateParams {
239
+ /** Audience list ID to sync. */
240
+ audience_id: number;
241
+ platform: AudienceSyncPlatform;
242
+ platform_audience_name?: string;
243
+ /** Default "mirror". */
244
+ mode?: AudienceSyncMode;
245
+ /** Refresh cadence in hours (0-720; default 24). */
246
+ refresh_cadence_hours?: number;
247
+ /** Platform-specific config (OAuth creds, ad-account ids, etc.). */
248
+ platform_config?: Record<string, unknown>;
249
+ /** Audience list IDs whose members should be suppressed from the sync. */
250
+ suppression_list_ids?: number[];
251
+ }
252
+ interface AudienceSyncUpdateParams {
253
+ mode?: AudienceSyncMode;
254
+ refresh_cadence_hours?: number;
255
+ is_active?: boolean;
256
+ suppression_list_ids?: number[];
257
+ }
258
+ interface AudienceSyncRun {
259
+ id: number;
260
+ started_at: string | null;
261
+ finished_at: string | null;
262
+ status: string | null;
263
+ members_added: number | null;
264
+ members_removed: number | null;
265
+ total_members: number | null;
266
+ error_message: string | null;
267
+ }
268
+ interface AudienceSyncError {
269
+ id: number;
270
+ started_at: string | null;
271
+ error_message: string | null;
272
+ details: Record<string, unknown> | null;
273
+ }
274
+ /**
275
+ * Audiences API — sync an audience list to ad platforms (Meta, LinkedIn,
276
+ * Google, X). Requires API key (server-side). Built on the hardened HTTP core,
277
+ * so every method throws a typed `G8Error` on failure and retries transient
278
+ * 429/5xx/network errors.
279
+ *
280
+ * Backed by `/api/v1/audience-syncs`.
281
+ */
282
+ declare const createAudiencesClient: (apiKey: string, apiUrl?: string) => {
283
+ /** List all audience syncs for the organization. */
284
+ list(): Promise<{
285
+ data: AudienceSync[];
286
+ }>;
287
+ /** Create a new audience sync to an ad platform. */
288
+ create(params: AudienceSyncCreateParams): Promise<AudienceSync>;
289
+ /** Get a single audience sync by ID. */
290
+ get(configId: number): Promise<AudienceSync>;
291
+ /** Update an audience sync (partial). */
292
+ update(configId: number, fields: AudienceSyncUpdateParams): Promise<AudienceSync>;
293
+ /** Delete an audience sync. */
294
+ delete(configId: number): Promise<{
295
+ data: Record<string, unknown>;
296
+ }>;
297
+ /** Trigger an immediate sync run for a config. */
298
+ trigger(configId: number): Promise<{
299
+ data: Record<string, unknown>;
300
+ }>;
301
+ /** List recent sync runs for a config (most recent first). */
302
+ runs(configId: number): Promise<{
303
+ data: AudienceSyncRun[];
304
+ }>;
305
+ /** List recent sync errors for a config. */
306
+ errors(configId: number): Promise<{
307
+ data: AudienceSyncError[];
308
+ }>;
309
+ };
310
+
3
311
  interface MeetingAttendee {
4
312
  name: string | null;
5
313
  email: string;
@@ -585,7 +893,8 @@ interface WorkflowListParams {
585
893
  }
586
894
  /**
587
895
  * Workflows API - automation workflows with nodes, connections, and execution lifecycle.
588
- * Requires API key (server-side).
896
+ * Requires API key (server-side). On the hardened HTTP core: throws a typed
897
+ * `G8Error` on failure and retries transient errors.
589
898
  *
590
899
  * The graph8 workflow surface treats the whole workflow definition as a single
591
900
  * record updated via `update()` — there are no per-node CRUD endpoints. To edit
@@ -650,9 +959,9 @@ declare const createWorkflowsClient: (apiKey: string, apiUrl?: string) => {
650
959
  }>;
651
960
  /** Execute a workflow immediately with a trigger payload. */
652
961
  execute(workflowId: string, triggerPayload?: Record<string, unknown>): Promise<WorkflowExecution>;
653
- /** Get the status + output of a workflow execution. */
962
+ /** Get the status + outputs of a single execution. */
654
963
  getExecution(executionId: string): Promise<WorkflowExecution>;
655
- /** Pause an in-flight execution. */
964
+ /** Pause a running execution. */
656
965
  pauseExecution(executionId: string): Promise<{
657
966
  data: {
658
967
  paused: boolean;
@@ -664,34 +973,32 @@ declare const createWorkflowsClient: (apiKey: string, apiUrl?: string) => {
664
973
  resumed: boolean;
665
974
  };
666
975
  }>;
667
- /** Stop an execution (terminal state — cannot resume). */
976
+ /** Stop an execution. */
668
977
  stopExecution(executionId: string): Promise<{
669
978
  data: {
670
979
  stopped: boolean;
671
980
  };
672
981
  }>;
673
- /** Get the status of a workflow's external trigger (e.g. "waiting for webhook"). */
982
+ /** Get the trigger status (e.g. schedule / webhook wiring) for a workflow. */
674
983
  getTriggerStatus(workflowId: string): Promise<{
675
984
  data: {
676
985
  status: string;
677
986
  details: Record<string, unknown>;
678
987
  };
679
988
  }>;
680
- /** Reset the trigger cursor (e.g. for event-stream triggers — resume from beginning). */
989
+ /** Reset a workflow's trigger cursor / state. */
681
990
  resetTrigger(workflowId: string): Promise<{
682
991
  data: {
683
992
  reset: boolean;
684
993
  };
685
994
  }>;
686
- /**
687
- * List available node types with schemas. Pass a `type` param to fetch one type's full schema.
688
- */
995
+ /** Catalog of available workflow node types with config + output schemas. */
689
996
  nodeTypes(params?: {
690
997
  type?: string;
691
998
  }): Promise<{
692
999
  data: NodeTypeSchema[];
693
1000
  }>;
694
- /** Slack workspace users (for Slack action recipients). */
1001
+ /** Slack users available to workflow nodes. */
695
1002
  listSlackUsers(): Promise<{
696
1003
  data: Array<{
697
1004
  id: string;
@@ -699,7 +1006,7 @@ declare const createWorkflowsClient: (apiKey: string, apiUrl?: string) => {
699
1006
  email: string | null;
700
1007
  }>;
701
1008
  }>;
702
- /** Slack channels. */
1009
+ /** Slack channels available to workflow nodes. */
703
1010
  listSlackChannels(): Promise<{
704
1011
  data: Array<{
705
1012
  id: string;
@@ -707,7 +1014,7 @@ declare const createWorkflowsClient: (apiKey: string, apiUrl?: string) => {
707
1014
  is_private: boolean;
708
1015
  }>;
709
1016
  }>;
710
- /** Roam (Copilot chat) users. */
1017
+ /** Roam users available to workflow nodes. */
711
1018
  listRoamUsers(): Promise<{
712
1019
  data: Array<{
713
1020
  id: string;
@@ -715,14 +1022,14 @@ declare const createWorkflowsClient: (apiKey: string, apiUrl?: string) => {
715
1022
  email: string | null;
716
1023
  }>;
717
1024
  }>;
718
- /** Roam (Copilot chat) groups. */
1025
+ /** Roam groups available to workflow nodes. */
719
1026
  listRoamGroups(): Promise<{
720
1027
  data: Array<{
721
1028
  id: string;
722
1029
  name: string;
723
1030
  }>;
724
1031
  }>;
725
- /** Available MCP servers (for Agent-node integrations). */
1032
+ /** MCP servers available to workflow nodes. */
726
1033
  listMcpServers(): Promise<{
727
1034
  data: Array<{
728
1035
  id: string;
@@ -730,14 +1037,14 @@ declare const createWorkflowsClient: (apiKey: string, apiUrl?: string) => {
730
1037
  url: string;
731
1038
  }>;
732
1039
  }>;
733
- /** Available call dispositions (voice workflow nodes). */
1040
+ /** Disposition options available to workflow nodes. */
734
1041
  listDispositions(): Promise<{
735
1042
  data: Array<{
736
1043
  id: string;
737
1044
  label: string;
738
1045
  }>;
739
1046
  }>;
740
- /** Form field schema for form-trigger nodes. */
1047
+ /** Form field definitions for a given form (used by form-trigger nodes). */
741
1048
  listFormFields(formId: string): Promise<{
742
1049
  data: Array<{
743
1050
  name: string;
@@ -820,7 +1127,8 @@ interface PipelineSuggestion {
820
1127
  }
821
1128
  /**
822
1129
  * Stage Checklist Pipelines API - workflow pipelines with evidence + scripts.
823
- * Requires API key (server-side).
1130
+ * Requires API key (server-side). On the hardened HTTP core: throws a typed
1131
+ * `G8Error` on failure and retries transient errors.
824
1132
  *
825
1133
  * Backed by:
826
1134
  * GET /api/v1/pipelines
@@ -963,7 +1271,9 @@ interface PaginationMeta$2 {
963
1271
  has_next: boolean;
964
1272
  }
965
1273
  /**
966
- * Quotes API - quote-to-cash lifecycle. Requires API key (server-side).
1274
+ * Quotes API - quote-to-cash lifecycle. Requires API key (server-side). On the
1275
+ * hardened HTTP core: throws a typed `G8Error` on failure and retries transient
1276
+ * errors.
967
1277
  *
968
1278
  * Backed by:
969
1279
  * GET /api/v1/quotes
@@ -1116,7 +1426,9 @@ interface InboxSendResult {
1116
1426
  }
1117
1427
  /**
1118
1428
  * Inbox API — read + reply to multi-channel inbox threads (email, SMS, LinkedIn/HeyReach).
1119
- * Requires API key (server-side).
1429
+ * Requires API key (server-side). On the hardened HTTP core: throws a typed
1430
+ * `G8Error` on failure (e.g. 402 when an AI draft exceeds your credit balance)
1431
+ * and retries transient errors.
1120
1432
  *
1121
1433
  * Backed by:
1122
1434
  * GET /api/v1/inbox
@@ -1323,7 +1635,8 @@ interface SetFieldValueParams {
1323
1635
  }
1324
1636
  /**
1325
1637
  * Fields API - manage custom fields (columns) on contacts and companies.
1326
- * Requires API key (server-side).
1638
+ * Requires API key (server-side). On the hardened HTTP core: throws a typed
1639
+ * `G8Error` on failure and retries transient errors.
1327
1640
  *
1328
1641
  * Backed by:
1329
1642
  * GET /api/v1/fields — list contact fields
@@ -1717,8 +2030,11 @@ declare const createContactsClient: (apiKey: string, apiUrl?: string) => {
1717
2030
  }>;
1718
2031
  /** Get a single contact by ID. */
1719
2032
  get(contactId: number): Promise<Contact>;
1720
- /** Create a new contact. */
1721
- create(contact: ContactCreateParams): Promise<Contact>;
2033
+ /**
2034
+ * Create a new contact. Pass `idempotencyKey` to make a retry safe — the
2035
+ * same key returns the first result instead of creating a duplicate (A6).
2036
+ */
2037
+ create(contact: ContactCreateParams, idempotencyKey?: string): Promise<Contact>;
1722
2038
  /** Update a contact (partial). */
1723
2039
  update(contactId: number, fields: ContactUpdateParams): Promise<{
1724
2040
  updated: number;
@@ -1735,18 +2051,76 @@ declare const createContactsClient: (apiKey: string, apiUrl?: string) => {
1735
2051
  createColumn(params: ContactColumnCreateParams): Promise<ContactColumn>;
1736
2052
  };
1737
2053
 
1738
- type WebhookEvent = "reply_received" | "meeting_booked" | "contact_enriched" | "contact_created" | "sequence_completed" | "sequence_replied" | "campaign_launched" | "form_submitted" | "visitor_identified";
1739
- type WebhookCallback = (data: Record<string, unknown>) => void;
1740
2054
  /**
1741
- * Webhooks - listen for graph8 events. Requires API key (server-side).
2055
+ * Known graph8 webhook event types.
2056
+ *
2057
+ * Source of truth is the backend ``WEBHOOK_EVENTS`` catalog
2058
+ * (campaign_builder/services/webhook_service.py). Keep in sync when the backend
2059
+ * adds events. ``WebhookEvent`` also accepts any string so a newly-added
2060
+ * backend event never breaks a client that hasn't upgraded.
2061
+ */
2062
+ declare const KNOWN_WEBHOOK_EVENTS: readonly ["campaign.created", "campaign.updated", "campaign.deleted", "campaign.launched", "campaign.paused", "campaign.completed", "campaign.status_changed", "campaign.content_ready", "document.generated", "document.failed", "intelligence.completed", "intelligence.failed", "company.enriched", "company_intelligence.completed", "audience.ready", "audience.failed", "sequence.deployed", "sequence.started", "sequence.paused", "sequence.completed", "engagement.email_sent", "engagement.email_replied", "engagement.email_bounced", "engagement.email_skipped", "engagement.call_dispatched", "engagement.sms_sent", "engagement.sms_replied", "engagement.whatsapp_sent", "engagement.linkedin_connection_sent", "engagement.linkedin_message_sent", "engagement.linkedin_inmail_sent", "engagement.linkedin_reply_received", "engagement.linkedin_connection_accepted", "meeting.booked", "meeting.cancelled", "meeting.rescheduled"];
2063
+ type WebhookEvent = (typeof KNOWN_WEBHOOK_EVENTS)[number] | (string & {});
2064
+ /** The decoded body graph8 delivers to a webhook endpoint. */
2065
+ interface WebhookEventPayload {
2066
+ event: WebhookEvent;
2067
+ timestamp: string;
2068
+ data: Record<string, unknown>;
2069
+ org_id: string;
2070
+ /** Stable per-delivery id (present once the backend adds it; for consumer dedup). */
2071
+ id?: string;
2072
+ }
2073
+ interface ConstructEventOptions {
2074
+ /**
2075
+ * Reject events whose ``X-Studio-Timestamp`` is older (or newer) than this
2076
+ * many seconds — replay protection. Disabled when 0/undefined.
2077
+ */
2078
+ toleranceSeconds?: number;
2079
+ }
2080
+ /** Thrown by {@link constructEvent} when a webhook cannot be verified. */
2081
+ declare class WebhookSignatureError extends Error {
2082
+ constructor(message: string);
2083
+ }
2084
+ /**
2085
+ * Verify the HMAC-SHA256 signature of an incoming graph8 webhook and return the
2086
+ * parsed event. Server-side only (needs the per-endpoint signing secret).
2087
+ *
2088
+ * Mirrors the backend signing scheme exactly: the signature is
2089
+ * ``HMAC_SHA256(secret, `${timestamp}.${rawBody}`)`` hex-encoded, delivered in
2090
+ * the ``X-Studio-Signature`` header alongside the unix ``X-Studio-Timestamp``.
1742
2091
  *
1743
- * For client-side real-time events, use g8.visitors.onIntent() or g8.chat.on() instead.
2092
+ * @param payload The RAW request body string (verify before JSON.parse — re-serializing changes bytes).
2093
+ * @param signature The ``X-Studio-Signature`` header (an optional ``sha256=`` prefix is tolerated).
2094
+ * @param timestamp The ``X-Studio-Timestamp`` header (unix seconds).
2095
+ * @param secret The endpoint's signing secret.
2096
+ * @throws {WebhookSignatureError} on a missing/invalid signature, stale timestamp, or bad JSON.
2097
+ *
2098
+ * @example
2099
+ * app.post("/webhooks/graph8", (req, res) => {
2100
+ * const event = g8.webhooks.constructEvent(
2101
+ * req.rawBody,
2102
+ * req.header("X-Studio-Signature"),
2103
+ * req.header("X-Studio-Timestamp"),
2104
+ * process.env.G8_WEBHOOK_SECRET,
2105
+ * { toleranceSeconds: 300 },
2106
+ * );
2107
+ * if (event.event === "meeting.booked") { ... }
2108
+ * res.sendStatus(200);
2109
+ * });
1744
2110
  */
1745
- declare const createWebhooksClient: (apiKey: string, apiUrl?: string) => {
1746
- /** Register a listener for a webhook event. Starts polling automatically. */
1747
- on(event: WebhookEvent, callback: WebhookCallback): void;
1748
- /** Stop all webhook polling. */
1749
- stop(): void;
2111
+ declare function constructEvent(payload: string, signature: string, timestamp: string | number, secret: string, opts?: ConstructEventOptions): WebhookEventPayload;
2112
+ /**
2113
+ * Webhooks client (server-side). graph8 webhooks are PUSH — graph8 POSTs to your
2114
+ * endpoint; you verify each delivery with {@link constructEvent}. (The previous
2115
+ * polling implementation hit a feed endpoint that never existed and is removed.)
2116
+ */
2117
+ declare const createWebhooksClient: (_apiKey: string, apiUrl?: string) => {
2118
+ /** Base URL the webhook subscription API lives under. */
2119
+ baseUrl: string;
2120
+ /** Known event types (for autocomplete / validation). */
2121
+ knownEvents: readonly ["campaign.created", "campaign.updated", "campaign.deleted", "campaign.launched", "campaign.paused", "campaign.completed", "campaign.status_changed", "campaign.content_ready", "document.generated", "document.failed", "intelligence.completed", "intelligence.failed", "company.enriched", "company_intelligence.completed", "audience.ready", "audience.failed", "sequence.deployed", "sequence.started", "sequence.paused", "sequence.completed", "engagement.email_sent", "engagement.email_replied", "engagement.email_bounced", "engagement.email_skipped", "engagement.call_dispatched", "engagement.sms_sent", "engagement.sms_replied", "engagement.whatsapp_sent", "engagement.linkedin_connection_sent", "engagement.linkedin_message_sent", "engagement.linkedin_inmail_sent", "engagement.linkedin_reply_received", "engagement.linkedin_connection_accepted", "meeting.booked", "meeting.cancelled", "meeting.rescheduled"];
2122
+ /** Verify an incoming webhook's HMAC signature and return the parsed event. */
2123
+ constructEvent(payload: string, signature: string, timestamp: string | number, secret: string, opts?: ConstructEventOptions): WebhookEventPayload;
1750
2124
  };
1751
2125
 
1752
2126
  interface LandingPage {
@@ -1757,7 +2131,9 @@ interface LandingPage {
1757
2131
  published_url: string | null;
1758
2132
  }
1759
2133
  /**
1760
- * Landing pages - clone, create, publish. Requires API key (server-side).
2134
+ * Landing pages - clone, create, publish. Requires API key (server-side). On the
2135
+ * hardened HTTP core: throws a typed `G8Error` on failure and retries transient
2136
+ * errors.
1761
2137
  */
1762
2138
  declare const createPagesClient: (apiKey: string, apiUrl?: string) => {
1763
2139
  /** Clone a landing page from any URL. */
@@ -2115,6 +2491,12 @@ interface AnalyticsOverview {
2115
2491
  }
2116
2492
  /**
2117
2493
  * Analytics - dashboard data and metrics. Requires API key (server-side).
2494
+ *
2495
+ * On the hardened HTTP core: throws a typed `G8Error` on failure and retries
2496
+ * transient errors. Note the deliberate behavior change vs the preview client —
2497
+ * a non-2xx response now **throws** instead of silently returning an all-zeros
2498
+ * overview, so callers can distinguish genuinely-zero activity from an auth/5xx
2499
+ * failure.
2118
2500
  */
2119
2501
  declare const createAnalyticsClient: (apiKey: string, apiUrl?: string) => {
2120
2502
  overview(config?: {
@@ -2147,7 +2529,9 @@ interface Integration {
2147
2529
  connected_at: string | null;
2148
2530
  }
2149
2531
  /**
2150
- * Integrations - connect CRM platforms, trigger syncs. Requires API key (server-side).
2532
+ * Integrations - connect CRM platforms, trigger syncs. Requires API key
2533
+ * (server-side). On the hardened HTTP core: throws a typed `G8Error` on failure
2534
+ * and retries transient errors.
2151
2535
  */
2152
2536
  declare const createIntegrationsClient: (apiKey: string, apiUrl?: string) => {
2153
2537
  list(): Promise<Integration[]>;
@@ -2183,6 +2567,8 @@ interface CampaignStats {
2183
2567
  }
2184
2568
  /**
2185
2569
  * Campaigns - create, manage, launch campaigns. Requires API key (server-side).
2570
+ * On the hardened HTTP core: throws a typed `G8Error` on failure and retries
2571
+ * transient errors.
2186
2572
  */
2187
2573
  declare const createCampaignsClient: (apiKey: string, apiUrl?: string) => {
2188
2574
  list(page?: number, limit?: number): Promise<Campaign[]>;
@@ -2459,7 +2845,8 @@ interface SearchResults {
2459
2845
  /**
2460
2846
  * Enrichment API - person/company lookup, email verification, prospecting search.
2461
2847
  *
2462
- * Requires API key (server-side only). Credits charged per call.
2848
+ * Requires API key (server-side only). Credits charged per call. On the hardened
2849
+ * HTTP core: throws a typed `G8Error` on failure and retries transient errors.
2463
2850
  */
2464
2851
  declare const createEnrichClient: (apiKey: string, apiUrl?: string) => {
2465
2852
  /** Look up a person by email, LinkedIn, or name + company. Costs 1 credit. */
@@ -2736,6 +3123,11 @@ declare class G8 {
2736
3123
  /** @internal */ _intent: ReturnType<typeof createIntentClient> | null;
2737
3124
  /** @internal */ _studio: ReturnType<typeof createStudioClient> | null;
2738
3125
  /** @internal */ _meetings: ReturnType<typeof createMeetingsClient> | null;
3126
+ /** @internal */ _audiences: ReturnType<typeof createAudiencesClient> | null;
3127
+ /** @internal */ _search: ReturnType<typeof createSearchClient> | null;
3128
+ /** @internal */ _agency: ReturnType<typeof createAgencyClient> | null;
3129
+ /** @internal */ _marketplace: ReturnType<typeof createMarketplaceClient> | null;
3130
+ /** @internal */ _snippet: ReturnType<typeof createSnippetClient> | null;
2739
3131
  /**
2740
3132
  * Initialize the graph8 SDK. Must be called before any other method.
2741
3133
  * Safe to call on the server (SSR) - becomes a no-op for tracking.
@@ -2796,19 +3188,7 @@ declare class G8 {
2796
3188
  company_domain?: string;
2797
3189
  }): Promise<PersonEnrichment>;
2798
3190
  company(params: {
2799
- domain
2800
- /**
2801
- * graph8 SDK client.
2802
- *
2803
- * Handles event tracking, identity, and progressive forms.
2804
- *
2805
- * Usage:
2806
- * import { g8 } from '@graph8/js';
2807
- * g8.init({ writeKey: 'your_write_key' });
2808
- * g8.track('page_view', { page: '/pricing' });
2809
- * g8.identify('user@acme.com', { name: 'John', company: 'Acme' });
2810
- */
2811
- ?: string;
3191
+ domain?: string;
2812
3192
  name?: string;
2813
3193
  }): Promise<CompanyEnrichment>;
2814
3194
  verifyEmail(email: string): Promise<EmailVerification>;
@@ -2934,8 +3314,9 @@ declare class G8 {
2934
3314
  };
2935
3315
  /** Webhook event listeners (requires API key). */
2936
3316
  get webhooks(): {
2937
- on(event: WebhookEvent, callback: (data: Record<string, unknown>) => void): void;
2938
- stop(): void;
3317
+ baseUrl: string;
3318
+ knownEvents: readonly ["campaign.created", "campaign.updated", "campaign.deleted", "campaign.launched", "campaign.paused", "campaign.completed", "campaign.status_changed", "campaign.content_ready", "document.generated", "document.failed", "intelligence.completed", "intelligence.failed", "company.enriched", "company_intelligence.completed", "audience.ready", "audience.failed", "sequence.deployed", "sequence.started", "sequence.paused", "sequence.completed", "engagement.email_sent", "engagement.email_replied", "engagement.email_bounced", "engagement.email_skipped", "engagement.call_dispatched", "engagement.sms_sent", "engagement.sms_replied", "engagement.whatsapp_sent", "engagement.linkedin_connection_sent", "engagement.linkedin_message_sent", "engagement.linkedin_inmail_sent", "engagement.linkedin_reply_received", "engagement.linkedin_connection_accepted", "meeting.booked", "meeting.cancelled", "meeting.rescheduled"];
3319
+ constructEvent(payload: string, signature: string, timestamp: string | number, secret: string, opts?: ConstructEventOptions): WebhookEventPayload;
2939
3320
  };
2940
3321
  /** Contacts CRUD (requires API key). */
2941
3322
  get contacts(): {
@@ -2944,7 +3325,7 @@ declare class G8 {
2944
3325
  total: number;
2945
3326
  }>;
2946
3327
  get(contactId: number): Promise<Contact>;
2947
- create(contact: ContactCreateParams): Promise<Contact>;
3328
+ create(contact: ContactCreateParams, idempotencyKey?: string): Promise<Contact>;
2948
3329
  update(contactId: number, fields: ContactUpdateParams): Promise<{
2949
3330
  updated: number;
2950
3331
  }>;
@@ -3346,7 +3727,7 @@ declare class G8 {
3346
3727
  }>;
3347
3728
  keywordContacts(keywordId: string, params?: {
3348
3729
  limit?: number;
3349
- date_from? /** @internal */: string;
3730
+ date_from?: string;
3350
3731
  date_to?: string;
3351
3732
  }): Promise<{
3352
3733
  data: IntentContact[];
@@ -3409,7 +3790,7 @@ declare class G8 {
3409
3790
  }>;
3410
3791
  personas(params?: {
3411
3792
  status?: string;
3412
- limit?: number;
3793
+ limit? /** @internal */: number;
3413
3794
  }): Promise<{
3414
3795
  data: Persona[];
3415
3796
  }>;
@@ -3439,6 +3820,63 @@ declare class G8 {
3439
3820
  }>;
3440
3821
  get(meetingId: string): Promise<MeetingDetail>;
3441
3822
  };
3823
+ /** Audiences — sync audience lists to ad platforms (Meta, LinkedIn, Google, X) (requires API key). */
3824
+ get audiences(): {
3825
+ list(): Promise<{
3826
+ data: AudienceSync[];
3827
+ }>;
3828
+ create(params: AudienceSyncCreateParams): Promise<AudienceSync>;
3829
+ get(configId: number): Promise<AudienceSync>;
3830
+ update(configId: number, fields: AudienceSyncUpdateParams): Promise<AudienceSync>;
3831
+ delete(configId: number): Promise<{
3832
+ data: Record<string, unknown>;
3833
+ }>;
3834
+ trigger(configId: number): Promise<{
3835
+ data: Record<string, unknown>;
3836
+ }>;
3837
+ runs(configId: number): Promise<{
3838
+ data: AudienceSyncRun[];
3839
+ }>;
3840
+ errors(configId: number): Promise<{
3841
+ data: AudienceSyncError[];
3842
+ }>;
3843
+ };
3844
+ /** Search — prospect open-data contacts + companies by filter, optionally save to a list (requires API key). */
3845
+ get search(): {
3846
+ contacts(params?: SearchParams): Promise<{
3847
+ data: SearchContactItem[];
3848
+ }>;
3849
+ companies(params?: SearchParams): Promise<{
3850
+ data: SearchCompanyItem[];
3851
+ }>;
3852
+ saveContacts(params: SearchSaveParams): Promise<SearchSaveResult>;
3853
+ saveCompanies(params: SearchSaveParams): Promise<SearchSaveResult>;
3854
+ };
3855
+ /** Agency — for agency keys: discover the agency credential + the client orgs it may target (requires API key). */
3856
+ get agency(): {
3857
+ me(): Promise<AgencyInfo>;
3858
+ clients(): Promise<{
3859
+ data: AgencyClient[];
3860
+ }>;
3861
+ };
3862
+ /** Marketplace — for SDR/AE talent: profile, hire offers (accept/reject), active hirings (requires API key). */
3863
+ get marketplace(): {
3864
+ profile(): Promise<MarketplaceProfile>;
3865
+ offers(): Promise<{
3866
+ offers: MarketplaceOffer[];
3867
+ count: number;
3868
+ }>;
3869
+ acceptOffer(hiringId: string): Promise<Record<string, unknown>>;
3870
+ rejectOffer(hiringId: string): Promise<Record<string, unknown>>;
3871
+ hirings(): Promise<{
3872
+ hirings: MarketplaceHiring[];
3873
+ count: number;
3874
+ }>;
3875
+ };
3876
+ /** Snippet — fetch your org's tracking snippet (write key + React/script-tag embeds + config) for embedding (requires API key). */
3877
+ get snippet(): {
3878
+ get(): Promise<Snippet>;
3879
+ };
3442
3880
  /** Whether the SDK has been initialized. */
3443
3881
  get initialized(): boolean;
3444
3882
  /** @internal */
@@ -3449,4 +3887,88 @@ declare class G8 {
3449
3887
  /** Singleton g8 client instance. */
3450
3888
  declare const g8: G8;
3451
3889
 
3452
- export { type AddToSequenceConfig, type AnalyticsOverview, type Booking, type BookingRequest, type CalendarConfig, type CallAnalysis, type CallGradingResult, type Campaign, type CampaignCreateConfig, type CampaignStats, type ChatConfig, type Company, type CompanyColumn, type CompanyColumnCreateParams, type CompanyContact, type CompanyEnrichment, type CompanyListParams, type CompanyUpdateParams, type Contact, type ContactColumn, type ContactColumnCreateParams, type ContactCreateParams, type ContactDeal, type ContactList, type ContactListParams, type ContactUpdateParams, type CopilotConfig, type CreatedField, type Deal, type DealCreateParams, type DealListParams, type DealUpdateParams, type DialerAgentSummary, type DialerAgentsListParams, type DialerAgentsListResult, type DialerNumberInfo, type DialerNumbersListResult, type DialerReportFilters, type DialerReportMetric, type DialerSessionCreateParams, type DialerSessionCreateResult, type DialerSessionResumeResult, type DialerSessionStatus, type DialerSessionStatusUpdateResult, type DialerSessionSummary, type DialerSessionsListParams, type DialerSessionsListResult, type DialerStatsParams, type DialerStatsResult, type EmailVerification, type EnrichLookupResult, type EvidenceKey, type Field, type FieldCreateParams, type FieldDeleteParams, type G8Config, type G8PrivacyConfig, type GlobalContextDocument, type ICP, type IdentifyProperties, type InboxAssignResult, type InboxAssignee, type InboxChannel, type InboxContact, type InboxDraft, type InboxListParams, type InboxMessage, type InboxSendParams, type InboxSendResult, type InboxTag, type InboxTagResult, type InboxThread, type Integration, type IntelligenceData, type IntentCompany, type IntentContact, type IntentKeyword, type IntentPage, type IntentSignals, type IntentStats, type IntentVisitor, type LandingPage, type ListContact, type MeetingAnalysis, type MeetingAttendee, type MeetingDetail, type MeetingListParams, type MeetingSummary, type MeetingTranscriptLine, type MissedCallback, type MissedCallbacksResult, type NodeTypeSchema, type Note, type PaginationMeta$1 as PaginationMeta, type PersonEnrichment, type Persona, type Pipeline, type PipelineStage, type PipelineSuggestion, type QuotableProduct, type QuoteCreateParams, type QuoteDetail, type QuoteLineItem, type QuoteListParams, type QuoteSendParams, type QuoteSettings, type QuoteStatus, type QuoteSummary, type QuoteUpdateParams, type ResearchReport, type SearchFilter, type SearchResults, type Sequence, type SequenceActionResult, type SequenceAnalytics, type SequenceChannelConfig, type SequenceContactItem, type SequenceContactsParams, type SequenceCreateParams, type SequenceCreateResult, type SequenceDetail, type SequenceKind, type SequenceListItem, type SequenceListParams, type SequencePreview, type SequencePreviewChannel, type SequencePreviewStep, type SequenceStepConfig, type SequenceStepInputType, type SequenceStepType, type SequenceStepUpdateParams, type SequenceUpdateParams, type SetFieldValueParams, type Skill, type SkillCreateAPIParams, type SkillCreateLLMParams, type SkillInputField, type SkillListParams, type SkillTemplate, type SkillType, type SkillUpdateAPIParams, type SkillUpdateLLMParams, type StageCreateParams, type StagePipeline, type StagePipelineCreateParams, type StagePipelineStage, type StagePipelineUpdateParams, type StageUpdateParams, type Task, type TaskCreateParams, type TaskListParams, type TaskUpdateParams, type TimeSlot, type TrackProperties, type VisitorCompany, type VisitorScore, type VoicePagination, type VoiceSession, type WebhookEvent, type Workflow, type WorkflowConfig, type WorkflowConnection, type WorkflowCreateParams, type WorkflowExecution, type WorkflowListParams, type WorkflowNode, type WorkflowUpdateParams, g8 };
3890
+ /**
3891
+ * Hardened HTTP core for the graph8 JS SDK (sprint B2).
3892
+ *
3893
+ * Resource clients historically called `fetch` directly and returned
3894
+ * `resp.json()` even on a 4xx/5xx — so API errors surfaced silently as "data".
3895
+ * This module centralizes the request path with:
3896
+ *
3897
+ * - a typed `G8Error` (status, type, code, request_id, detail) thrown on any
3898
+ * non-2xx response, parsed from the standard ApiError envelope;
3899
+ * - automatic retry with exponential backoff + jitter on 429 and 5xx,
3900
+ * honoring the `Retry-After` header;
3901
+ * - `Idempotency-Key` support for safe POST retries (pairs with the backend
3902
+ * idempotency added in A6);
3903
+ * - a cursor `paginate()` async-iterator that follows `next_cursor` (A9).
3904
+ *
3905
+ * `fetch` and `sleep` are injectable so the retry/backoff logic is
3906
+ * deterministically unit-testable without real timers or network.
3907
+ */
3908
+ declare class G8Error extends Error {
3909
+ readonly status: number;
3910
+ readonly type: string;
3911
+ readonly code?: string;
3912
+ readonly requestId?: string;
3913
+ readonly detail?: unknown;
3914
+ /** True when the failure class is transient (429/5xx/network). */
3915
+ readonly retryable: boolean;
3916
+ constructor(args: {
3917
+ message: string;
3918
+ status: number;
3919
+ type: string;
3920
+ code?: string;
3921
+ requestId?: string;
3922
+ detail?: unknown;
3923
+ retryable?: boolean;
3924
+ });
3925
+ }
3926
+ /** 429 and 5xx are the transient classes worth retrying. */
3927
+ declare function isRetryableStatus(status: number): boolean;
3928
+ /**
3929
+ * Parse a `Retry-After` header into milliseconds. Supports both the
3930
+ * delta-seconds form (`"2"`) and the HTTP-date form. Returns null when absent
3931
+ * or unparseable so the caller falls back to computed backoff.
3932
+ */
3933
+ declare function parseRetryAfter(header: string | null | undefined, nowMs?: number): number | null;
3934
+ /** Exponential backoff with full jitter, capped at 10s. */
3935
+ declare function backoffDelayMs(attempt: number, baseMs?: number, rand?: () => number): number;
3936
+ interface RequestOptions {
3937
+ method?: string;
3938
+ body?: unknown;
3939
+ headers?: Record<string, string>;
3940
+ query?: Record<string, unknown>;
3941
+ /** Sent as the `Idempotency-Key` header (safe POST retries; see A6). */
3942
+ idempotencyKey?: string;
3943
+ /** Max retry attempts on 429/5xx/network (default 2 -> up to 3 tries). */
3944
+ maxRetries?: number;
3945
+ /** Base backoff in ms (default 200). */
3946
+ retryBaseMs?: number;
3947
+ signal?: AbortSignal;
3948
+ /** Injected for tests; defaults to global fetch. */
3949
+ fetchImpl?: typeof fetch;
3950
+ /** Injected for tests; defaults to a real setTimeout sleep. */
3951
+ sleepImpl?: (ms: number) => Promise<void>;
3952
+ }
3953
+ /**
3954
+ * Perform a JSON request with retries + typed errors. Returns the parsed JSON
3955
+ * envelope (callers unwrap `.data` as today). Throws `G8Error` on any non-2xx
3956
+ * after exhausting retries.
3957
+ */
3958
+ declare function request<T = unknown>(baseUrl: string, path: string, apiKey: string, opts?: RequestOptions): Promise<T>;
3959
+ interface PaginatedResponse<T> {
3960
+ data: T[];
3961
+ pagination?: {
3962
+ next_cursor?: string | null;
3963
+ has_next?: boolean;
3964
+ page?: number;
3965
+ };
3966
+ }
3967
+ /**
3968
+ * Auto-pagination async iterator following `next_cursor` (A9). Yields every
3969
+ * item across pages so callers can `for await (const x of paginate(...))`
3970
+ * without manual cursor bookkeeping.
3971
+ */
3972
+ declare function paginate<T>(fetchPage: (cursor?: string) => Promise<PaginatedResponse<T>>): AsyncGenerator<T, void, unknown>;
3973
+
3974
+ export { type AddToSequenceConfig, type AgencyClient, type AgencyInfo, type AnalyticsOverview, type AudienceSync, type AudienceSyncCreateParams, type AudienceSyncError, type AudienceSyncMode, type AudienceSyncPlatform, type AudienceSyncRun, type AudienceSyncUpdateParams, type Booking, type BookingRequest, type CalendarConfig, type CallAnalysis, type CallGradingResult, type Campaign, type CampaignCreateConfig, type CampaignStats, type ChatConfig, type Company, type CompanyColumn, type CompanyColumnCreateParams, type CompanyContact, type CompanyEnrichment, type CompanyListParams, type CompanyUpdateParams, type ConstructEventOptions, type Contact, type ContactColumn, type ContactColumnCreateParams, type ContactCreateParams, type ContactDeal, type ContactList, type ContactListParams, type ContactUpdateParams, type CopilotConfig, type CreatedField, type Deal, type DealCreateParams, type DealListParams, type DealUpdateParams, type DialerAgentSummary, type DialerAgentsListParams, type DialerAgentsListResult, type DialerNumberInfo, type DialerNumbersListResult, type DialerReportFilters, type DialerReportMetric, type DialerSessionCreateParams, type DialerSessionCreateResult, type DialerSessionResumeResult, type DialerSessionStatus, type DialerSessionStatusUpdateResult, type DialerSessionSummary, type DialerSessionsListParams, type DialerSessionsListResult, type DialerStatsParams, type DialerStatsResult, type EmailVerification, type EnrichLookupResult, type EvidenceKey, type Field, type FieldCreateParams, type FieldDeleteParams, type G8Config, G8Error, type G8PrivacyConfig, type GlobalContextDocument, type ICP, type IdentifyProperties, type InboxAssignResult, type InboxAssignee, type InboxChannel, type InboxContact, type InboxDraft, type InboxListParams, type InboxMessage, type InboxSendParams, type InboxSendResult, type InboxTag, type InboxTagResult, type InboxThread, type Integration, type IntelligenceData, type IntentCompany, type IntentContact, type IntentKeyword, type IntentPage, type IntentSignals, type IntentStats, type IntentVisitor, KNOWN_WEBHOOK_EVENTS, type LandingPage, type ListContact, type MarketplaceHiring, type MarketplaceOffer, type MarketplaceProfile, type MeetingAnalysis, type MeetingAttendee, type MeetingDetail, type MeetingListParams, type MeetingSummary, type MeetingTranscriptLine, type MissedCallback, type MissedCallbacksResult, type NodeTypeSchema, type Note, type PaginatedResponse, type PaginationMeta$1 as PaginationMeta, type PersonEnrichment, type Persona, type Pipeline, type PipelineStage, type PipelineSuggestion, type QuotableProduct, type QuoteCreateParams, type QuoteDetail, type QuoteLineItem, type QuoteListParams, type QuoteSendParams, type QuoteSettings, type QuoteStatus, type QuoteSummary, type QuoteUpdateParams, type RequestOptions, type ResearchReport, type SearchCompanyItem, type SearchCondition, type SearchContactItem, type SearchFilter, type SearchOperator, type SearchParams, type SearchResults, type SearchSaveParams, type SearchSaveResult, type Sequence, type SequenceActionResult, type SequenceAnalytics, type SequenceChannelConfig, type SequenceContactItem, type SequenceContactsParams, type SequenceCreateParams, type SequenceCreateResult, type SequenceDetail, type SequenceKind, type SequenceListItem, type SequenceListParams, type SequencePreview, type SequencePreviewChannel, type SequencePreviewStep, type SequenceStepConfig, type SequenceStepInputType, type SequenceStepType, type SequenceStepUpdateParams, type SequenceUpdateParams, type SetFieldValueParams, type Skill, type SkillCreateAPIParams, type SkillCreateLLMParams, type SkillInputField, type SkillListParams, type SkillTemplate, type SkillType, type SkillUpdateAPIParams, type SkillUpdateLLMParams, type Snippet, type StageCreateParams, type StagePipeline, type StagePipelineCreateParams, type StagePipelineStage, type StagePipelineUpdateParams, type StageUpdateParams, type Task, type TaskCreateParams, type TaskListParams, type TaskUpdateParams, type TimeSlot, type TrackProperties, type VisitorCompany, type VisitorScore, type VoicePagination, type VoiceSession, type WebhookEvent, type WebhookEventPayload, WebhookSignatureError, type Workflow, type WorkflowConfig, type WorkflowConnection, type WorkflowCreateParams, type WorkflowExecution, type WorkflowListParams, type WorkflowNode, type WorkflowUpdateParams, backoffDelayMs, constructEvent, g8, isRetryableStatus, paginate, parseRetryAfter, request };