@graph8/sdk 0.357.0 → 0.361.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +1 -1
- package/dist/index.browser.js +1 -1
- package/dist/index.browser.js.map +1 -1
- package/dist/index.browser.mjs +1 -1
- package/dist/index.browser.mjs.map +1 -1
- package/dist/index.d.mts +115 -9
- package/dist/index.d.ts +115 -9
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/react.browser.js +1 -1
- package/dist/react.browser.js.map +1 -1
- package/dist/react.browser.mjs +1 -1
- package/dist/react.browser.mjs.map +1 -1
- package/dist/react.d.mts +112 -6
- package/dist/react.d.ts +112 -6
- package/dist/react.js +1 -1
- package/dist/react.js.map +1 -1
- package/dist/react.mjs +1 -1
- package/dist/react.mjs.map +1 -1
- package/dist/types/core.d.ts +3 -2
- package/dist/types/react.d.ts +2 -0
- package/dist/types/studio.d.ts +48 -0
- package/dist/types/version.d.ts +2 -2
- package/docs/api/adCampaigns.d.ts +4 -0
- package/docs/api/adCampaigns.md +4 -0
- package/docs/api/enrichment.d.ts +18 -0
- package/docs/api/enrichment.md +25 -4
- package/docs/api/gtmCampaigns.d.ts +4 -0
- package/docs/api/gtmCampaigns.md +2 -0
- package/docs/api/gtmContext.d.ts +5 -1
- package/docs/api/gtmContext.md +15 -7
- package/docs/api/integrations.d.ts +29 -4
- package/docs/api/integrations.md +14 -0
- package/docs/api/revenueLifecycle.d.ts +3 -1
- package/docs/api/revenueLifecycle.md +12 -2
- package/docs/api/seo.d.ts +1 -1
- package/docs/api/seo.md +1 -1
- package/docs/api/workflows.md +46 -2
- package/docs/sdk-clients.md +1 -1
- package/package.json +1 -1
package/docs/api/workflows.md
CHANGED
|
@@ -193,6 +193,14 @@ Send an `Idempotency-Key` header as well for the app-wide guard.
|
|
|
193
193
|
Every execution in the batch is scoped to the caller's org before it is
|
|
194
194
|
touched; ids belonging to another tenant are simply not found.
|
|
195
195
|
|
|
196
|
+
A restart runs each workflow as it is NOW. When one has record steps or a
|
|
197
|
+
record trigger, the key needs the object scopes they exercise (403
|
|
198
|
+
``missing_scopes`` refuses the whole batch, nothing restarts), and only the
|
|
199
|
+
workflow's owner or a graph8 admin may restart it: for any other member that
|
|
200
|
+
item is reported in ``failed`` with ``owner_or_admin_required`` while the
|
|
201
|
+
rest of the batch goes ahead. When graph8 cannot confirm who is an admin,
|
|
202
|
+
that item is refused, never guessed, and also reported in ``failed``.
|
|
203
|
+
|
|
196
204
|
**Input**
|
|
197
205
|
|
|
198
206
|
| Field | Type | Required | Description |
|
|
@@ -319,6 +327,13 @@ const result = await g8.api.workflows.createWorkbench({ body: {} });
|
|
|
319
327
|
Create a new workflow. Pins ``org_id`` and ``runtime_type='workflow'``
|
|
320
328
|
server-side - the body cannot override either.
|
|
321
329
|
|
|
330
|
+
The workflow's OWNER is the authenticated caller, never a body field: a
|
|
331
|
+
body ``created_by`` is dropped (see ``voice_owner_headers``). Record steps
|
|
332
|
+
and record triggers run with the owner's record access, so the key must hold
|
|
333
|
+
the object scopes they exercise (403 ``missing_scopes``). A node or trigger
|
|
334
|
+
config that carries the same key in snake_case and camelCase with values
|
|
335
|
+
that disagree is refused (422 ``conflicting_node_keys``): keep one spelling.
|
|
336
|
+
|
|
322
337
|
Translates the public ``config`` field to voice's internal
|
|
323
338
|
``skill_config`` before forwarding (see module docstring).
|
|
324
339
|
|
|
@@ -573,6 +588,14 @@ const result = await g8.api.workflows.diffSkillVersions({ path: { action_id: "id
|
|
|
573
588
|
|
|
574
589
|
Trigger a workflow run. Returns ``execution_id`` for polling.
|
|
575
590
|
|
|
591
|
+
A workflow with record steps or a record trigger runs them with its OWNER's
|
|
592
|
+
record access, and this run's input feeds them: the key must hold the object
|
|
593
|
+
scopes they exercise (403 ``missing_scopes``) and its member must own the
|
|
594
|
+
workflow or administer the org (403 ``owner_or_admin_required``, from the
|
|
595
|
+
workflow service, which receives the member as the verified identity). The
|
|
596
|
+
saved workflow is read before the run so that check is never skipped: when
|
|
597
|
+
it cannot be read, the answer is ``502`` and nothing runs.
|
|
598
|
+
|
|
576
599
|
Pins ``org_id`` server-side; the caller cannot override which org's
|
|
577
600
|
execution row is created. ``triggered_by`` defaults to the caller's
|
|
578
601
|
user id when not supplied.
|
|
@@ -1908,6 +1931,14 @@ a paused run instead, use `POST /workflows/executions/{id}/resume`.
|
|
|
1908
1931
|
The org is forwarded and voice scopes the lookup by it, so one tenant
|
|
1909
1932
|
cannot restart another's run.
|
|
1910
1933
|
|
|
1934
|
+
A restart runs the workflow as it is NOW, with the original or new input.
|
|
1935
|
+
When it has record steps or a record trigger, the key needs the object
|
|
1936
|
+
scopes they exercise (403 ``missing_scopes``), and only the workflow's
|
|
1937
|
+
owner or a graph8 admin may restart it, with reused or new input (403
|
|
1938
|
+
``owner_or_admin_required``). When graph8 cannot confirm who is an admin the
|
|
1939
|
+
restart is refused, never guessed: the workflow service answers 503, which
|
|
1940
|
+
reaches the caller as ``502`` like its other upstream failures; retry later.
|
|
1941
|
+
|
|
1911
1942
|
**Input**
|
|
1912
1943
|
|
|
1913
1944
|
| Field | Type | Required | Description |
|
|
@@ -1941,7 +1972,14 @@ const result = await g8.api.workflows.restartExecution({ path: { execution_id: "
|
|
|
1941
1972
|
|
|
1942
1973
|
SPENDS NOTHING. Publishes the old snapshot as a NEW version, live for the
|
|
1943
1974
|
next run - agents and workflows using the skill pick it up. Append-only, so
|
|
1944
|
-
the restore can itself be rolled back. Routine-managed skills refuse (403).
|
|
1975
|
+
the restore can itself be rolled back. Routine-managed skills refuse (403). A
|
|
1976
|
+
restored graph with record steps or a record trigger needs the same object
|
|
1977
|
+
scopes as a create or an update (403 ``missing_scopes``), a restored graph
|
|
1978
|
+
whose snake_case and camelCase node keys disagree is refused (422
|
|
1979
|
+
``conflicting_node_keys``), and a restore that changes such a workflow's
|
|
1980
|
+
graph is refused (403 ``owner_or_admin_required``) unless the key's member
|
|
1981
|
+
owns the workflow or administers the org. The version's graph is read first
|
|
1982
|
+
to run those checks: 404 when it cannot be found (unknown skill or version).
|
|
1945
1983
|
|
|
1946
1984
|
**Input**
|
|
1947
1985
|
|
|
@@ -2250,7 +2288,13 @@ const result = await g8.api.workflows.updateSkillTestCase({ path: { action_id: "
|
|
|
2250
2288
|
- ★ Hand-written: [`g8.workflows.update()`](../sdk-clients.md#g8-workflows-update)
|
|
2251
2289
|
|
|
2252
2290
|
Update a workflow. The voice update endpoint takes ``org_id`` as a
|
|
2253
|
-
query param and the partial body in JSON, so we forward both.
|
|
2291
|
+
query param and the partial body in JSON, so we forward both. A graph with
|
|
2292
|
+
record steps or a record trigger needs the object scopes they exercise
|
|
2293
|
+
(403 ``missing_scopes``), like create, and a node or trigger config whose
|
|
2294
|
+
snake_case and camelCase keys disagree is refused (422
|
|
2295
|
+
``conflicting_node_keys``). On a workflow with record steps or a record
|
|
2296
|
+
trigger, only its owner or a graph8 admin may change what it runs (403
|
|
2297
|
+
``owner_or_admin_required``); its name and description stay editable.
|
|
2254
2298
|
|
|
2255
2299
|
Translates the public ``config`` field to voice's internal
|
|
2256
2300
|
``skill_config`` before forwarding (see module docstring).
|
package/docs/sdk-clients.md
CHANGED
|
@@ -3593,7 +3593,7 @@ Create a buyer persona manually (no AI generation). Requires title + website_url
|
|
|
3593
3593
|
### `g8.studio.globalContext`
|
|
3594
3594
|
|
|
3595
3595
|
```ts
|
|
3596
|
-
g8.studio.globalContext: (params?: { category?: string; limit?: number; include_content?: boolean; }) => Promise<{ data: GlobalContextDocument[]; }>
|
|
3596
|
+
g8.studio.globalContext: (params?: { category?: string; limit?: number; include_content?: boolean; include_intelligence?: boolean; include_research?: boolean; }) => Promise<{ data: GlobalContextDocument[]; }>
|
|
3597
3597
|
```
|
|
3598
3598
|
|
|
3599
3599
|
Org-level Studio documents (brand_brief, value_props, messaging_house, etc.). `include_content` defaults to true server-side, so each document includes its `content` body unless you explicitly pass `include_content: false`.
|
package/package.json
CHANGED