@gitbook/api 0.207.0 → 0.208.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/client.d.ts +133 -13
- package/dist/constants.d.ts +5 -1
- package/dist/index.cjs +32 -2
- package/dist/index.js +27 -2
- package/package.json +1 -1
- package/spec/openapi.json +358 -6
- package/spec/openapi.yaml +239 -5
package/dist/client.d.ts
CHANGED
|
@@ -373,6 +373,13 @@ export declare enum SiteQuestionAnswerHelpfulness {
|
|
|
373
373
|
Medium = "medium",
|
|
374
374
|
High = "high"
|
|
375
375
|
}
|
|
376
|
+
/** Size of a timeline bucket. Weeks start on Sunday, and every bucket is in UTC. */
|
|
377
|
+
export declare enum SiteQuestionTimelineInterval {
|
|
378
|
+
Hour = "hour",
|
|
379
|
+
Day = "day",
|
|
380
|
+
Week = "week",
|
|
381
|
+
Month = "month"
|
|
382
|
+
}
|
|
376
383
|
/** Whether the response answered the question. */
|
|
377
384
|
export declare enum SiteQuestionAnswerResolution {
|
|
378
385
|
No = "no",
|
|
@@ -454,8 +461,8 @@ export declare enum SiteQuestionType {
|
|
|
454
461
|
}
|
|
455
462
|
/**
|
|
456
463
|
* An action that moves a finding to another state. A finding's `actions` lists the ones it allows.
|
|
457
|
-
* - `approve` makes the redirect GitBook drafted for a broken link live, which resolves the finding.
|
|
458
|
-
* - `reject` deletes the redirect GitBook drafted for a broken link; the finding stays open and GitBook won't draft a fix for it again.
|
|
464
|
+
* - `approve` makes the redirect GitBook drafted for a broken link live, which resolves the finding. A change request GitBook drafted for an outbound link is approved by merging it.
|
|
465
|
+
* - `reject` deletes the redirect GitBook drafted for a broken link; the finding stays open and GitBook won't draft a fix for it again. For an outbound link, it archives the change request GitBook drafted (`awaitingChangeRequest`) and unlinks every link it fixes. They are open again, marked `undone`, and GitBook won't draft a fix for them again.
|
|
459
466
|
* - `create-redirect` creates a redirect for a broken link's path with `createSiteRedirect`, prefilled with the suggestion; it resolves the finding.
|
|
460
467
|
* - `mark-resolved` resolves it. A broken link resolved this way has no redirect: visitors still get a 404.
|
|
461
468
|
* - `reopen` reopens a resolved finding. For a broken link, it deletes the live redirect at its path; for a fix GitBook applied, this undoes the fix and GitBook won't fix the link again.
|
|
@@ -488,7 +495,7 @@ export declare enum SiteTriageFilterQuestions {
|
|
|
488
495
|
/**
|
|
489
496
|
* Where a link finding stands, from its status and what GitBook did with it.
|
|
490
497
|
* - `open` needs a fix.
|
|
491
|
-
* - `awaiting-approval` has a
|
|
498
|
+
* - `awaiting-approval` has a fix GitBook drafted, waiting to be approved or rejected: a redirect at a `broken-link` finding's path, or an unmerged change request for an `outbound-link-error` finding (`awaitingChangeRequest`).
|
|
492
499
|
* - `resolved` was fixed or closed: `servingRedirect` says whether a live redirect serves its path.
|
|
493
500
|
* - `ignored` was dismissed.
|
|
494
501
|
*/
|
|
@@ -1250,6 +1257,7 @@ export declare enum DocumentTextColor {
|
|
|
1250
1257
|
Violet = "violet",
|
|
1251
1258
|
Cyan = "cyan",
|
|
1252
1259
|
Primary = "$primary",
|
|
1260
|
+
Secondary = "$secondary",
|
|
1253
1261
|
Info = "$info",
|
|
1254
1262
|
Success = "$success",
|
|
1255
1263
|
Warning = "$warning",
|
|
@@ -1475,7 +1483,11 @@ export type ChangeRequestContentChange = ({
|
|
|
1475
1483
|
operation: "update_reusable_content";
|
|
1476
1484
|
} & ChangeRequestContentChangeUpdateReusableContent) | ({
|
|
1477
1485
|
operation: "delete_reusable_content";
|
|
1478
|
-
} & ChangeRequestContentChangeDeleteReusableContent)
|
|
1486
|
+
} & ChangeRequestContentChangeDeleteReusableContent) | ({
|
|
1487
|
+
operation: "insert_variables";
|
|
1488
|
+
} & ChangeRequestContentChangeInsertVariables) | ({
|
|
1489
|
+
operation: "update_variable";
|
|
1490
|
+
} & ChangeRequestContentChangeUpdateVariable);
|
|
1479
1491
|
export type Revision = RevisionTypeEdits | RevisionTypeMerge | RevisionTypeRollback | RevisionTypeUpdate | RevisionTypeComputed;
|
|
1480
1492
|
export type RevisionPage = RevisionPageDocument | RevisionPageGroup | RevisionPageLink | RevisionPageComputed;
|
|
1481
1493
|
export interface ApiInformation {
|
|
@@ -4042,6 +4054,41 @@ export interface ChangeRequestContentChangeDeleteReusableContent {
|
|
|
4042
4054
|
/** ID of the reusable content to delete. */
|
|
4043
4055
|
reusableContent: string;
|
|
4044
4056
|
}
|
|
4057
|
+
/**
|
|
4058
|
+
* Name of a variable, referenced in content as `space.vars.<name>`. It starts with a letter, `_` or `$` and contains only letters, digits, `_` and `$`.
|
|
4059
|
+
* @minLength 1
|
|
4060
|
+
* @maxLength 64
|
|
4061
|
+
* @pattern ^[a-zA-Z_$][a-zA-Z0-9_$]*$
|
|
4062
|
+
*/
|
|
4063
|
+
export type VariableName = string;
|
|
4064
|
+
/**
|
|
4065
|
+
* Create space variables in the change request (Git Sync's `.gitbook/vars.yaml`). Content references one as an expression, `<code class="expression">space.vars.<name></code>` in markdown, which renders the variable's value.
|
|
4066
|
+
* @example {"operation":"insert_variables","variables":[{"name":"version","value":"2.0"}]}
|
|
4067
|
+
*/
|
|
4068
|
+
export interface ChangeRequestContentChangeInsertVariables {
|
|
4069
|
+
operation: "insert_variables";
|
|
4070
|
+
/**
|
|
4071
|
+
* @maxItems 50
|
|
4072
|
+
* @minItems 1
|
|
4073
|
+
*/
|
|
4074
|
+
variables: {
|
|
4075
|
+
/** Name of a variable, referenced in content as `space.vars.<name>`. It starts with a letter, `_` or `$` and contains only letters, digits, `_` and `$`. */
|
|
4076
|
+
name: VariableName;
|
|
4077
|
+
/** Value of the variable. */
|
|
4078
|
+
value: VariableValue;
|
|
4079
|
+
}[];
|
|
4080
|
+
}
|
|
4081
|
+
/**
|
|
4082
|
+
* Change the value of an existing space variable. Every expression referencing it shows the new value.
|
|
4083
|
+
* @example {"operation":"update_variable","variable":"version","value":"2.1"}
|
|
4084
|
+
*/
|
|
4085
|
+
export interface ChangeRequestContentChangeUpdateVariable {
|
|
4086
|
+
operation: "update_variable";
|
|
4087
|
+
/** Name of the variable to update. */
|
|
4088
|
+
variable: VariableName;
|
|
4089
|
+
/** New value of the variable. */
|
|
4090
|
+
value: VariableValue;
|
|
4091
|
+
}
|
|
4045
4092
|
export interface ChangeRequestContentUpdatePageRef {
|
|
4046
4093
|
/** Type of Object, always equals to "page". */
|
|
4047
4094
|
object: "page";
|
|
@@ -7557,6 +7604,8 @@ export interface SiteCustomizationSettingsBase {
|
|
|
7557
7604
|
*/
|
|
7558
7605
|
theme: CustomizationTheme;
|
|
7559
7606
|
primaryColor: CustomizationThemedColor;
|
|
7607
|
+
/** Secondary brand color, used for secondary buttons and for content colored with `$secondary`. When not set, these elements use the neutral colors of the site. */
|
|
7608
|
+
secondaryColor?: CustomizationThemedColor;
|
|
7560
7609
|
tint?: CustomizationTint;
|
|
7561
7610
|
infoColor: CustomizationThemedColor;
|
|
7562
7611
|
successColor: CustomizationThemedColor;
|
|
@@ -8219,6 +8268,18 @@ export interface SiteFindingServingRedirect {
|
|
|
8219
8268
|
/** Whether GitBook created the redirect on its own. */
|
|
8220
8269
|
createdByAgent: boolean;
|
|
8221
8270
|
}
|
|
8271
|
+
/**
|
|
8272
|
+
* Awaiting change request
|
|
8273
|
+
* The change request GitBook drafted to fix an `outbound-link-error` finding, waiting to be approved or rejected. Approving it means merging it. Reject it with `applySiteFindingAction`.
|
|
8274
|
+
*/
|
|
8275
|
+
export interface SiteFindingAwaitingChangeRequest {
|
|
8276
|
+
/** ID of the space the change request is in. */
|
|
8277
|
+
space: string;
|
|
8278
|
+
/** ID of the change request. */
|
|
8279
|
+
changeRequest: string;
|
|
8280
|
+
/** Number of open outbound links on the site the change request fixes. */
|
|
8281
|
+
findings: number;
|
|
8282
|
+
}
|
|
8222
8283
|
/**
|
|
8223
8284
|
* Available action
|
|
8224
8285
|
* An action a finding allows now, with the site permission it needs.
|
|
@@ -8226,8 +8287,8 @@ export interface SiteFindingServingRedirect {
|
|
|
8226
8287
|
export interface SiteFindingAvailableAction {
|
|
8227
8288
|
/**
|
|
8228
8289
|
* An action that moves a finding to another state. A finding's `actions` lists the ones it allows.
|
|
8229
|
-
* - `approve` makes the redirect GitBook drafted for a broken link live, which resolves the finding.
|
|
8230
|
-
* - `reject` deletes the redirect GitBook drafted for a broken link; the finding stays open and GitBook won't draft a fix for it again.
|
|
8290
|
+
* - `approve` makes the redirect GitBook drafted for a broken link live, which resolves the finding. A change request GitBook drafted for an outbound link is approved by merging it.
|
|
8291
|
+
* - `reject` deletes the redirect GitBook drafted for a broken link; the finding stays open and GitBook won't draft a fix for it again. For an outbound link, it archives the change request GitBook drafted (`awaitingChangeRequest`) and unlinks every link it fixes. They are open again, marked `undone`, and GitBook won't draft a fix for them again.
|
|
8231
8292
|
* - `create-redirect` creates a redirect for a broken link's path with `createSiteRedirect`, prefilled with the suggestion; it resolves the finding.
|
|
8232
8293
|
* - `mark-resolved` resolves it. A broken link resolved this way has no redirect: visitors still get a 404.
|
|
8233
8294
|
* - `reopen` reopens a resolved finding. For a broken link, it deletes the live redirect at its path; for a fix GitBook applied, this undoes the fix and GitBook won't fix the link again.
|
|
@@ -8323,13 +8384,15 @@ export interface SiteFinding {
|
|
|
8323
8384
|
/**
|
|
8324
8385
|
* Where a link finding stands, from its status and what GitBook did with it.
|
|
8325
8386
|
* - `open` needs a fix.
|
|
8326
|
-
* - `awaiting-approval` has a
|
|
8387
|
+
* - `awaiting-approval` has a fix GitBook drafted, waiting to be approved or rejected: a redirect at a `broken-link` finding's path, or an unmerged change request for an `outbound-link-error` finding (`awaitingChangeRequest`).
|
|
8327
8388
|
* - `resolved` was fixed or closed: `servingRedirect` says whether a live redirect serves its path.
|
|
8328
8389
|
* - `ignored` was dismissed.
|
|
8329
8390
|
*/
|
|
8330
8391
|
state?: SiteFindingState;
|
|
8331
8392
|
/** The live redirect serving a `broken-link` finding's path. */
|
|
8332
8393
|
servingRedirect?: SiteFindingServingRedirect;
|
|
8394
|
+
/** The change request GitBook drafted to fix an `outbound-link-error` finding, waiting to be approved or rejected. Approving it means merging it. Reject it with `applySiteFindingAction`. */
|
|
8395
|
+
awaitingChangeRequest?: SiteFindingAwaitingChangeRequest;
|
|
8333
8396
|
/** Actions the finding allows now, applied with `applySiteFindingAction`. */
|
|
8334
8397
|
actions?: SiteFindingAvailableAction[];
|
|
8335
8398
|
/** Suggested fix for a broken-link finding, shaped as the input for `createSiteRedirect` so it can be applied directly. Absent when the finding has no directly applicable redirect (for example, a suggestion to create a new page). The destination is absent when the audit judged the URL and found no page to redirect to: a redirect can still be created from the source with a destination of your choosing. */
|
|
@@ -8825,6 +8888,18 @@ export type SiteQuestionAnswerSourceRecord = SiteQuestionAnswerSourceBase & {
|
|
|
8825
8888
|
/** Integration source */
|
|
8826
8889
|
connector?: ContextConnector;
|
|
8827
8890
|
};
|
|
8891
|
+
export interface SiteQuestionTimelineBucket {
|
|
8892
|
+
/** Start of the bucket. */
|
|
8893
|
+
time: Timestamp;
|
|
8894
|
+
/** Count of answers given during the bucket. */
|
|
8895
|
+
answers: number;
|
|
8896
|
+
/** Count of distinct visitors who received those answers. */
|
|
8897
|
+
visitors: number;
|
|
8898
|
+
}
|
|
8899
|
+
/** Ask AI answers counted per bucket, oldest first. */
|
|
8900
|
+
export interface SiteQuestionTimeline {
|
|
8901
|
+
items: SiteQuestionTimelineBucket[];
|
|
8902
|
+
}
|
|
8828
8903
|
export interface SiteQuestionAnswer {
|
|
8829
8904
|
object: "site-question-answer";
|
|
8830
8905
|
/** The ID of the site question answer. */
|
|
@@ -13289,7 +13364,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
13289
13364
|
computed?: boolean;
|
|
13290
13365
|
}, params?: RequestParams) => Promise<HttpResponse<Revision, any>>;
|
|
13291
13366
|
/**
|
|
13292
|
-
* @description Applies an ordered array of content changes (up to 50) to the change request atomically, creating a single new revision. Changes are applied sequentially; if any single change is invalid the entire batch is rejected and no revision is created. Use this to create, update, rename, move, or delete pages within a change request before merging to live. This is the primary way to programmatically author content in a change request. **Renaming a page** — `update_page` can change a page's `title` and/or its `slug` (the path segment used to build its URL within its current parent). Both fields are independent: to rename only the title without changing the URL, set `title` and omit `slug`; to change the URL without changing the title, set `slug` and omit `title`. **Moving a page** — `update_page` can also change a page's parent and/or its position among siblings with `into`/`at`. Set `into` to the new parent's page ID, or `null` to move the page to the root of the tree; omit `into` to leave the parent unchanged. Set `at` to place the page at a specific zero-based index among its new siblings; omit it to leave the position unchanged (when the parent isn't changing) or append at the end (when it is). A page cannot be moved under itself or one of its own descendants. `insert_page`'s `into`/`at` remain the way to place a **new** page at creation time. To put an image or attachment in a page, upload it with an `insert_files` change. Give the file a `ref` and a page inserted in the same batch can reference it as `` or `[File](./<ref>)`, which resolves to the file's ID at apply time regardless of operation order. Uploaded files are also listed as `insertedFiles` when `compat=false`, and a file already in the change request can be referenced directly as `/files/<fileId>`. Inline `data:` URIs in markdown are not ingested and large image blocks are dropped, so upload the bytes with `insert_files` instead. **Reusable content** (snippets shared by several pages, Git Sync's `.gitbook/includes/`) is created with `insert_reusable_contents`, changed with `update_reusable_content` and removed with `delete_reusable_content`. A page includes one in markdown as `{% include "/reusable-content/<reusableContentId>" %}`; give a new one a `ref` and a page in the same batch can include it as `{% include "./<ref>" %}`, regardless of operation order. Created reusable contents are listed as `insertedReusableContents` when `compat=false`. An update keeps the ID, so every page including it shows the change. Deleting one leaves the includes in pages unresolved, as in the editor: remove them from those pages too. Reusable content cannot include other reusable content, so an include in its document is dropped. Unlike a link, an include that matches no reusable content of the change request (or of the batch) rejects the batch, since dropping it would remove it from the page silently. **Publishing an OpenAPI spec** — an OpenAPI spec belongs to the organization (see `createOpenAPISpec`) and appears in a space only through a page that renders it. Insert that page with an `insert_computed_page` change: `{ "operation": "insert_computed_page", "title": "API reference", "computed": { "type": "builtin:openapi", "props": { "models": true }, "dependencies": { "spec": { "ref": { "kind": "openapi", "spec": "<spec slug>" } } } } }`. GitBook replaces that page, at its position, with the API reference: one page per tag (or per operation with `"grouping": "by-operation"` in `props`), plus a models page when `models` is true, regenerated whenever the spec changes. Use `into` to nest the reference under an existing page. Do not recreate a spec with `insert_page`: `openapi-operation` blocks in a document only render the operations they name. When page content is provided as markdown, links to other pages are resolved against the change request's current page tree. You can link a page by: - Page ID — `/pages/<pageId>` (also `/pages/<pageId>#anchor`). - Page slug path — `/pages/<slug>` for a top-level page, or `/pages/<parent-slug>/<slug>` for a nested page (e.g. `/pages/guides/getting-started`). - Markdown file path — the path the page would have in Git: `/pages/<slug>.md` for a page, or `/pages/<slug>/README.md` for a page that has child pages. The space's root page is `/pages/README.md`. - Relative markdown link — resolved against the page being edited, e.g. `./sibling.md`, `../other.md`, or `../README.md` (the parent page). Folder-style links without an extension (e.g. `./section`) resolve to that folder's page. External URLs (`https://…`) are kept as-is. A link that does not match any page in the change request is left as plain text rather than causing the request to fail. GitBook normalizes submitted content, so the stored page may differ from what was sent. To help callers reconcile local state with the stored result, the response can list each created and modified page with its resolved ID and a `urls.location` to fetch the page's persisted content. For change requests with frequent concurrent edits, consider `expectedRevision` to protect against overwriting changes made since your read. If the branch has changed since the supplied revision, the batch is rejected with HTTP 409 and none of the submitted changes are applied. **Response shape (`compat`)** — this endpoint is changing what it returns: - `compat=true` (current default) returns the updated change request, matching the endpoint's original behavior. - `compat=false` returns the updated change request **and** the list of affected pages (see the response schema). The default is `true` for now to preserve backwards compatibility, but **will switch to `false` in a future release**, at which point the affected-page list is always included. You should pass `compat=false` if you want the new behavior today and avoid unexpected errors when the default flips in the future.
|
|
13367
|
+
* @description Applies an ordered array of content changes (up to 50) to the change request atomically, creating a single new revision. Changes are applied sequentially; if any single change is invalid the entire batch is rejected and no revision is created. Use this to create, update, rename, move, or delete pages within a change request before merging to live. This is the primary way to programmatically author content in a change request. **Renaming a page** — `update_page` can change a page's `title` and/or its `slug` (the path segment used to build its URL within its current parent). Both fields are independent: to rename only the title without changing the URL, set `title` and omit `slug`; to change the URL without changing the title, set `slug` and omit `title`. **Moving a page** — `update_page` can also change a page's parent and/or its position among siblings with `into`/`at`. Set `into` to the new parent's page ID, or `null` to move the page to the root of the tree; omit `into` to leave the parent unchanged. Set `at` to place the page at a specific zero-based index among its new siblings; omit it to leave the position unchanged (when the parent isn't changing) or append at the end (when it is). A page cannot be moved under itself or one of its own descendants. `insert_page`'s `into`/`at` remain the way to place a **new** page at creation time. To put an image or attachment in a page, upload it with an `insert_files` change. Give the file a `ref` and a page inserted in the same batch can reference it as `` or `[File](./<ref>)`, which resolves to the file's ID at apply time regardless of operation order. Uploaded files are also listed as `insertedFiles` when `compat=false`, and a file already in the change request can be referenced directly as `/files/<fileId>`. Inline `data:` URIs in markdown are not ingested and large image blocks are dropped, so upload the bytes with `insert_files` instead. **Reusable content** (snippets shared by several pages, Git Sync's `.gitbook/includes/`) is created with `insert_reusable_contents`, changed with `update_reusable_content` and removed with `delete_reusable_content`. A page includes one in markdown as `{% include "/reusable-content/<reusableContentId>" %}`; give a new one a `ref` and a page in the same batch can include it as `{% include "./<ref>" %}`, regardless of operation order. Created reusable contents are listed as `insertedReusableContents` when `compat=false`. An update keeps the ID, so every page including it shows the change. Deleting one leaves the includes in pages unresolved, as in the editor: remove them from those pages too. Reusable content cannot include other reusable content, so an include in its document is dropped. Unlike a link, an include that matches no reusable content of the change request (or of the batch) rejects the batch, since dropping it would remove it from the page silently. **Variables** (space variables, Git Sync's `.gitbook/vars.yaml`) are created with `insert_variables` and changed with `update_variable`. A variable is identified by its name, which content references as an expression: `<code class="expression">space.vars.<name></code>` in markdown. Inserting a name the change request already uses, or updating one it does not, rejects the batch. **Publishing an OpenAPI spec** — an OpenAPI spec belongs to the organization (see `createOpenAPISpec`) and appears in a space only through a page that renders it. Insert that page with an `insert_computed_page` change: `{ "operation": "insert_computed_page", "title": "API reference", "computed": { "type": "builtin:openapi", "props": { "models": true }, "dependencies": { "spec": { "ref": { "kind": "openapi", "spec": "<spec slug>" } } } } }`. GitBook replaces that page, at its position, with the API reference: one page per tag (or per operation with `"grouping": "by-operation"` in `props`), plus a models page when `models` is true, regenerated whenever the spec changes. Use `into` to nest the reference under an existing page. Do not recreate a spec with `insert_page`: `openapi-operation` blocks in a document only render the operations they name. When page content is provided as markdown, links to other pages are resolved against the change request's current page tree. You can link a page by: - Page ID — `/pages/<pageId>` (also `/pages/<pageId>#anchor`). - Page slug path — `/pages/<slug>` for a top-level page, or `/pages/<parent-slug>/<slug>` for a nested page (e.g. `/pages/guides/getting-started`). - Markdown file path — the path the page would have in Git: `/pages/<slug>.md` for a page, or `/pages/<slug>/README.md` for a page that has child pages. The space's root page is `/pages/README.md`. - Relative markdown link — resolved against the page being edited, e.g. `./sibling.md`, `../other.md`, or `../README.md` (the parent page). Folder-style links without an extension (e.g. `./section`) resolve to that folder's page. External URLs (`https://…`) are kept as-is. A link that does not match any page in the change request is left as plain text rather than causing the request to fail. GitBook normalizes submitted content, so the stored page may differ from what was sent. To help callers reconcile local state with the stored result, the response can list each created and modified page with its resolved ID and a `urls.location` to fetch the page's persisted content. For change requests with frequent concurrent edits, consider `expectedRevision` to protect against overwriting changes made since your read. If the branch has changed since the supplied revision, the batch is rejected with HTTP 409 and none of the submitted changes are applied. **Response shape (`compat`)** — this endpoint is changing what it returns: - `compat=true` (current default) returns the updated change request, matching the endpoint's original behavior. - `compat=false` returns the updated change request **and** the list of affected pages (see the response schema). The default is `true` for now to preserve backwards compatibility, but **will switch to `false` in a future release**, at which point the affected-page list is always included. You should pass `compat=false` if you want the new behavior today and avoid unexpected errors when the default flips in the future.
|
|
13293
13368
|
*
|
|
13294
13369
|
* @tags change-request-content
|
|
13295
13370
|
* @name UpdateChangeRequestContent
|
|
@@ -15129,7 +15204,23 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
15129
15204
|
actor?: string;
|
|
15130
15205
|
/** Filter by an exact stable target identifier. */
|
|
15131
15206
|
target?: string;
|
|
15207
|
+
/** Include matching counts for action and actor options, excluding the option's own filter. */
|
|
15208
|
+
includeFacets?: boolean;
|
|
15209
|
+
/**
|
|
15210
|
+
* Include any of these action names. Combined with other filters using AND.
|
|
15211
|
+
* @maxItems 100
|
|
15212
|
+
*/
|
|
15213
|
+
actions?: string[];
|
|
15214
|
+
/**
|
|
15215
|
+
* Include any of these stable actor identifiers, including system actors. Combined with other filters using AND.
|
|
15216
|
+
* @maxItems 100
|
|
15217
|
+
*/
|
|
15218
|
+
actors?: string[];
|
|
15132
15219
|
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
15220
|
+
facets?: {
|
|
15221
|
+
actions: Record<string, number>;
|
|
15222
|
+
actors: Record<string, number>;
|
|
15223
|
+
};
|
|
15133
15224
|
items: AuditEvent[];
|
|
15134
15225
|
}, {
|
|
15135
15226
|
error: {
|
|
@@ -15205,7 +15296,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
15205
15296
|
*/
|
|
15206
15297
|
listStyleguideTemplates: (organizationId: EntityId, params?: RequestParams) => Promise<HttpResponse<StyleguideTemplates, any>>;
|
|
15207
15298
|
/**
|
|
15208
|
-
*
|
|
15299
|
+
* @description Lists the members of the organization. Guests can list members too, but the list they get leaves out every guest, themselves included, and filtering by the `guest` role returns no one.
|
|
15209
15300
|
*
|
|
15210
15301
|
* @tags organization-members
|
|
15211
15302
|
* @name ListMembersInOrganizationById
|
|
@@ -15240,7 +15331,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
15240
15331
|
items: OrganizationMember[];
|
|
15241
15332
|
}, any>>;
|
|
15242
15333
|
/**
|
|
15243
|
-
*
|
|
15334
|
+
* @description Returns a member of the organization. Guests can get any member who isn't a guest, and themselves. Another guest is reported as not found.
|
|
15244
15335
|
*
|
|
15245
15336
|
* @tags organization-members, critical
|
|
15246
15337
|
* @name GetMemberInOrganizationById
|
|
@@ -18138,7 +18229,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
18138
18229
|
items: ContextRecord[];
|
|
18139
18230
|
}, any>>;
|
|
18140
18231
|
/**
|
|
18141
|
-
* @description Applies one of the `actions` a finding lists, with the site permission it gives: resolve, dismiss or reopen it,
|
|
18232
|
+
* @description Applies one of the `actions` a finding lists, with the site permission it gives: resolve, dismiss or reopen it, act on a broken link's redirect, or reject the change request GitBook drafted for an outbound link. Returns 409 when the finding doesn't allow the action now.
|
|
18142
18233
|
*
|
|
18143
18234
|
* @tags site-context
|
|
18144
18235
|
* @name ApplySiteFindingAction
|
|
@@ -18149,8 +18240,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
18149
18240
|
applySiteFindingAction: (organizationId: EntityId, siteId: string, siteFindingId: string, data: {
|
|
18150
18241
|
/**
|
|
18151
18242
|
* An action that moves a finding to another state. A finding's `actions` lists the ones it allows.
|
|
18152
|
-
* - `approve` makes the redirect GitBook drafted for a broken link live, which resolves the finding.
|
|
18153
|
-
* - `reject` deletes the redirect GitBook drafted for a broken link; the finding stays open and GitBook won't draft a fix for it again.
|
|
18243
|
+
* - `approve` makes the redirect GitBook drafted for a broken link live, which resolves the finding. A change request GitBook drafted for an outbound link is approved by merging it.
|
|
18244
|
+
* - `reject` deletes the redirect GitBook drafted for a broken link; the finding stays open and GitBook won't draft a fix for it again. For an outbound link, it archives the change request GitBook drafted (`awaitingChangeRequest`) and unlinks every link it fixes. They are open again, marked `undone`, and GitBook won't draft a fix for them again.
|
|
18154
18245
|
* - `create-redirect` creates a redirect for a broken link's path with `createSiteRedirect`, prefilled with the suggestion; it resolves the finding.
|
|
18155
18246
|
* - `mark-resolved` resolves it. A broken link resolved this way has no redirect: visitors still get a 404.
|
|
18156
18247
|
* - `reopen` reopens a resolved finding. For a broken link, it deletes the live redirect at its path; for a fix GitBook applied, this undoes the fix and GitBook won't fix the link again.
|
|
@@ -18484,6 +18575,33 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
18484
18575
|
/** Filter stats by answer resolution. */
|
|
18485
18576
|
answered?: SiteQuestionAnswerResolution[];
|
|
18486
18577
|
}, params?: RequestParams) => Promise<HttpResponse<SiteQuestionStats, any>>;
|
|
18578
|
+
/**
|
|
18579
|
+
* @description Returns how many answers the site's Ask AI assistant gave, and to how many visitors, in each UTC bucket of the interval between `from` and `to`, optionally filtered by topic, relevance, channel, visitor type or resolution. Buckets without answers are omitted.
|
|
18580
|
+
*
|
|
18581
|
+
* @tags site-questions
|
|
18582
|
+
* @name GetSiteQuestionTimeline
|
|
18583
|
+
* @summary Get Ask AI answers over time for a site
|
|
18584
|
+
* @request GET:/orgs/{organizationId}/sites/{siteId}/question-timeline
|
|
18585
|
+
* @secure
|
|
18586
|
+
*/
|
|
18587
|
+
getSiteQuestionTimeline: (organizationId: EntityId, siteId: string, query: {
|
|
18588
|
+
/** Count answers created at or after this timestamp. */
|
|
18589
|
+
from: Timestamp;
|
|
18590
|
+
/** Count answers created at or before this timestamp. */
|
|
18591
|
+
to: Timestamp;
|
|
18592
|
+
/** Size of each bucket. An hourly timeline covers at most 31 days. */
|
|
18593
|
+
interval: SiteQuestionTimelineInterval;
|
|
18594
|
+
/** Filter answers by associated site topic IDs. */
|
|
18595
|
+
topic?: string[];
|
|
18596
|
+
/** Filter answers by question relevance. */
|
|
18597
|
+
relevance?: SiteQuestionAnswerRelevance[];
|
|
18598
|
+
/** Filter answers by channel type. */
|
|
18599
|
+
channelType?: SiteChannelType[];
|
|
18600
|
+
/** Filter by whether a person or an AI agent asked the question. */
|
|
18601
|
+
visitorType?: SiteQuestionVisitorType[];
|
|
18602
|
+
/** Filter answers by resolution. */
|
|
18603
|
+
answered?: SiteQuestionAnswerResolution[];
|
|
18604
|
+
}, params?: RequestParams) => Promise<HttpResponse<SiteQuestionTimeline, any>>;
|
|
18487
18605
|
/**
|
|
18488
18606
|
* @description Returns a paginated list of individual Ask AI answers generated for a site. Each is the assistant's response to a specific asked question, with the raw question text, channel, and feedback. Use it to review answer quality and what users asked across the site.
|
|
18489
18607
|
*
|
|
@@ -18661,6 +18779,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
18661
18779
|
theme?: CustomizationTheme | null;
|
|
18662
18780
|
/** The primary color used for links and UI text. Set to null to reset the override. */
|
|
18663
18781
|
primaryColor?: CustomizationThemedColor | null;
|
|
18782
|
+
/** The secondary brand color used for secondary buttons and content colored with `$secondary`. Set to null to reset the override. */
|
|
18783
|
+
secondaryColor?: CustomizationThemedColor | null;
|
|
18664
18784
|
/** Used for informational messages and neutral alerts. Set to null to reset the override. */
|
|
18665
18785
|
infoColor?: CustomizationThemedColor | null;
|
|
18666
18786
|
/** Used for showing positive actions or achievements. Set to null to reset the override. */
|
package/dist/constants.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ export declare const MEMBER_ROLE_ENUM: ["admin", "create", "edit", "review", "co
|
|
|
16
16
|
export declare const ORGANIZATION_TEAM_TITLE_MAX_LENGTH = 64;
|
|
17
17
|
export declare const ORGANIZATION_TEAM_TITLE_MIN_LENGTH = 1;
|
|
18
18
|
export declare const ICON_MAX_LENGTH = 50;
|
|
19
|
-
export declare const DOCUMENT_TEXT_COLOR_ENUM: ["default", "green", "blue", "red", "orange", "yellow", "purple", "pink", "violet", "cyan", "$primary", "$info", "$success", "$warning", "$danger", "$tint"];
|
|
19
|
+
export declare const DOCUMENT_TEXT_COLOR_ENUM: ["default", "green", "blue", "red", "orange", "yellow", "purple", "pink", "violet", "cyan", "$primary", "$secondary", "$info", "$success", "$warning", "$danger", "$tint"];
|
|
20
20
|
export declare const TEXT_ALIGNMENT_ENUM: ["start", "center", "end"];
|
|
21
21
|
export declare const CARDS_IMAGE_OBJECT_FIT_ENUM: ["contain", "fill", "cover"];
|
|
22
22
|
export declare const VERTICAL_ALIGNMENT_ENUM: ["top", "middle", "bottom"];
|
|
@@ -33,6 +33,9 @@ export declare const CHANGE_REQUEST_SUBJECT_MIN_LENGTH = 0;
|
|
|
33
33
|
export declare const CHANGE_REQUEST_LINK_TITLE_MAX_LENGTH = 128;
|
|
34
34
|
export declare const CHANGE_REQUEST_ORDER_BY_ENUM: ["updatedAt", "createdAt"];
|
|
35
35
|
export declare const CHANGE_REQUEST_REVIEW_STATUS_ENUM: ["changes-requested", "approved"];
|
|
36
|
+
export declare const VARIABLE_NAME_MAX_LENGTH = 64;
|
|
37
|
+
export declare const VARIABLE_NAME_MIN_LENGTH = 1;
|
|
38
|
+
export declare const VARIABLE_NAME_PATTERN = "^[a-zA-Z_$][a-zA-Z0-9_$]*$";
|
|
36
39
|
export declare const REVISION_PAGE_TYPE_ENUM: ["document", "group", "link", "computed"];
|
|
37
40
|
export declare const REVISION_PAGE_LAYOUT_PRESET_ENUM: ["docs", "editorial", "landing"];
|
|
38
41
|
export declare const MEMBER_DISABLED_REASON_ENUM: ["billing", "scim", "admin"];
|
|
@@ -199,6 +202,7 @@ export declare const SITE_CORE_CHANNEL_TYPE_ENUM: ["site", "embed", "api"];
|
|
|
199
202
|
export declare const SITE_CONFIGURABLE_CHANNEL_TYPE_ENUM: ["builtin:slack", "builtin:discord", "builtin:github", "builtin:linear"];
|
|
200
203
|
export declare const SITE_QUESTION_VISITOR_TYPE_ENUM: ["human", "agent", "bot", "unknown"];
|
|
201
204
|
export declare const SITE_QUESTION_ANSWER_RESOLUTION_ENUM: ["no", "partially", "yes"];
|
|
205
|
+
export declare const SITE_QUESTION_TIMELINE_INTERVAL_ENUM: ["hour", "day", "week", "month"];
|
|
202
206
|
export declare const SITE_QUESTION_ANSWER_HELPFULNESS_ENUM: ["low", "medium", "high"];
|
|
203
207
|
export declare const AIMESSAGE_ROLE_ENUM: ["user", "assistant", "developer"];
|
|
204
208
|
export declare const AIMESSAGE_STEP_START_CONDITION_ENUM: ["compaction"];
|
package/dist/index.cjs
CHANGED
|
@@ -491,6 +491,7 @@ __export(src_exports, {
|
|
|
491
491
|
SITE_QUESTION_ANSWER_RELEVANCE_ENUM: () => SITE_QUESTION_ANSWER_RELEVANCE_ENUM,
|
|
492
492
|
SITE_QUESTION_ANSWER_RESOLUTION_ENUM: () => SITE_QUESTION_ANSWER_RESOLUTION_ENUM,
|
|
493
493
|
SITE_QUESTION_ANSWER_SOURCE_TYPE_ENUM: () => SITE_QUESTION_ANSWER_SOURCE_TYPE_ENUM,
|
|
494
|
+
SITE_QUESTION_TIMELINE_INTERVAL_ENUM: () => SITE_QUESTION_TIMELINE_INTERVAL_ENUM,
|
|
494
495
|
SITE_QUESTION_TYPE_ENUM: () => SITE_QUESTION_TYPE_ENUM,
|
|
495
496
|
SITE_QUESTION_VISITOR_TYPE_ENUM: () => SITE_QUESTION_VISITOR_TYPE_ENUM,
|
|
496
497
|
SITE_REDIRECT_ORDER_BY_ENUM: () => SITE_REDIRECT_ORDER_BY_ENUM,
|
|
@@ -564,6 +565,7 @@ __export(src_exports, {
|
|
|
564
565
|
SiteQuestionAnswerRelevance: () => SiteQuestionAnswerRelevance,
|
|
565
566
|
SiteQuestionAnswerResolution: () => SiteQuestionAnswerResolution,
|
|
566
567
|
SiteQuestionAnswerSourceType: () => SiteQuestionAnswerSourceType,
|
|
568
|
+
SiteQuestionTimelineInterval: () => SiteQuestionTimelineInterval,
|
|
567
569
|
SiteQuestionType: () => SiteQuestionType,
|
|
568
570
|
SiteQuestionVisitorType: () => SiteQuestionVisitorType,
|
|
569
571
|
SiteRedirectOrderBy: () => SiteRedirectOrderBy,
|
|
@@ -587,6 +589,9 @@ __export(src_exports, {
|
|
|
587
589
|
TranslationLanguage: () => TranslationLanguage,
|
|
588
590
|
TranslationStatus: () => TranslationStatus,
|
|
589
591
|
URL_MAX_LENGTH: () => URL_MAX_LENGTH,
|
|
592
|
+
VARIABLE_NAME_MAX_LENGTH: () => VARIABLE_NAME_MAX_LENGTH,
|
|
593
|
+
VARIABLE_NAME_MIN_LENGTH: () => VARIABLE_NAME_MIN_LENGTH,
|
|
594
|
+
VARIABLE_NAME_PATTERN: () => VARIABLE_NAME_PATTERN,
|
|
590
595
|
VERTICAL_ALIGNMENT_ENUM: () => VERTICAL_ALIGNMENT_ENUM,
|
|
591
596
|
VerticalAlignment: () => VerticalAlignment,
|
|
592
597
|
YOUTUBE_CHANNEL_ID_PATTERN: () => YOUTUBE_CHANNEL_ID_PATTERN,
|
|
@@ -596,7 +601,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
596
601
|
|
|
597
602
|
// package.json
|
|
598
603
|
var name = "@gitbook/api";
|
|
599
|
-
var version = "0.
|
|
604
|
+
var version = "0.208.0";
|
|
600
605
|
|
|
601
606
|
// src/client.ts
|
|
602
607
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -1073,6 +1078,13 @@ var SiteQuestionAnswerHelpfulness = /* @__PURE__ */ ((SiteQuestionAnswerHelpfuln
|
|
|
1073
1078
|
SiteQuestionAnswerHelpfulness2["High"] = "high";
|
|
1074
1079
|
return SiteQuestionAnswerHelpfulness2;
|
|
1075
1080
|
})(SiteQuestionAnswerHelpfulness || {});
|
|
1081
|
+
var SiteQuestionTimelineInterval = /* @__PURE__ */ ((SiteQuestionTimelineInterval2) => {
|
|
1082
|
+
SiteQuestionTimelineInterval2["Hour"] = "hour";
|
|
1083
|
+
SiteQuestionTimelineInterval2["Day"] = "day";
|
|
1084
|
+
SiteQuestionTimelineInterval2["Week"] = "week";
|
|
1085
|
+
SiteQuestionTimelineInterval2["Month"] = "month";
|
|
1086
|
+
return SiteQuestionTimelineInterval2;
|
|
1087
|
+
})(SiteQuestionTimelineInterval || {});
|
|
1076
1088
|
var SiteQuestionAnswerResolution = /* @__PURE__ */ ((SiteQuestionAnswerResolution2) => {
|
|
1077
1089
|
SiteQuestionAnswerResolution2["No"] = "no";
|
|
1078
1090
|
SiteQuestionAnswerResolution2["Partially"] = "partially";
|
|
@@ -1862,6 +1874,7 @@ var DocumentTextColor = /* @__PURE__ */ ((DocumentTextColor2) => {
|
|
|
1862
1874
|
DocumentTextColor2["Violet"] = "violet";
|
|
1863
1875
|
DocumentTextColor2["Cyan"] = "cyan";
|
|
1864
1876
|
DocumentTextColor2["Primary"] = "$primary";
|
|
1877
|
+
DocumentTextColor2["Secondary"] = "$secondary";
|
|
1865
1878
|
DocumentTextColor2["Info"] = "$info";
|
|
1866
1879
|
DocumentTextColor2["Success"] = "$success";
|
|
1867
1880
|
DocumentTextColor2["Warning"] = "$warning";
|
|
@@ -4676,6 +4689,14 @@ var Api = class extends HttpClient {
|
|
|
4676
4689
|
format: "json",
|
|
4677
4690
|
...params
|
|
4678
4691
|
}),
|
|
4692
|
+
getSiteQuestionTimeline: (organizationId, siteId, query, params = {}) => this.request({
|
|
4693
|
+
path: `/orgs/${organizationId}/sites/${siteId}/question-timeline`,
|
|
4694
|
+
method: "GET",
|
|
4695
|
+
query,
|
|
4696
|
+
secure: true,
|
|
4697
|
+
format: "json",
|
|
4698
|
+
...params
|
|
4699
|
+
}),
|
|
4679
4700
|
listSiteQuestionAnswers: (organizationId, siteId, query, params = {}) => this.request({
|
|
4680
4701
|
path: `/orgs/${organizationId}/sites/${siteId}/answers`,
|
|
4681
4702
|
method: "GET",
|
|
@@ -5304,7 +5325,7 @@ var MEMBER_ROLE_ENUM = ["admin", "create", "edit", "review", "comment", "read"];
|
|
|
5304
5325
|
var ORGANIZATION_TEAM_TITLE_MAX_LENGTH = 64;
|
|
5305
5326
|
var ORGANIZATION_TEAM_TITLE_MIN_LENGTH = 1;
|
|
5306
5327
|
var ICON_MAX_LENGTH = 50;
|
|
5307
|
-
var DOCUMENT_TEXT_COLOR_ENUM = ["default", "green", "blue", "red", "orange", "yellow", "purple", "pink", "violet", "cyan", "$primary", "$info", "$success", "$warning", "$danger", "$tint"];
|
|
5328
|
+
var DOCUMENT_TEXT_COLOR_ENUM = ["default", "green", "blue", "red", "orange", "yellow", "purple", "pink", "violet", "cyan", "$primary", "$secondary", "$info", "$success", "$warning", "$danger", "$tint"];
|
|
5308
5329
|
var TEXT_ALIGNMENT_ENUM = ["start", "center", "end"];
|
|
5309
5330
|
var CARDS_IMAGE_OBJECT_FIT_ENUM = ["contain", "fill", "cover"];
|
|
5310
5331
|
var VERTICAL_ALIGNMENT_ENUM = ["top", "middle", "bottom"];
|
|
@@ -5321,6 +5342,9 @@ var CHANGE_REQUEST_SUBJECT_MIN_LENGTH = 0;
|
|
|
5321
5342
|
var CHANGE_REQUEST_LINK_TITLE_MAX_LENGTH = 128;
|
|
5322
5343
|
var CHANGE_REQUEST_ORDER_BY_ENUM = ["updatedAt", "createdAt"];
|
|
5323
5344
|
var CHANGE_REQUEST_REVIEW_STATUS_ENUM = ["changes-requested", "approved"];
|
|
5345
|
+
var VARIABLE_NAME_MAX_LENGTH = 64;
|
|
5346
|
+
var VARIABLE_NAME_MIN_LENGTH = 1;
|
|
5347
|
+
var VARIABLE_NAME_PATTERN = "^[a-zA-Z_$][a-zA-Z0-9_$]*$";
|
|
5324
5348
|
var REVISION_PAGE_TYPE_ENUM = ["document", "group", "link", "computed"];
|
|
5325
5349
|
var REVISION_PAGE_LAYOUT_PRESET_ENUM = ["docs", "editorial", "landing"];
|
|
5326
5350
|
var MEMBER_DISABLED_REASON_ENUM = ["billing", "scim", "admin"];
|
|
@@ -5487,6 +5511,7 @@ var SITE_CORE_CHANNEL_TYPE_ENUM = ["site", "embed", "api"];
|
|
|
5487
5511
|
var SITE_CONFIGURABLE_CHANNEL_TYPE_ENUM = ["builtin:slack", "builtin:discord", "builtin:github", "builtin:linear"];
|
|
5488
5512
|
var SITE_QUESTION_VISITOR_TYPE_ENUM = ["human", "agent", "bot", "unknown"];
|
|
5489
5513
|
var SITE_QUESTION_ANSWER_RESOLUTION_ENUM = ["no", "partially", "yes"];
|
|
5514
|
+
var SITE_QUESTION_TIMELINE_INTERVAL_ENUM = ["hour", "day", "week", "month"];
|
|
5490
5515
|
var SITE_QUESTION_ANSWER_HELPFULNESS_ENUM = ["low", "medium", "high"];
|
|
5491
5516
|
var AIMESSAGE_ROLE_ENUM = ["user", "assistant", "developer"];
|
|
5492
5517
|
var AIMESSAGE_STEP_START_CONDITION_ENUM = ["compaction"];
|
|
@@ -5924,6 +5949,7 @@ var GitBookAPI = class extends Api {
|
|
|
5924
5949
|
SITE_QUESTION_ANSWER_RELEVANCE_ENUM,
|
|
5925
5950
|
SITE_QUESTION_ANSWER_RESOLUTION_ENUM,
|
|
5926
5951
|
SITE_QUESTION_ANSWER_SOURCE_TYPE_ENUM,
|
|
5952
|
+
SITE_QUESTION_TIMELINE_INTERVAL_ENUM,
|
|
5927
5953
|
SITE_QUESTION_TYPE_ENUM,
|
|
5928
5954
|
SITE_QUESTION_VISITOR_TYPE_ENUM,
|
|
5929
5955
|
SITE_REDIRECT_ORDER_BY_ENUM,
|
|
@@ -5997,6 +6023,7 @@ var GitBookAPI = class extends Api {
|
|
|
5997
6023
|
SiteQuestionAnswerRelevance,
|
|
5998
6024
|
SiteQuestionAnswerResolution,
|
|
5999
6025
|
SiteQuestionAnswerSourceType,
|
|
6026
|
+
SiteQuestionTimelineInterval,
|
|
6000
6027
|
SiteQuestionType,
|
|
6001
6028
|
SiteQuestionVisitorType,
|
|
6002
6029
|
SiteRedirectOrderBy,
|
|
@@ -6020,6 +6047,9 @@ var GitBookAPI = class extends Api {
|
|
|
6020
6047
|
TranslationLanguage,
|
|
6021
6048
|
TranslationStatus,
|
|
6022
6049
|
URL_MAX_LENGTH,
|
|
6050
|
+
VARIABLE_NAME_MAX_LENGTH,
|
|
6051
|
+
VARIABLE_NAME_MIN_LENGTH,
|
|
6052
|
+
VARIABLE_NAME_PATTERN,
|
|
6023
6053
|
VERTICAL_ALIGNMENT_ENUM,
|
|
6024
6054
|
VerticalAlignment,
|
|
6025
6055
|
YOUTUBE_CHANNEL_ID_PATTERN,
|
package/dist/index.js
CHANGED
|
@@ -172,7 +172,7 @@ var require_node = __commonJS({
|
|
|
172
172
|
|
|
173
173
|
// package.json
|
|
174
174
|
var name = "@gitbook/api";
|
|
175
|
-
var version = "0.
|
|
175
|
+
var version = "0.208.0";
|
|
176
176
|
|
|
177
177
|
// src/client.ts
|
|
178
178
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -649,6 +649,13 @@ var SiteQuestionAnswerHelpfulness = /* @__PURE__ */ ((SiteQuestionAnswerHelpfuln
|
|
|
649
649
|
SiteQuestionAnswerHelpfulness2["High"] = "high";
|
|
650
650
|
return SiteQuestionAnswerHelpfulness2;
|
|
651
651
|
})(SiteQuestionAnswerHelpfulness || {});
|
|
652
|
+
var SiteQuestionTimelineInterval = /* @__PURE__ */ ((SiteQuestionTimelineInterval2) => {
|
|
653
|
+
SiteQuestionTimelineInterval2["Hour"] = "hour";
|
|
654
|
+
SiteQuestionTimelineInterval2["Day"] = "day";
|
|
655
|
+
SiteQuestionTimelineInterval2["Week"] = "week";
|
|
656
|
+
SiteQuestionTimelineInterval2["Month"] = "month";
|
|
657
|
+
return SiteQuestionTimelineInterval2;
|
|
658
|
+
})(SiteQuestionTimelineInterval || {});
|
|
652
659
|
var SiteQuestionAnswerResolution = /* @__PURE__ */ ((SiteQuestionAnswerResolution2) => {
|
|
653
660
|
SiteQuestionAnswerResolution2["No"] = "no";
|
|
654
661
|
SiteQuestionAnswerResolution2["Partially"] = "partially";
|
|
@@ -1438,6 +1445,7 @@ var DocumentTextColor = /* @__PURE__ */ ((DocumentTextColor2) => {
|
|
|
1438
1445
|
DocumentTextColor2["Violet"] = "violet";
|
|
1439
1446
|
DocumentTextColor2["Cyan"] = "cyan";
|
|
1440
1447
|
DocumentTextColor2["Primary"] = "$primary";
|
|
1448
|
+
DocumentTextColor2["Secondary"] = "$secondary";
|
|
1441
1449
|
DocumentTextColor2["Info"] = "$info";
|
|
1442
1450
|
DocumentTextColor2["Success"] = "$success";
|
|
1443
1451
|
DocumentTextColor2["Warning"] = "$warning";
|
|
@@ -4252,6 +4260,14 @@ var Api = class extends HttpClient {
|
|
|
4252
4260
|
format: "json",
|
|
4253
4261
|
...params
|
|
4254
4262
|
}),
|
|
4263
|
+
getSiteQuestionTimeline: (organizationId, siteId, query, params = {}) => this.request({
|
|
4264
|
+
path: `/orgs/${organizationId}/sites/${siteId}/question-timeline`,
|
|
4265
|
+
method: "GET",
|
|
4266
|
+
query,
|
|
4267
|
+
secure: true,
|
|
4268
|
+
format: "json",
|
|
4269
|
+
...params
|
|
4270
|
+
}),
|
|
4255
4271
|
listSiteQuestionAnswers: (organizationId, siteId, query, params = {}) => this.request({
|
|
4256
4272
|
path: `/orgs/${organizationId}/sites/${siteId}/answers`,
|
|
4257
4273
|
method: "GET",
|
|
@@ -4880,7 +4896,7 @@ var MEMBER_ROLE_ENUM = ["admin", "create", "edit", "review", "comment", "read"];
|
|
|
4880
4896
|
var ORGANIZATION_TEAM_TITLE_MAX_LENGTH = 64;
|
|
4881
4897
|
var ORGANIZATION_TEAM_TITLE_MIN_LENGTH = 1;
|
|
4882
4898
|
var ICON_MAX_LENGTH = 50;
|
|
4883
|
-
var DOCUMENT_TEXT_COLOR_ENUM = ["default", "green", "blue", "red", "orange", "yellow", "purple", "pink", "violet", "cyan", "$primary", "$info", "$success", "$warning", "$danger", "$tint"];
|
|
4899
|
+
var DOCUMENT_TEXT_COLOR_ENUM = ["default", "green", "blue", "red", "orange", "yellow", "purple", "pink", "violet", "cyan", "$primary", "$secondary", "$info", "$success", "$warning", "$danger", "$tint"];
|
|
4884
4900
|
var TEXT_ALIGNMENT_ENUM = ["start", "center", "end"];
|
|
4885
4901
|
var CARDS_IMAGE_OBJECT_FIT_ENUM = ["contain", "fill", "cover"];
|
|
4886
4902
|
var VERTICAL_ALIGNMENT_ENUM = ["top", "middle", "bottom"];
|
|
@@ -4897,6 +4913,9 @@ var CHANGE_REQUEST_SUBJECT_MIN_LENGTH = 0;
|
|
|
4897
4913
|
var CHANGE_REQUEST_LINK_TITLE_MAX_LENGTH = 128;
|
|
4898
4914
|
var CHANGE_REQUEST_ORDER_BY_ENUM = ["updatedAt", "createdAt"];
|
|
4899
4915
|
var CHANGE_REQUEST_REVIEW_STATUS_ENUM = ["changes-requested", "approved"];
|
|
4916
|
+
var VARIABLE_NAME_MAX_LENGTH = 64;
|
|
4917
|
+
var VARIABLE_NAME_MIN_LENGTH = 1;
|
|
4918
|
+
var VARIABLE_NAME_PATTERN = "^[a-zA-Z_$][a-zA-Z0-9_$]*$";
|
|
4900
4919
|
var REVISION_PAGE_TYPE_ENUM = ["document", "group", "link", "computed"];
|
|
4901
4920
|
var REVISION_PAGE_LAYOUT_PRESET_ENUM = ["docs", "editorial", "landing"];
|
|
4902
4921
|
var MEMBER_DISABLED_REASON_ENUM = ["billing", "scim", "admin"];
|
|
@@ -5063,6 +5082,7 @@ var SITE_CORE_CHANNEL_TYPE_ENUM = ["site", "embed", "api"];
|
|
|
5063
5082
|
var SITE_CONFIGURABLE_CHANNEL_TYPE_ENUM = ["builtin:slack", "builtin:discord", "builtin:github", "builtin:linear"];
|
|
5064
5083
|
var SITE_QUESTION_VISITOR_TYPE_ENUM = ["human", "agent", "bot", "unknown"];
|
|
5065
5084
|
var SITE_QUESTION_ANSWER_RESOLUTION_ENUM = ["no", "partially", "yes"];
|
|
5085
|
+
var SITE_QUESTION_TIMELINE_INTERVAL_ENUM = ["hour", "day", "week", "month"];
|
|
5066
5086
|
var SITE_QUESTION_ANSWER_HELPFULNESS_ENUM = ["low", "medium", "high"];
|
|
5067
5087
|
var AIMESSAGE_ROLE_ENUM = ["user", "assistant", "developer"];
|
|
5068
5088
|
var AIMESSAGE_STEP_START_CONDITION_ENUM = ["compaction"];
|
|
@@ -5499,6 +5519,7 @@ export {
|
|
|
5499
5519
|
SITE_QUESTION_ANSWER_RELEVANCE_ENUM,
|
|
5500
5520
|
SITE_QUESTION_ANSWER_RESOLUTION_ENUM,
|
|
5501
5521
|
SITE_QUESTION_ANSWER_SOURCE_TYPE_ENUM,
|
|
5522
|
+
SITE_QUESTION_TIMELINE_INTERVAL_ENUM,
|
|
5502
5523
|
SITE_QUESTION_TYPE_ENUM,
|
|
5503
5524
|
SITE_QUESTION_VISITOR_TYPE_ENUM,
|
|
5504
5525
|
SITE_REDIRECT_ORDER_BY_ENUM,
|
|
@@ -5572,6 +5593,7 @@ export {
|
|
|
5572
5593
|
SiteQuestionAnswerRelevance,
|
|
5573
5594
|
SiteQuestionAnswerResolution,
|
|
5574
5595
|
SiteQuestionAnswerSourceType,
|
|
5596
|
+
SiteQuestionTimelineInterval,
|
|
5575
5597
|
SiteQuestionType,
|
|
5576
5598
|
SiteQuestionVisitorType,
|
|
5577
5599
|
SiteRedirectOrderBy,
|
|
@@ -5595,6 +5617,9 @@ export {
|
|
|
5595
5617
|
TranslationLanguage,
|
|
5596
5618
|
TranslationStatus,
|
|
5597
5619
|
URL_MAX_LENGTH,
|
|
5620
|
+
VARIABLE_NAME_MAX_LENGTH,
|
|
5621
|
+
VARIABLE_NAME_MIN_LENGTH,
|
|
5622
|
+
VARIABLE_NAME_PATTERN,
|
|
5598
5623
|
VERTICAL_ALIGNMENT_ENUM,
|
|
5599
5624
|
VerticalAlignment,
|
|
5600
5625
|
YOUTUBE_CHANNEL_ID_PATTERN,
|