@gitbook/api 0.172.0 → 0.173.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 CHANGED
@@ -231,6 +231,17 @@ export declare enum SiteInsightsDisplayContext {
231
231
  Embed = "embed",
232
232
  Mcp = "mcp"
233
233
  }
234
+ /** Controls how issue remediation change requests should be handled for a site. */
235
+ export declare enum SiteSettingsFindingChangeRequests {
236
+ Always = "always",
237
+ AutoFixable = "auto-fixable",
238
+ Never = "never"
239
+ }
240
+ /** Controls when topics are being scanned for findings. */
241
+ export declare enum SiteSettingsScanTopics {
242
+ Auto = "auto",
243
+ Never = "never"
244
+ }
234
245
  export declare enum AIModel {
235
246
  Fast = "fast",
236
247
  ReasoningLow = "reasoning-low",
@@ -668,6 +679,11 @@ export declare enum SiteAdsTopic {
668
679
  Webdev = "webdev",
669
680
  Crypto = "crypto"
670
681
  }
682
+ /** Permissions resolution mode for the site. */
683
+ export declare enum SitePermissionsModel {
684
+ Legacy = "legacy",
685
+ Site = "site"
686
+ }
671
687
  /**
672
688
  * The visibility setting of the site determines the audience of the site.
673
689
  * * `public`: Anyone can access the site, and the site is indexed by search engines.
@@ -1004,7 +1020,7 @@ export declare enum ContentVisibility {
1004
1020
  /** Data passed through a realtime channel */
1005
1021
  export type APIChannelData = APIChannelGitSyncOperationData | APIChannelSpaceContentRefsData | APIChannelChangeRequestContentRefsData | APIChannelTranslationRunData | APIChannelImportRunData | APIChannelMutationData;
1006
1022
  /** Channel to subscribe to for realtime updates. */
1007
- export type APIChannel = APIChannelSpaceInfo | APIChannelSpaceContent | APIChannelSpaceGitInfo | APIChannelSpacePublishingAuth | APIChannelSpacePublishingCustomization | APIChannelSpaceContentRefs | APIChannelSpaceIntegrations | APIChannelUserAPITokens | APIChannelUserOrganizations | APIChannelUserProfile | APIChannelChangeRequest | APIChannelChangeRequests | APIChannelChangeRequestReviews | APIChannelChangeRequestContentRefs | APIChannelCollection | APIChannelCollectionPublishingCustomization | APIChannelOrganizationInfo | APIChannelOrganizationAgentData | APIChannelOrganizationInviteLinks | APIChannelOrganizationMembers | APIChannelOrganizationMember | APIChannelOrganizationSAML | APIChannelOrganizationTeams | APIChannelOrganizationTeam | APIChannelOrganizationTeamMembers | APIChannelOrganizationTeamMember | APIChannelOrganizationSpaces | APIChannelOrganizationCollections | APIChannelOrganizationIntegrations | APIChannelOrganizationInstallations | APIChannelOrganizationSites | APIChannelOrganizationOpenAPISpecs | APIChannelOrganizationTranslations | APIChannelOrganizationTranslationsGlossary | APIChannelOrganizationCustomFonts | APIChannelOrganizationAgentInstructions | APIChannelOrganizationChangeRequests | APIChannelSpaceComments | APIChannelChangeRequestComments | APIChannelCommentInfo | APIChannelCommentReplies | APIChannelIntegration | APIChannelIntegrationInstallation | APIChannelIntegrationSpaceInstallation | APIChannelIntegrationSpaceInstallations | APIChannelIntegrationSiteInstallation | APIChannelIntegrationSiteInstallations | APIChannelPublishedContentSite | APIChannelSiteRedirects | APIChannelSite | APIChannelSiteContext | APIChannelSiteCustomization | APIChannelSiteIntegrations | APIChannelSiteSpace | APIChannelSiteSpaceCustomization | APIChannelSiteStructure | APIChannelSiteAdaptiveSchema | APIChannelSitePublishingAuth | APIChannelSiteShareLinks | APIChannelSiteShareLink | APIChannelSiteMcpServers | APIChannelSiteMcpServer | APIChannelSiteSection | APIChannelCustomHostname | APIChannelGitSyncOperation | APIChannelOpenAPISpec | APIChannelSubdomain | APIChannelTranslation | APIChannelTranslationRun | APIChannelImportRun;
1023
+ export type APIChannel = APIChannelSpaceInfo | APIChannelSpaceContent | APIChannelSpaceGitInfo | APIChannelSpacePublishingAuth | APIChannelSpacePublishingCustomization | APIChannelSpaceContentRefs | APIChannelSpaceIntegrations | APIChannelUserAPITokens | APIChannelUserOrganizations | APIChannelUserProfile | APIChannelChangeRequest | APIChannelChangeRequests | APIChannelChangeRequestReviews | APIChannelChangeRequestContentRefs | APIChannelCollection | APIChannelCollectionPublishingCustomization | APIChannelOrganizationInfo | APIChannelOrganizationAgentData | APIChannelOrganizationInviteLinks | APIChannelOrganizationMembers | APIChannelOrganizationMember | APIChannelOrganizationSAML | APIChannelOrganizationTeams | APIChannelOrganizationTeam | APIChannelOrganizationTeamMembers | APIChannelOrganizationTeamMember | APIChannelOrganizationSpaces | APIChannelOrganizationCollections | APIChannelOrganizationIntegrations | APIChannelOrganizationInstallations | APIChannelOrganizationSites | APIChannelOrganizationOpenAPISpecs | APIChannelOrganizationTranslations | APIChannelOrganizationTranslationsGlossary | APIChannelOrganizationCustomFonts | APIChannelOrganizationAgentInstructions | APIChannelOrganizationChangeRequests | APIChannelSpaceComments | APIChannelChangeRequestComments | APIChannelCommentInfo | APIChannelCommentReplies | APIChannelIntegration | APIChannelIntegrationInstallation | APIChannelIntegrationSpaceInstallation | APIChannelIntegrationSpaceInstallations | APIChannelIntegrationSiteInstallation | APIChannelIntegrationSiteInstallations | APIChannelPublishedContentSite | APIChannelSiteRedirects | APIChannelSite | APIChannelSiteContext | APIChannelSiteCustomization | APIChannelSiteAgentSettings | APIChannelSiteIntegrations | APIChannelSiteSpace | APIChannelSiteSpaceCustomization | APIChannelSiteStructure | APIChannelSiteAdaptiveSchema | APIChannelSitePublishingAuth | APIChannelSiteShareLinks | APIChannelSiteShareLink | APIChannelSiteMcpServers | APIChannelSiteMcpServer | APIChannelSiteSection | APIChannelCustomHostname | APIChannelGitSyncOperation | APIChannelOpenAPISpec | APIChannelSubdomain | APIChannelTranslation | APIChannelTranslationRun | APIChannelImportRun;
1008
1024
  export type PublishedContentRedirect = {
1009
1025
  /** Type of target for the redirect */
1010
1026
  target: "application" | "content";
@@ -1794,6 +1810,8 @@ export interface DocumentTableViewGrid {
1794
1810
  columnWidths?: Record<string, number>;
1795
1811
  /** Should we display the header with column titles */
1796
1812
  hideHeader: boolean;
1813
+ /** Should we keep the table header sticky while the page scrolls */
1814
+ stickyHeader?: boolean;
1797
1815
  /**
1798
1816
  * Tables in GitBook originally used a scaled width approach i.e. the width defined
1799
1817
  * in columnWidths would be scaled to ensure a 100% width table.
@@ -4324,6 +4342,10 @@ export interface Site {
4324
4342
  * * `visitor-auth`: Anyone authenticated through a JWT token can access the site.
4325
4343
  */
4326
4344
  visibility: SiteVisibility;
4345
+ /** Permissions resolution mode for the site. */
4346
+ permissionsModel: SitePermissionsModel;
4347
+ /** Default level for a piece of content */
4348
+ defaultLevel: DefaultLevel;
4327
4349
  /** Whether the site is live or not. If true, the site is accessible to the audience defined by the visibility setting. */
4328
4350
  published: boolean;
4329
4351
  siteSpaces: number;
@@ -4771,6 +4793,8 @@ export interface SiteSpace {
4771
4793
  default?: boolean;
4772
4794
  /** Conditional expression used to evaluate whether the site space should be shown to the site's visitor. */
4773
4795
  condition?: Expression;
4796
+ /** Whether the site space is draft and not live. */
4797
+ draft: boolean;
4774
4798
  /** Whether the space has advanced customization feature enabled */
4775
4799
  hasAdvancedCustomizationFeature?: boolean;
4776
4800
  /** URLs associated with the object */
@@ -4799,6 +4823,8 @@ export interface SiteSection {
4799
4823
  localizedDescription?: LocalizedSectionDescription;
4800
4824
  /** Whether this is the default section for the site */
4801
4825
  default?: boolean;
4826
+ /** Whether the site section is draft and not live. */
4827
+ draft: boolean;
4802
4828
  /** Path to the section on the site */
4803
4829
  path: SiteSectionPath;
4804
4830
  /** Conditional expression used to evaluate whether the site section should be shown to the site's visitor. */
@@ -4839,6 +4865,8 @@ export interface SiteSectionGroup {
4839
4865
  sections: SiteSection[];
4840
4866
  /** ID of the parent section group this group belongs to */
4841
4867
  sectionGroup?: string;
4868
+ /** Whether the site section group is draft and not live. */
4869
+ draft: boolean;
4842
4870
  /** List of all child sections and groups nested under this group */
4843
4871
  children: (SiteSection | SiteSectionGroup)[];
4844
4872
  /** Name of the icon */
@@ -6384,6 +6412,13 @@ export interface SiteTopic {
6384
6412
  pages: number;
6385
6413
  /** The number of records in the topic */
6386
6414
  records: number;
6415
+ /** The number of findings linked to the topic */
6416
+ findings: {
6417
+ /** The number of open findings linked to the topic */
6418
+ open: number;
6419
+ /** The total number of findings linked to the topic */
6420
+ total: number;
6421
+ };
6387
6422
  /** Aggregated stats for questions and linked answers. */
6388
6423
  questions: SiteQuestionStats;
6389
6424
  /** URLs associated with the topic */
@@ -6426,6 +6461,8 @@ export type SiteQuestionAnswerSourceRecord = SiteQuestionAnswerSourceBase & {
6426
6461
  type: "record";
6427
6462
  /** The site context record ID. */
6428
6463
  record: string;
6464
+ /** Integration source */
6465
+ connector?: ContextConnector;
6429
6466
  };
6430
6467
  /** Identifiers for a GitBook site session, used for analytics and adaptive content. */
6431
6468
  export interface SiteInsightsSession {
@@ -6500,6 +6537,21 @@ export interface AIToolCallGetPageContent {
6500
6537
  revisionId: string;
6501
6538
  page: ChangedRevisionPage;
6502
6539
  }
6540
+ /** Tool to read the body of an external record. */
6541
+ export interface AIToolCallGetRecordContent {
6542
+ tool: "getRecordContent";
6543
+ /** The ID of the site owning the context record. */
6544
+ siteId: string;
6545
+ /** The ID of the context record. */
6546
+ recordId: string;
6547
+ /** The title of the record. */
6548
+ title: string;
6549
+ /**
6550
+ * URL of the record in the source system.
6551
+ * @format uri
6552
+ */
6553
+ url?: string;
6554
+ }
6503
6555
  export interface AIToolCallGetPages {
6504
6556
  tool: "getPages";
6505
6557
  /** The ID of the space being accessed. */
@@ -6701,7 +6753,7 @@ export interface AIToolCallOther {
6701
6753
  /** Summary of a generic tool call. */
6702
6754
  summary: AIToolCallOtherSummary;
6703
6755
  }
6704
- export type AIToolCall = AIToolCallGetPageContent | AIToolCallGetPages | AIToolCallGetReusableContents | AIToolCallSearch | AIToolCallEditPage | AIToolCallCreatePage | AIToolCallDeletePage | AIToolCallRenamePage | AIToolCallMovePage | AIToolCallListModifiedPages | AIToolCallGetPageDiff | AIToolCallCreateReusableContent | AIToolCallEditReusableContent | AIToolCallGetReusableContent | AIToolCallCreateChangeRequest | AIToolCallComment | AIToolCallReplyToComment | AIToolCallSubmitChangeRequestReview | AIToolCallMCP | AIToolCallOther;
6756
+ export type AIToolCall = AIToolCallGetPageContent | AIToolCallGetRecordContent | AIToolCallGetPages | AIToolCallGetReusableContents | AIToolCallSearch | AIToolCallEditPage | AIToolCallCreatePage | AIToolCallDeletePage | AIToolCallRenamePage | AIToolCallMovePage | AIToolCallListModifiedPages | AIToolCallGetPageDiff | AIToolCallCreateReusableContent | AIToolCallEditReusableContent | AIToolCallGetReusableContent | AIToolCallCreateChangeRequest | AIToolCallComment | AIToolCallReplyToComment | AIToolCallSubmitChangeRequestReview | AIToolCallMCP | AIToolCallOther;
6705
6757
  export interface Timerange {
6706
6758
  start: Timestamp;
6707
6759
  end: Timestamp;
@@ -6814,7 +6866,7 @@ export type InviteSiteUsersAndTeams = ({
6814
6866
  users: string[];
6815
6867
  }) & {
6816
6868
  /** Role to set. */
6817
- role: MemberRole;
6869
+ role: MemberRoleOrGuest;
6818
6870
  };
6819
6871
  export interface OrganizationPointer {
6820
6872
  type: "organization";
@@ -6831,30 +6883,14 @@ export interface UserSitePermission {
6831
6883
  }
6832
6884
  /** Permission override of a user in a site. */
6833
6885
  export interface UserSitePermissionOverride {
6834
- /**
6835
- * "The role of a member in an organization.
6836
- * "admin": Can administrate the content: create, delete spaces, ...
6837
- * "create": Can create content.
6838
- * "review": Can review content.
6839
- * "edit": Can edit the content (live or change requests).
6840
- * "comment": Can access the content and its discussions.
6841
- * "read": Can access the content, but cannot update it in any way.
6842
- */
6843
- permission: MemberRole;
6886
+ /** The role of a member in an organization, null for guests */
6887
+ permission: MemberRoleOrGuest;
6844
6888
  user: User;
6845
6889
  }
6846
6890
  /** Permission override of a team in a site. */
6847
6891
  export interface TeamSitePermissionOverride {
6848
- /**
6849
- * "The role of a member in an organization.
6850
- * "admin": Can administrate the content: create, delete spaces, ...
6851
- * "create": Can create content.
6852
- * "review": Can review content.
6853
- * "edit": Can edit the content (live or change requests).
6854
- * "comment": Can access the content and its discussions.
6855
- * "read": Can access the content, but cannot update it in any way.
6856
- */
6857
- permission: MemberRole;
6892
+ /** The role of a member in an organization, null for guests */
6893
+ permission: MemberRoleOrGuest;
6858
6894
  team: OrganizationTeam;
6859
6895
  }
6860
6896
  /** Context about the current user sending a message. */
@@ -6984,6 +7020,32 @@ export interface AIStreamResponseAttachment {
6984
7020
  attachment: AIAttachment;
6985
7021
  }
6986
7022
  export type AIStreamResponse = AIStreamResponseStart | AIStreamResponseFinish | AIStreamResponseDocument | AIStreamResponseObject | AIStreamResponseToolCall | AIStreamResponseToolCallPending | AIStreamResponseFollowupSuggestion | AIStreamResponseAttachment;
7023
+ export interface SiteAgentSettingsInput {
7024
+ /** Settings related to scanning for a site. */
7025
+ scans: {
7026
+ /** Controls when topics are being scanned for findings. */
7027
+ topics: SiteSettingsScanTopics;
7028
+ };
7029
+ /** Settings related to processing of findings for a site. */
7030
+ findings: {
7031
+ /** Controls how issue remediation change requests should be handled for a site. */
7032
+ changeRequests: SiteSettingsFindingChangeRequests;
7033
+ };
7034
+ /** Site-specific instructions for the editing agent. */
7035
+ editing: {
7036
+ customInstructions: JSONDocument;
7037
+ };
7038
+ }
7039
+ export type SiteAgentSettings = {
7040
+ object: "site-agent-settings";
7041
+ updatedAt?: Timestamp;
7042
+ /** Identifier of the member who last updated the settings. */
7043
+ updatedBy?: string;
7044
+ urls: {
7045
+ /** Relative URL to the resource in the API. */
7046
+ location: string;
7047
+ };
7048
+ } & SiteAgentSettingsInput;
6987
7049
  /** Analytics info on the GitBook's site session. */
6988
7050
  export type SiteInsightsEventSession = SiteInsightsSession & {
6989
7051
  /** The visitors cookies. */
@@ -8286,6 +8348,10 @@ export interface APIChannelSiteCustomization {
8286
8348
  channel: "site-customization";
8287
8349
  site: string;
8288
8350
  }
8351
+ export interface APIChannelSiteAgentSettings {
8352
+ channel: "site-agent-settings";
8353
+ site: string;
8354
+ }
8289
8355
  export interface APIChannelSiteIntegrations {
8290
8356
  channel: "site-integrations";
8291
8357
  site: string;
@@ -12946,6 +13012,10 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
12946
13012
  /** Basename for the site. For e.g. api */
12947
13013
  basename?: SiteBasename;
12948
13014
  adaptiveContent?: SiteAdaptiveContent;
13015
+ /** Permissions resolution mode for the site. */
13016
+ permissionsModel?: SitePermissionsModel;
13017
+ /** Default level for a piece of content */
13018
+ defaultLevel?: DefaultLevel;
12949
13019
  /** ID of the site-space to be used as the default at the root level. If site has sections, this will mark the default site space in the site's default section. */
12950
13020
  defaultSiteSpace?: string;
12951
13021
  /** ID of the site-section to be used as the default. */
@@ -13324,6 +13394,11 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
13324
13394
  spaceId: string;
13325
13395
  /** ID of the section to add the space to. If not provided, the space will be added to the default section or at the root level if the site has no sections. */
13326
13396
  sectionId?: string;
13397
+ /**
13398
+ * Whether the site space should be created as draft. Defaults to false.
13399
+ * @default false
13400
+ */
13401
+ draft?: boolean;
13327
13402
  }, params?: RequestParams) => Promise<HttpResponse<SiteSpace, any>>;
13328
13403
  /**
13329
13404
  * No description
@@ -13388,6 +13463,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
13388
13463
  sections?: string[];
13389
13464
  /** ID of the parent section group to nest this group under. If not provided, the section group will be added at the root of the site. */
13390
13465
  parent?: string;
13466
+ /** Whether the section group should be created in draft mode. */
13467
+ draft?: boolean;
13391
13468
  }, params?: RequestParams) => Promise<HttpResponse<SiteSectionGroup, any>>;
13392
13469
  /**
13393
13470
  * No description
@@ -13404,6 +13481,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
13404
13481
  /** Localized title value, keyed by locale. Contains overrides for non-default languages only. */
13405
13482
  localizedTitle?: LocalizedTitle;
13406
13483
  icon?: Icon | null;
13484
+ /** Whether the site section group is draft and not live. */
13485
+ draft?: boolean;
13407
13486
  }, params?: RequestParams) => Promise<HttpResponse<SiteSectionGroup, any>>;
13408
13487
  /**
13409
13488
  * No description
@@ -13454,6 +13533,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
13454
13533
  spaceId: string;
13455
13534
  title?: SiteSectionTitle | null;
13456
13535
  icon?: Icon | null;
13536
+ /** Whether the section should be created in draft mode. */
13537
+ draft?: boolean;
13457
13538
  /** ID of the section group to create the section in */
13458
13539
  siteSectionGroupId?: string;
13459
13540
  }, params?: RequestParams) => Promise<HttpResponse<SiteSection, any>>;
@@ -13501,6 +13582,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
13501
13582
  /** Conditional expression used to evaluate whether the site section should be shown to the site's visitor (should evaluate to a boolean). If not set, the condition will remain unchanged. If set to null, the condition will be removed. */
13502
13583
  condition?: Expression | null;
13503
13584
  icon?: Icon | null;
13585
+ /** Whether the site section is draft and not live. */
13586
+ draft?: boolean;
13504
13587
  description?: SiteSectionDescription | null;
13505
13588
  /** Localized section description value, keyed by locale. Contains overrides for non-default languages only. */
13506
13589
  localizedDescription?: LocalizedSectionDescription;
@@ -14155,6 +14238,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
14155
14238
  spaceId?: string;
14156
14239
  /** Whether the site space is hidden. If true, the site space will not be shown in the site's navigation. If not set, the hidden state will remain unchanged. If set to false, the site space will be shown in site navigation. */
14157
14240
  hidden?: boolean;
14241
+ /** Whether the site space should be kept in draft mode. Setting it to false makes the site space live. */
14242
+ draft?: boolean;
14158
14243
  }, params?: RequestParams) => Promise<HttpResponse<SiteSpace, any>>;
14159
14244
  /**
14160
14245
  * No description
@@ -14604,6 +14689,38 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
14604
14689
  type: SiteCoreChannelType;
14605
14690
  };
14606
14691
  }, params?: RequestParams) => EventIterator<AIStreamResponse>;
14692
+ /**
14693
+ * No description
14694
+ *
14695
+ * @tags site-agent-settings
14696
+ * @name GetSiteAgentSettingsById
14697
+ * @summary Get site agent settings
14698
+ * @request GET:/orgs/{organizationId}/sites/{siteId}/agent-settings
14699
+ * @secure
14700
+ */
14701
+ getSiteAgentSettingsById: (organizationId: EntityId, siteId: string, params?: RequestParams) => Promise<HttpResponse<SiteAgentSettings, {
14702
+ error: {
14703
+ /** @format int32 */
14704
+ code: 400;
14705
+ message: string;
14706
+ };
14707
+ }>>;
14708
+ /**
14709
+ * No description
14710
+ *
14711
+ * @tags site-agent-settings
14712
+ * @name UpdateSiteAgentSettingsById
14713
+ * @summary Update site agent settings
14714
+ * @request PUT:/orgs/{organizationId}/sites/{siteId}/agent-settings
14715
+ * @secure
14716
+ */
14717
+ updateSiteAgentSettingsById: (organizationId: EntityId, siteId: string, data: SiteAgentSettingsInput, params?: RequestParams) => Promise<HttpResponse<SiteAgentSettings, {
14718
+ error: {
14719
+ /** @format int32 */
14720
+ code: 400;
14721
+ message: string;
14722
+ };
14723
+ }>>;
14607
14724
  /**
14608
14725
  * No description
14609
14726
  *
@@ -77,6 +77,7 @@ export declare const SITE_BASENAME_MIN_LENGTH = 1;
77
77
  export declare const SITE_PROXY_ORIGIN_MAX_LENGTH = 512;
78
78
  export declare const SITE_PROXY_ORIGIN_PATTERN = "^([\\w-]+\\.)*[\\w-]+\\.[a-zA-Z]{2,}(\\/[\\w-]+)+$";
79
79
  export declare const SITE_VISIBILITY_ENUM: ["public", "unlisted", "share-link", "visitor-auth"];
80
+ export declare const SITE_PERMISSIONS_MODEL_ENUM: ["legacy", "site"];
80
81
  export declare const SITE_ADS_TOPIC_ENUM: ["webdev", "crypto"];
81
82
  export declare const SITE_FEATURE_KEY_ENUM: ["sites-adaptive-content", "sites-advanced-customization", "sites-advanced-insights", "sites-ads", "sites-ai-search", "sites-ai-assistant", "sites-embed", "sites-api-playground", "sites-basic-customization", "sites-custom-domain", "sites-custom-fonts", "sites-custom-subdirectory", "sites-full-text-search", "sites-multivariant-site", "sites-no-custom-domain", "sites-page-feedback", "sites-page-traffic-insights", "sites-pdf-export", "sites-preview-deployments", "sites-public-visibility", "sites-redirects", "sites-search-insights", "sites-sections", "sites-seo", "sites-share-links", "sites-unlisted-visibility", "sites-user-contribution", "sites-visitor-authentication", "sites-visitors"];
82
83
  export declare const SITE_CUSTOMIZATION_FEATURE_ENUM: ["header-logo", "header-primary-link", "theme-preset", "premium-fonts", "custom-icons", "footer-logo", "footer-links", "footer-copyright", "semantic-colors"];
@@ -156,6 +157,8 @@ export declare const SITE_CORE_CHANNEL_TYPE_ENUM: ["site", "embed", "api"];
156
157
  export declare const SITE_CONFIGURABLE_CHANNEL_TYPE_ENUM: ["builtin:slack", "builtin:discord"];
157
158
  export declare const AIMESSAGE_ROLE_ENUM: ["user", "assistant", "developer"];
158
159
  export declare const AIMODEL_ENUM: ["fast", "reasoning-low", "reasoning-medium", "reasoning-high"];
160
+ export declare const SITE_SETTINGS_SCAN_TOPICS_ENUM: ["auto", "never"];
161
+ export declare const SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM: ["always", "auto-fixable", "never"];
159
162
  export declare const SITE_INSIGHTS_DISPLAY_CONTEXT_ENUM: ["site", "server", "embed", "mcp"];
160
163
  export declare const SITE_INSIGHTS_LINK_POSITION_ENUM: ["announcement", "header", "footer", "sidebar", "content"];
161
164
  export declare const SITE_INSIGHTS_TRADEMARK_PLACEMENT_ENUM: ["sidebar", "ad", "footer", "pdf", "embed"];
package/dist/index.cjs CHANGED
@@ -409,6 +409,7 @@ __export(src_exports, {
409
409
  SITE_INSIGHTS_VISITOR_OS_ENUM: () => SITE_INSIGHTS_VISITOR_OS_ENUM,
410
410
  SITE_MCP_SERVER_NAME_MAX_LENGTH: () => SITE_MCP_SERVER_NAME_MAX_LENGTH,
411
411
  SITE_MCP_SERVER_NAME_MIN_LENGTH: () => SITE_MCP_SERVER_NAME_MIN_LENGTH,
412
+ SITE_PERMISSIONS_MODEL_ENUM: () => SITE_PERMISSIONS_MODEL_ENUM,
412
413
  SITE_PROXY_ORIGIN_MAX_LENGTH: () => SITE_PROXY_ORIGIN_MAX_LENGTH,
413
414
  SITE_PROXY_ORIGIN_PATTERN: () => SITE_PROXY_ORIGIN_PATTERN,
414
415
  SITE_QUESTION_ANSWER_HELPFULNESS_ENUM: () => SITE_QUESTION_ANSWER_HELPFULNESS_ENUM,
@@ -427,6 +428,8 @@ __export(src_exports, {
427
428
  SITE_SECTION_PATH_MIN_LENGTH: () => SITE_SECTION_PATH_MIN_LENGTH,
428
429
  SITE_SECTION_TITLE_MAX_LENGTH: () => SITE_SECTION_TITLE_MAX_LENGTH,
429
430
  SITE_SECTION_TITLE_MIN_LENGTH: () => SITE_SECTION_TITLE_MIN_LENGTH,
431
+ SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM: () => SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM,
432
+ SITE_SETTINGS_SCAN_TOPICS_ENUM: () => SITE_SETTINGS_SCAN_TOPICS_ENUM,
430
433
  SITE_SOCIAL_ACCOUNT_HANDLE_MAX_LENGTH: () => SITE_SOCIAL_ACCOUNT_HANDLE_MAX_LENGTH,
431
434
  SITE_SOCIAL_ACCOUNT_HANDLE_MIN_LENGTH: () => SITE_SOCIAL_ACCOUNT_HANDLE_MIN_LENGTH,
432
435
  SITE_SOCIAL_ACCOUNT_PLATFORM_ENUM: () => SITE_SOCIAL_ACCOUNT_PLATFORM_ENUM,
@@ -463,12 +466,15 @@ __export(src_exports, {
463
466
  SiteInsightsVisitorBrowser: () => SiteInsightsVisitorBrowser,
464
467
  SiteInsightsVisitorDevice: () => SiteInsightsVisitorDevice,
465
468
  SiteInsightsVisitorOS: () => SiteInsightsVisitorOS,
469
+ SitePermissionsModel: () => SitePermissionsModel,
466
470
  SiteQuestionAnswerHelpfulness: () => SiteQuestionAnswerHelpfulness,
467
471
  SiteQuestionAnswerRelevance: () => SiteQuestionAnswerRelevance,
468
472
  SiteQuestionAnswerResolution: () => SiteQuestionAnswerResolution,
469
473
  SiteQuestionAnswerSourceType: () => SiteQuestionAnswerSourceType,
470
474
  SiteQuestionType: () => SiteQuestionType,
471
475
  SiteScanStatus: () => SiteScanStatus,
476
+ SiteSettingsFindingChangeRequests: () => SiteSettingsFindingChangeRequests,
477
+ SiteSettingsScanTopics: () => SiteSettingsScanTopics,
472
478
  SiteSocialAccountPlatform: () => SiteSocialAccountPlatform,
473
479
  SiteType: () => SiteType,
474
480
  SiteVisibility: () => SiteVisibility,
@@ -490,7 +496,7 @@ module.exports = __toCommonJS(src_exports);
490
496
 
491
497
  // package.json
492
498
  var name = "@gitbook/api";
493
- var version = "0.172.0";
499
+ var version = "0.173.0";
494
500
 
495
501
  // src/client.ts
496
502
  var import_event_iterator = __toESM(require_node(), 1);
@@ -836,6 +842,17 @@ var SiteInsightsDisplayContext = /* @__PURE__ */ ((SiteInsightsDisplayContext2)
836
842
  SiteInsightsDisplayContext2["Mcp"] = "mcp";
837
843
  return SiteInsightsDisplayContext2;
838
844
  })(SiteInsightsDisplayContext || {});
845
+ var SiteSettingsFindingChangeRequests = /* @__PURE__ */ ((SiteSettingsFindingChangeRequests2) => {
846
+ SiteSettingsFindingChangeRequests2["Always"] = "always";
847
+ SiteSettingsFindingChangeRequests2["AutoFixable"] = "auto-fixable";
848
+ SiteSettingsFindingChangeRequests2["Never"] = "never";
849
+ return SiteSettingsFindingChangeRequests2;
850
+ })(SiteSettingsFindingChangeRequests || {});
851
+ var SiteSettingsScanTopics = /* @__PURE__ */ ((SiteSettingsScanTopics2) => {
852
+ SiteSettingsScanTopics2["Auto"] = "auto";
853
+ SiteSettingsScanTopics2["Never"] = "never";
854
+ return SiteSettingsScanTopics2;
855
+ })(SiteSettingsScanTopics || {});
839
856
  var AIModel = /* @__PURE__ */ ((AIModel2) => {
840
857
  AIModel2["Fast"] = "fast";
841
858
  AIModel2["ReasoningLow"] = "reasoning-low";
@@ -1238,6 +1255,11 @@ var SiteAdsTopic = /* @__PURE__ */ ((SiteAdsTopic2) => {
1238
1255
  SiteAdsTopic2["Crypto"] = "crypto";
1239
1256
  return SiteAdsTopic2;
1240
1257
  })(SiteAdsTopic || {});
1258
+ var SitePermissionsModel = /* @__PURE__ */ ((SitePermissionsModel2) => {
1259
+ SitePermissionsModel2["Legacy"] = "legacy";
1260
+ SitePermissionsModel2["Site"] = "site";
1261
+ return SitePermissionsModel2;
1262
+ })(SitePermissionsModel || {});
1241
1263
  var SiteVisibility = /* @__PURE__ */ ((SiteVisibility2) => {
1242
1264
  SiteVisibility2["Public"] = "public";
1243
1265
  SiteVisibility2["Unlisted"] = "unlisted";
@@ -4209,6 +4231,22 @@ var Api = class extends HttpClient {
4209
4231
  type: "application/json" /* Json */,
4210
4232
  ...params
4211
4233
  }),
4234
+ getSiteAgentSettingsById: (organizationId, siteId, params = {}) => this.request({
4235
+ path: `/orgs/${organizationId}/sites/${siteId}/agent-settings`,
4236
+ method: "GET",
4237
+ secure: true,
4238
+ format: "json",
4239
+ ...params
4240
+ }),
4241
+ updateSiteAgentSettingsById: (organizationId, siteId, data, params = {}) => this.request({
4242
+ path: `/orgs/${organizationId}/sites/${siteId}/agent-settings`,
4243
+ method: "PUT",
4244
+ body: data,
4245
+ secure: true,
4246
+ type: "application/json" /* Json */,
4247
+ format: "json",
4248
+ ...params
4249
+ }),
4212
4250
  trackEventsInSiteById: (organizationId, siteId, data, params = {}) => this.request({
4213
4251
  path: `/orgs/${organizationId}/sites/${siteId}/insights/events`,
4214
4252
  method: "POST",
@@ -4567,6 +4605,7 @@ var SITE_BASENAME_MIN_LENGTH = 1;
4567
4605
  var SITE_PROXY_ORIGIN_MAX_LENGTH = 512;
4568
4606
  var SITE_PROXY_ORIGIN_PATTERN = "^([\\w-]+\\.)*[\\w-]+\\.[a-zA-Z]{2,}(\\/[\\w-]+)+$";
4569
4607
  var SITE_VISIBILITY_ENUM = ["public", "unlisted", "share-link", "visitor-auth"];
4608
+ var SITE_PERMISSIONS_MODEL_ENUM = ["legacy", "site"];
4570
4609
  var SITE_ADS_TOPIC_ENUM = ["webdev", "crypto"];
4571
4610
  var SITE_FEATURE_KEY_ENUM = ["sites-adaptive-content", "sites-advanced-customization", "sites-advanced-insights", "sites-ads", "sites-ai-search", "sites-ai-assistant", "sites-embed", "sites-api-playground", "sites-basic-customization", "sites-custom-domain", "sites-custom-fonts", "sites-custom-subdirectory", "sites-full-text-search", "sites-multivariant-site", "sites-no-custom-domain", "sites-page-feedback", "sites-page-traffic-insights", "sites-pdf-export", "sites-preview-deployments", "sites-public-visibility", "sites-redirects", "sites-search-insights", "sites-sections", "sites-seo", "sites-share-links", "sites-unlisted-visibility", "sites-user-contribution", "sites-visitor-authentication", "sites-visitors"];
4572
4611
  var SITE_CUSTOMIZATION_FEATURE_ENUM = ["header-logo", "header-primary-link", "theme-preset", "premium-fonts", "custom-icons", "footer-logo", "footer-links", "footer-copyright", "semantic-colors"];
@@ -4646,6 +4685,8 @@ var SITE_CORE_CHANNEL_TYPE_ENUM = ["site", "embed", "api"];
4646
4685
  var SITE_CONFIGURABLE_CHANNEL_TYPE_ENUM = ["builtin:slack", "builtin:discord"];
4647
4686
  var AIMESSAGE_ROLE_ENUM = ["user", "assistant", "developer"];
4648
4687
  var AIMODEL_ENUM = ["fast", "reasoning-low", "reasoning-medium", "reasoning-high"];
4688
+ var SITE_SETTINGS_SCAN_TOPICS_ENUM = ["auto", "never"];
4689
+ var SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM = ["always", "auto-fixable", "never"];
4649
4690
  var SITE_INSIGHTS_DISPLAY_CONTEXT_ENUM = ["site", "server", "embed", "mcp"];
4650
4691
  var SITE_INSIGHTS_LINK_POSITION_ENUM = ["announcement", "header", "footer", "sidebar", "content"];
4651
4692
  var SITE_INSIGHTS_TRADEMARK_PLACEMENT_ENUM = ["sidebar", "ad", "footer", "pdf", "embed"];
@@ -4979,6 +5020,7 @@ var GitBookAPI = class extends Api {
4979
5020
  SITE_INSIGHTS_VISITOR_OS_ENUM,
4980
5021
  SITE_MCP_SERVER_NAME_MAX_LENGTH,
4981
5022
  SITE_MCP_SERVER_NAME_MIN_LENGTH,
5023
+ SITE_PERMISSIONS_MODEL_ENUM,
4982
5024
  SITE_PROXY_ORIGIN_MAX_LENGTH,
4983
5025
  SITE_PROXY_ORIGIN_PATTERN,
4984
5026
  SITE_QUESTION_ANSWER_HELPFULNESS_ENUM,
@@ -4997,6 +5039,8 @@ var GitBookAPI = class extends Api {
4997
5039
  SITE_SECTION_PATH_MIN_LENGTH,
4998
5040
  SITE_SECTION_TITLE_MAX_LENGTH,
4999
5041
  SITE_SECTION_TITLE_MIN_LENGTH,
5042
+ SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM,
5043
+ SITE_SETTINGS_SCAN_TOPICS_ENUM,
5000
5044
  SITE_SOCIAL_ACCOUNT_HANDLE_MAX_LENGTH,
5001
5045
  SITE_SOCIAL_ACCOUNT_HANDLE_MIN_LENGTH,
5002
5046
  SITE_SOCIAL_ACCOUNT_PLATFORM_ENUM,
@@ -5033,12 +5077,15 @@ var GitBookAPI = class extends Api {
5033
5077
  SiteInsightsVisitorBrowser,
5034
5078
  SiteInsightsVisitorDevice,
5035
5079
  SiteInsightsVisitorOS,
5080
+ SitePermissionsModel,
5036
5081
  SiteQuestionAnswerHelpfulness,
5037
5082
  SiteQuestionAnswerRelevance,
5038
5083
  SiteQuestionAnswerResolution,
5039
5084
  SiteQuestionAnswerSourceType,
5040
5085
  SiteQuestionType,
5041
5086
  SiteScanStatus,
5087
+ SiteSettingsFindingChangeRequests,
5088
+ SiteSettingsScanTopics,
5042
5089
  SiteSocialAccountPlatform,
5043
5090
  SiteType,
5044
5091
  SiteVisibility,
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.172.0";
175
+ var version = "0.173.0";
176
176
 
177
177
  // src/client.ts
178
178
  var import_event_iterator = __toESM(require_node(), 1);
@@ -518,6 +518,17 @@ var SiteInsightsDisplayContext = /* @__PURE__ */ ((SiteInsightsDisplayContext2)
518
518
  SiteInsightsDisplayContext2["Mcp"] = "mcp";
519
519
  return SiteInsightsDisplayContext2;
520
520
  })(SiteInsightsDisplayContext || {});
521
+ var SiteSettingsFindingChangeRequests = /* @__PURE__ */ ((SiteSettingsFindingChangeRequests2) => {
522
+ SiteSettingsFindingChangeRequests2["Always"] = "always";
523
+ SiteSettingsFindingChangeRequests2["AutoFixable"] = "auto-fixable";
524
+ SiteSettingsFindingChangeRequests2["Never"] = "never";
525
+ return SiteSettingsFindingChangeRequests2;
526
+ })(SiteSettingsFindingChangeRequests || {});
527
+ var SiteSettingsScanTopics = /* @__PURE__ */ ((SiteSettingsScanTopics2) => {
528
+ SiteSettingsScanTopics2["Auto"] = "auto";
529
+ SiteSettingsScanTopics2["Never"] = "never";
530
+ return SiteSettingsScanTopics2;
531
+ })(SiteSettingsScanTopics || {});
521
532
  var AIModel = /* @__PURE__ */ ((AIModel2) => {
522
533
  AIModel2["Fast"] = "fast";
523
534
  AIModel2["ReasoningLow"] = "reasoning-low";
@@ -920,6 +931,11 @@ var SiteAdsTopic = /* @__PURE__ */ ((SiteAdsTopic2) => {
920
931
  SiteAdsTopic2["Crypto"] = "crypto";
921
932
  return SiteAdsTopic2;
922
933
  })(SiteAdsTopic || {});
934
+ var SitePermissionsModel = /* @__PURE__ */ ((SitePermissionsModel2) => {
935
+ SitePermissionsModel2["Legacy"] = "legacy";
936
+ SitePermissionsModel2["Site"] = "site";
937
+ return SitePermissionsModel2;
938
+ })(SitePermissionsModel || {});
923
939
  var SiteVisibility = /* @__PURE__ */ ((SiteVisibility2) => {
924
940
  SiteVisibility2["Public"] = "public";
925
941
  SiteVisibility2["Unlisted"] = "unlisted";
@@ -3891,6 +3907,22 @@ var Api = class extends HttpClient {
3891
3907
  type: "application/json" /* Json */,
3892
3908
  ...params
3893
3909
  }),
3910
+ getSiteAgentSettingsById: (organizationId, siteId, params = {}) => this.request({
3911
+ path: `/orgs/${organizationId}/sites/${siteId}/agent-settings`,
3912
+ method: "GET",
3913
+ secure: true,
3914
+ format: "json",
3915
+ ...params
3916
+ }),
3917
+ updateSiteAgentSettingsById: (organizationId, siteId, data, params = {}) => this.request({
3918
+ path: `/orgs/${organizationId}/sites/${siteId}/agent-settings`,
3919
+ method: "PUT",
3920
+ body: data,
3921
+ secure: true,
3922
+ type: "application/json" /* Json */,
3923
+ format: "json",
3924
+ ...params
3925
+ }),
3894
3926
  trackEventsInSiteById: (organizationId, siteId, data, params = {}) => this.request({
3895
3927
  path: `/orgs/${organizationId}/sites/${siteId}/insights/events`,
3896
3928
  method: "POST",
@@ -4249,6 +4281,7 @@ var SITE_BASENAME_MIN_LENGTH = 1;
4249
4281
  var SITE_PROXY_ORIGIN_MAX_LENGTH = 512;
4250
4282
  var SITE_PROXY_ORIGIN_PATTERN = "^([\\w-]+\\.)*[\\w-]+\\.[a-zA-Z]{2,}(\\/[\\w-]+)+$";
4251
4283
  var SITE_VISIBILITY_ENUM = ["public", "unlisted", "share-link", "visitor-auth"];
4284
+ var SITE_PERMISSIONS_MODEL_ENUM = ["legacy", "site"];
4252
4285
  var SITE_ADS_TOPIC_ENUM = ["webdev", "crypto"];
4253
4286
  var SITE_FEATURE_KEY_ENUM = ["sites-adaptive-content", "sites-advanced-customization", "sites-advanced-insights", "sites-ads", "sites-ai-search", "sites-ai-assistant", "sites-embed", "sites-api-playground", "sites-basic-customization", "sites-custom-domain", "sites-custom-fonts", "sites-custom-subdirectory", "sites-full-text-search", "sites-multivariant-site", "sites-no-custom-domain", "sites-page-feedback", "sites-page-traffic-insights", "sites-pdf-export", "sites-preview-deployments", "sites-public-visibility", "sites-redirects", "sites-search-insights", "sites-sections", "sites-seo", "sites-share-links", "sites-unlisted-visibility", "sites-user-contribution", "sites-visitor-authentication", "sites-visitors"];
4254
4287
  var SITE_CUSTOMIZATION_FEATURE_ENUM = ["header-logo", "header-primary-link", "theme-preset", "premium-fonts", "custom-icons", "footer-logo", "footer-links", "footer-copyright", "semantic-colors"];
@@ -4328,6 +4361,8 @@ var SITE_CORE_CHANNEL_TYPE_ENUM = ["site", "embed", "api"];
4328
4361
  var SITE_CONFIGURABLE_CHANNEL_TYPE_ENUM = ["builtin:slack", "builtin:discord"];
4329
4362
  var AIMESSAGE_ROLE_ENUM = ["user", "assistant", "developer"];
4330
4363
  var AIMODEL_ENUM = ["fast", "reasoning-low", "reasoning-medium", "reasoning-high"];
4364
+ var SITE_SETTINGS_SCAN_TOPICS_ENUM = ["auto", "never"];
4365
+ var SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM = ["always", "auto-fixable", "never"];
4331
4366
  var SITE_INSIGHTS_DISPLAY_CONTEXT_ENUM = ["site", "server", "embed", "mcp"];
4332
4367
  var SITE_INSIGHTS_LINK_POSITION_ENUM = ["announcement", "header", "footer", "sidebar", "content"];
4333
4368
  var SITE_INSIGHTS_TRADEMARK_PLACEMENT_ENUM = ["sidebar", "ad", "footer", "pdf", "embed"];
@@ -4660,6 +4695,7 @@ export {
4660
4695
  SITE_INSIGHTS_VISITOR_OS_ENUM,
4661
4696
  SITE_MCP_SERVER_NAME_MAX_LENGTH,
4662
4697
  SITE_MCP_SERVER_NAME_MIN_LENGTH,
4698
+ SITE_PERMISSIONS_MODEL_ENUM,
4663
4699
  SITE_PROXY_ORIGIN_MAX_LENGTH,
4664
4700
  SITE_PROXY_ORIGIN_PATTERN,
4665
4701
  SITE_QUESTION_ANSWER_HELPFULNESS_ENUM,
@@ -4678,6 +4714,8 @@ export {
4678
4714
  SITE_SECTION_PATH_MIN_LENGTH,
4679
4715
  SITE_SECTION_TITLE_MAX_LENGTH,
4680
4716
  SITE_SECTION_TITLE_MIN_LENGTH,
4717
+ SITE_SETTINGS_FINDING_CHANGE_REQUESTS_ENUM,
4718
+ SITE_SETTINGS_SCAN_TOPICS_ENUM,
4681
4719
  SITE_SOCIAL_ACCOUNT_HANDLE_MAX_LENGTH,
4682
4720
  SITE_SOCIAL_ACCOUNT_HANDLE_MIN_LENGTH,
4683
4721
  SITE_SOCIAL_ACCOUNT_PLATFORM_ENUM,
@@ -4714,12 +4752,15 @@ export {
4714
4752
  SiteInsightsVisitorBrowser,
4715
4753
  SiteInsightsVisitorDevice,
4716
4754
  SiteInsightsVisitorOS,
4755
+ SitePermissionsModel,
4717
4756
  SiteQuestionAnswerHelpfulness,
4718
4757
  SiteQuestionAnswerRelevance,
4719
4758
  SiteQuestionAnswerResolution,
4720
4759
  SiteQuestionAnswerSourceType,
4721
4760
  SiteQuestionType,
4722
4761
  SiteScanStatus,
4762
+ SiteSettingsFindingChangeRequests,
4763
+ SiteSettingsScanTopics,
4723
4764
  SiteSocialAccountPlatform,
4724
4765
  SiteType,
4725
4766
  SiteVisibility,
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "main": "./dist/index.cjs",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
7
- "version": "0.172.0",
7
+ "version": "0.173.0",
8
8
  "sideEffects": false,
9
9
  "files": [
10
10
  "README.md",