@graph8/sdk 0.5.0 → 0.5.3

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/react.d.mts CHANGED
@@ -135,10 +135,13 @@ interface ResearchReport {
135
135
  * GET /api/v1/research-reports
136
136
  */
137
137
  declare const createStudioClient: (apiKey: string, apiUrl?: string) => {
138
- /** Org-level Studio documents (brand_brief, value_props, messaging_house, etc.). */
138
+ /** Org-level Studio documents (brand_brief, value_props, messaging_house, etc.).
139
+ * `include_content` defaults to true server-side, so each document includes
140
+ * its `content` body unless you explicitly pass `include_content: false`. */
139
141
  globalContext(params?: {
140
142
  category?: string;
141
143
  limit?: number;
144
+ include_content?: boolean;
142
145
  }): Promise<{
143
146
  data: GlobalContextDocument[];
144
147
  }>;
@@ -1376,6 +1379,14 @@ interface Task {
1376
1379
  created_by: string | null;
1377
1380
  created_at: string | null;
1378
1381
  updated_at: string | null;
1382
+ /** Parent task UUID when this row is a subtask, else null. One level deep. */
1383
+ parent_task_id?: string | null;
1384
+ /** Sort position within the parent's subtasks. 0 when not a subtask. */
1385
+ subtask_sort_order?: number | null;
1386
+ /** Number of subtasks under this task (top-level rows only). */
1387
+ subtask_count?: number | null;
1388
+ /** Subset of subtask_count whose status is "completed". */
1389
+ completed_subtask_count?: number | null;
1379
1390
  }
1380
1391
  interface TaskCreateParams {
1381
1392
  title: string;
@@ -1385,6 +1396,16 @@ interface TaskCreateParams {
1385
1396
  assignee_id?: string;
1386
1397
  /** 0=none, 1=urgent, 2=high, 3=normal, 4=low */
1387
1398
  priority?: number;
1399
+ /**
1400
+ * When set, the new task is created as a subtask of this parent. Parent
1401
+ * must exist and must not itself be a subtask (subtasks are one level
1402
+ * deep).
1403
+ */
1404
+ parent_task_id?: string;
1405
+ /**
1406
+ * Sort position within the parent's subtasks. Omit to append at the end.
1407
+ */
1408
+ subtask_sort_order?: number;
1388
1409
  }
1389
1410
  interface TaskUpdateParams {
1390
1411
  title?: string;
@@ -1394,6 +1415,14 @@ interface TaskUpdateParams {
1394
1415
  /** "open" | "completed" */
1395
1416
  status?: string;
1396
1417
  priority?: number;
1418
+ /**
1419
+ * Re-parent this task into a subtask of the given parent. Parent must
1420
+ * exist, must not itself be a subtask, and a task that already has
1421
+ * subtasks of its own cannot be demoted into a subtask.
1422
+ */
1423
+ parent_task_id?: string;
1424
+ /** Reorder within the parent's subtasks. Can be sent alone. */
1425
+ subtask_sort_order?: number;
1397
1426
  }
1398
1427
  interface TaskListParams {
1399
1428
  /** "open" | "completed" */
@@ -2187,6 +2216,8 @@ interface SequenceListParams {
2187
2216
  limit?: number;
2188
2217
  /** Filter by sequence status (e.g. "live", "draft", "paused"). */
2189
2218
  status?: string;
2219
+ /** Filter by sequence kind ("cold_outbound" or "nurture"). Omit to list all kinds. */
2220
+ sequence_kind?: SequenceKind;
2190
2221
  }
2191
2222
  interface SequenceDetail {
2192
2223
  id: string;
@@ -2200,6 +2231,10 @@ interface SequenceDetail {
2200
2231
  wait_for_new_contacts: boolean;
2201
2232
  paused_at: string | null;
2202
2233
  resumed_at: string | null;
2234
+ /** Sequence kind. Immutable after creation. "cold_outbound" (default) or "nurture". */
2235
+ sequence_kind?: string | null;
2236
+ /** Pinned mailbox for nurture sequences; null for cold_outbound. Immutable. */
2237
+ pinned_mailbox_id?: number | null;
2203
2238
  created_at: string | null;
2204
2239
  updated_at: string | null;
2205
2240
  }
@@ -2244,6 +2279,13 @@ interface SequenceChannelConfig {
2244
2279
  channel_type: string;
2245
2280
  channel_data?: Record<string, unknown>;
2246
2281
  }
2282
+ /**
2283
+ * Sequence kind. A "nurture" is an ordinary sequence with `sequence_kind:
2284
+ * "nurture"` — same step types as cold outreach, but pinned to a single mailbox
2285
+ * with a higher daily email cap. There is no separate nurture client; create one
2286
+ * via `sequences.create({ sequence_kind: "nurture", pinned_mailbox_id })`.
2287
+ */
2288
+ type SequenceKind = "cold_outbound" | "nurture";
2247
2289
  interface SequenceCreateParams {
2248
2290
  name: string;
2249
2291
  user_email: string;
@@ -2255,6 +2297,18 @@ interface SequenceCreateParams {
2255
2297
  steps?: SequenceStepConfig[];
2256
2298
  channels?: SequenceChannelConfig[];
2257
2299
  campaign_id?: string;
2300
+ /**
2301
+ * Sequence kind. Defaults to "cold_outbound" server-side. Immutable after
2302
+ * creation. "nurture" requires `pinned_mailbox_id` and is gated by the
2303
+ * ENABLE_NURTURE feature flag.
2304
+ */
2305
+ sequence_kind?: SequenceKind;
2306
+ /**
2307
+ * Mailbox to pin for a nurture sequence. Required when
2308
+ * `sequence_kind: "nurture"`; all email channels must use this mailbox.
2309
+ * Ignored for cold_outbound sequences.
2310
+ */
2311
+ pinned_mailbox_id?: number;
2258
2312
  }
2259
2313
  interface SequenceCreateResult {
2260
2314
  id: string;
@@ -3320,6 +3374,7 @@ declare const useG8: () => {
3320
3374
  globalContext(params?: {
3321
3375
  category?: string;
3322
3376
  limit?: number;
3377
+ include_content?: boolean;
3323
3378
  }): Promise<{
3324
3379
  data: GlobalContextDocument[];
3325
3380
  }>;
package/dist/react.d.ts CHANGED
@@ -135,10 +135,13 @@ interface ResearchReport {
135
135
  * GET /api/v1/research-reports
136
136
  */
137
137
  declare const createStudioClient: (apiKey: string, apiUrl?: string) => {
138
- /** Org-level Studio documents (brand_brief, value_props, messaging_house, etc.). */
138
+ /** Org-level Studio documents (brand_brief, value_props, messaging_house, etc.).
139
+ * `include_content` defaults to true server-side, so each document includes
140
+ * its `content` body unless you explicitly pass `include_content: false`. */
139
141
  globalContext(params?: {
140
142
  category?: string;
141
143
  limit?: number;
144
+ include_content?: boolean;
142
145
  }): Promise<{
143
146
  data: GlobalContextDocument[];
144
147
  }>;
@@ -1376,6 +1379,14 @@ interface Task {
1376
1379
  created_by: string | null;
1377
1380
  created_at: string | null;
1378
1381
  updated_at: string | null;
1382
+ /** Parent task UUID when this row is a subtask, else null. One level deep. */
1383
+ parent_task_id?: string | null;
1384
+ /** Sort position within the parent's subtasks. 0 when not a subtask. */
1385
+ subtask_sort_order?: number | null;
1386
+ /** Number of subtasks under this task (top-level rows only). */
1387
+ subtask_count?: number | null;
1388
+ /** Subset of subtask_count whose status is "completed". */
1389
+ completed_subtask_count?: number | null;
1379
1390
  }
1380
1391
  interface TaskCreateParams {
1381
1392
  title: string;
@@ -1385,6 +1396,16 @@ interface TaskCreateParams {
1385
1396
  assignee_id?: string;
1386
1397
  /** 0=none, 1=urgent, 2=high, 3=normal, 4=low */
1387
1398
  priority?: number;
1399
+ /**
1400
+ * When set, the new task is created as a subtask of this parent. Parent
1401
+ * must exist and must not itself be a subtask (subtasks are one level
1402
+ * deep).
1403
+ */
1404
+ parent_task_id?: string;
1405
+ /**
1406
+ * Sort position within the parent's subtasks. Omit to append at the end.
1407
+ */
1408
+ subtask_sort_order?: number;
1388
1409
  }
1389
1410
  interface TaskUpdateParams {
1390
1411
  title?: string;
@@ -1394,6 +1415,14 @@ interface TaskUpdateParams {
1394
1415
  /** "open" | "completed" */
1395
1416
  status?: string;
1396
1417
  priority?: number;
1418
+ /**
1419
+ * Re-parent this task into a subtask of the given parent. Parent must
1420
+ * exist, must not itself be a subtask, and a task that already has
1421
+ * subtasks of its own cannot be demoted into a subtask.
1422
+ */
1423
+ parent_task_id?: string;
1424
+ /** Reorder within the parent's subtasks. Can be sent alone. */
1425
+ subtask_sort_order?: number;
1397
1426
  }
1398
1427
  interface TaskListParams {
1399
1428
  /** "open" | "completed" */
@@ -2187,6 +2216,8 @@ interface SequenceListParams {
2187
2216
  limit?: number;
2188
2217
  /** Filter by sequence status (e.g. "live", "draft", "paused"). */
2189
2218
  status?: string;
2219
+ /** Filter by sequence kind ("cold_outbound" or "nurture"). Omit to list all kinds. */
2220
+ sequence_kind?: SequenceKind;
2190
2221
  }
2191
2222
  interface SequenceDetail {
2192
2223
  id: string;
@@ -2200,6 +2231,10 @@ interface SequenceDetail {
2200
2231
  wait_for_new_contacts: boolean;
2201
2232
  paused_at: string | null;
2202
2233
  resumed_at: string | null;
2234
+ /** Sequence kind. Immutable after creation. "cold_outbound" (default) or "nurture". */
2235
+ sequence_kind?: string | null;
2236
+ /** Pinned mailbox for nurture sequences; null for cold_outbound. Immutable. */
2237
+ pinned_mailbox_id?: number | null;
2203
2238
  created_at: string | null;
2204
2239
  updated_at: string | null;
2205
2240
  }
@@ -2244,6 +2279,13 @@ interface SequenceChannelConfig {
2244
2279
  channel_type: string;
2245
2280
  channel_data?: Record<string, unknown>;
2246
2281
  }
2282
+ /**
2283
+ * Sequence kind. A "nurture" is an ordinary sequence with `sequence_kind:
2284
+ * "nurture"` — same step types as cold outreach, but pinned to a single mailbox
2285
+ * with a higher daily email cap. There is no separate nurture client; create one
2286
+ * via `sequences.create({ sequence_kind: "nurture", pinned_mailbox_id })`.
2287
+ */
2288
+ type SequenceKind = "cold_outbound" | "nurture";
2247
2289
  interface SequenceCreateParams {
2248
2290
  name: string;
2249
2291
  user_email: string;
@@ -2255,6 +2297,18 @@ interface SequenceCreateParams {
2255
2297
  steps?: SequenceStepConfig[];
2256
2298
  channels?: SequenceChannelConfig[];
2257
2299
  campaign_id?: string;
2300
+ /**
2301
+ * Sequence kind. Defaults to "cold_outbound" server-side. Immutable after
2302
+ * creation. "nurture" requires `pinned_mailbox_id` and is gated by the
2303
+ * ENABLE_NURTURE feature flag.
2304
+ */
2305
+ sequence_kind?: SequenceKind;
2306
+ /**
2307
+ * Mailbox to pin for a nurture sequence. Required when
2308
+ * `sequence_kind: "nurture"`; all email channels must use this mailbox.
2309
+ * Ignored for cold_outbound sequences.
2310
+ */
2311
+ pinned_mailbox_id?: number;
2258
2312
  }
2259
2313
  interface SequenceCreateResult {
2260
2314
  id: string;
@@ -3320,6 +3374,7 @@ declare const useG8: () => {
3320
3374
  globalContext(params?: {
3321
3375
  category?: string;
3322
3376
  limit?: number;
3377
+ include_content?: boolean;
3323
3378
  }): Promise<{
3324
3379
  data: GlobalContextDocument[];
3325
3380
  }>;
package/dist/react.js CHANGED
@@ -1994,7 +1994,9 @@ var createStudioClient = (apiKey, apiUrl) => {
1994
1994
  return resp.json();
1995
1995
  };
1996
1996
  return {
1997
- /** Org-level Studio documents (brand_brief, value_props, messaging_house, etc.). */
1997
+ /** Org-level Studio documents (brand_brief, value_props, messaging_house, etc.).
1998
+ * `include_content` defaults to true server-side, so each document includes
1999
+ * its `content` body unless you explicitly pass `include_content: false`. */
1998
2000
  async globalContext(params = {}) {
1999
2001
  return get("/global-context/documents", params);
2000
2002
  },