@gitbook/api 0.120.0 → 0.121.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 +122 -122
- package/dist/index.cjs +48 -1
- package/dist/index.js +47 -1
- package/package.json +1 -1
- package/spec/openapi.json +332 -380
- package/spec/openapi.yaml +219 -273
package/dist/client.d.ts
CHANGED
|
@@ -580,6 +580,15 @@ export interface DocumentInlineEmoji {
|
|
|
580
580
|
};
|
|
581
581
|
isVoid: true;
|
|
582
582
|
}
|
|
583
|
+
export interface DocumentInlineIcon {
|
|
584
|
+
object: 'inline';
|
|
585
|
+
type: 'icon';
|
|
586
|
+
key?: string;
|
|
587
|
+
data: {
|
|
588
|
+
icon: string;
|
|
589
|
+
};
|
|
590
|
+
isVoid: true;
|
|
591
|
+
}
|
|
583
592
|
export interface DocumentInlineExpression {
|
|
584
593
|
object: 'inline';
|
|
585
594
|
type: 'expression';
|
|
@@ -606,7 +615,7 @@ export interface DocumentBlockParagraph {
|
|
|
606
615
|
isVoid?: false;
|
|
607
616
|
data?: object;
|
|
608
617
|
}
|
|
609
|
-
export type DocumentInline = DocumentInlineLink | DocumentInlineEmoji | DocumentInlineExpression | DocumentInlineMath | DocumentInlineImage | DocumentInlineAnnotation | DocumentInlineMention | DocumentInlineButton;
|
|
618
|
+
export type DocumentInline = DocumentInlineLink | DocumentInlineEmoji | DocumentInlineIcon | DocumentInlineExpression | DocumentInlineMath | DocumentInlineImage | DocumentInlineAnnotation | DocumentInlineMention | DocumentInlineButton;
|
|
610
619
|
export interface DocumentBlockHeading {
|
|
611
620
|
object: 'block';
|
|
612
621
|
type: 'heading-1' | 'heading-2' | 'heading-3';
|
|
@@ -640,7 +649,7 @@ export interface DocumentBlockCodeLine {
|
|
|
640
649
|
object: 'block';
|
|
641
650
|
type: 'code-line';
|
|
642
651
|
key?: string;
|
|
643
|
-
nodes: (DocumentText | DocumentInlineAnnotation)[];
|
|
652
|
+
nodes: (DocumentText | DocumentInlineAnnotation | DocumentInlineExpression)[];
|
|
644
653
|
data: {
|
|
645
654
|
highlighted?: boolean;
|
|
646
655
|
};
|
|
@@ -3168,6 +3177,36 @@ export declare enum SiteAgentsContext {
|
|
|
3168
3177
|
Excluded = "excluded",
|
|
3169
3178
|
Included = "included"
|
|
3170
3179
|
}
|
|
3180
|
+
/** The site feature identifier */
|
|
3181
|
+
export declare enum SiteFeatureKey {
|
|
3182
|
+
SitesAdaptiveContent = "sites-adaptive-content",
|
|
3183
|
+
SitesAdvancedCustomization = "sites-advanced-customization",
|
|
3184
|
+
SitesAdvancedInsights = "sites-advanced-insights",
|
|
3185
|
+
SitesAds = "sites-ads",
|
|
3186
|
+
SitesAiSearch = "sites-ai-search",
|
|
3187
|
+
SitesApiPlayground = "sites-api-playground",
|
|
3188
|
+
SitesBasicCustomization = "sites-basic-customization",
|
|
3189
|
+
SitesCustomDomain = "sites-custom-domain",
|
|
3190
|
+
SitesCustomFonts = "sites-custom-fonts",
|
|
3191
|
+
SitesCustomSubdirectory = "sites-custom-subdirectory",
|
|
3192
|
+
SitesFullTextSearch = "sites-full-text-search",
|
|
3193
|
+
SitesMultivariantSite = "sites-multivariant-site",
|
|
3194
|
+
SitesNoCustomDomain = "sites-no-custom-domain",
|
|
3195
|
+
SitesPageFeedback = "sites-page-feedback",
|
|
3196
|
+
SitesPageTrafficInsights = "sites-page-traffic-insights",
|
|
3197
|
+
SitesPdfExport = "sites-pdf-export",
|
|
3198
|
+
SitesPreviewDeployments = "sites-preview-deployments",
|
|
3199
|
+
SitesPublicVisibility = "sites-public-visibility",
|
|
3200
|
+
SitesRedirects = "sites-redirects",
|
|
3201
|
+
SitesSearchInsights = "sites-search-insights",
|
|
3202
|
+
SitesSections = "sites-sections",
|
|
3203
|
+
SitesSeo = "sites-seo",
|
|
3204
|
+
SitesShareLinks = "sites-share-links",
|
|
3205
|
+
SitesUnlistedVisibility = "sites-unlisted-visibility",
|
|
3206
|
+
SitesUserContribution = "sites-user-contribution",
|
|
3207
|
+
SitesVisitorAuthentication = "sites-visitor-authentication",
|
|
3208
|
+
SitesVisitors = "sites-visitors"
|
|
3209
|
+
}
|
|
3171
3210
|
/** A list of all premium customizations. */
|
|
3172
3211
|
export declare enum SiteCustomizationFeature {
|
|
3173
3212
|
HeaderLogo = "header-logo",
|
|
@@ -3180,23 +3219,16 @@ export declare enum SiteCustomizationFeature {
|
|
|
3180
3219
|
SemanticColors = "semantic-colors"
|
|
3181
3220
|
}
|
|
3182
3221
|
/** A site feature and the plan it is available on. */
|
|
3183
|
-
export
|
|
3184
|
-
/** The feature identifier
|
|
3185
|
-
id:
|
|
3222
|
+
export interface SiteFeature {
|
|
3223
|
+
/** The site feature identifier */
|
|
3224
|
+
id: SiteFeatureKey;
|
|
3186
3225
|
/** The type of the site */
|
|
3187
3226
|
plan: SiteType;
|
|
3188
3227
|
/** A frozen feature is still enabled but cannot be changed or modified. */
|
|
3189
3228
|
frozen: boolean;
|
|
3190
|
-
|
|
3191
|
-
|
|
3192
|
-
|
|
3193
|
-
/** The type of the site */
|
|
3194
|
-
plan: SiteType;
|
|
3195
|
-
/** A frozen feature is still enabled but cannot be changed or modified. */
|
|
3196
|
-
frozen: boolean;
|
|
3197
|
-
/** A list of the actual advanced customizations used */
|
|
3198
|
-
customizations: SiteCustomizationFeature[];
|
|
3199
|
-
};
|
|
3229
|
+
/** A list of the actual advanced customizations used (only applicable for sites-advanced-customization) */
|
|
3230
|
+
customizations?: SiteCustomizationFeature[];
|
|
3231
|
+
}
|
|
3200
3232
|
export interface Site {
|
|
3201
3233
|
object: 'site';
|
|
3202
3234
|
/** Unique identifier of the site */
|
|
@@ -4960,6 +4992,24 @@ export interface ShareLink {
|
|
|
4960
4992
|
published?: string;
|
|
4961
4993
|
};
|
|
4962
4994
|
}
|
|
4995
|
+
export interface SiteStructureItemPointer {
|
|
4996
|
+
type: 'site-space' | 'site-section' | 'site-section-group';
|
|
4997
|
+
/** Unique identifier for the site structure item (site space, site section or site section group). */
|
|
4998
|
+
id: string;
|
|
4999
|
+
}
|
|
5000
|
+
/** Position at which to move the site structure item (site space, site section or site section group). */
|
|
5001
|
+
export interface SiteStructureItemMovePosition {
|
|
5002
|
+
before?: SiteStructureItemPointer;
|
|
5003
|
+
after?: SiteStructureItemPointer;
|
|
5004
|
+
}
|
|
5005
|
+
/**
|
|
5006
|
+
* Site Structure Item
|
|
5007
|
+
* A site structure item can be a site space, a site section or a site section group.
|
|
5008
|
+
* It is used to represent the structure of a site.
|
|
5009
|
+
*/
|
|
5010
|
+
export type SiteStructureItem = SiteSpace | SiteSection | SiteSectionGroup;
|
|
5011
|
+
/** The reason or feature that triggered the site upgrade */
|
|
5012
|
+
export type SiteUpgradeReason = SiteFeatureKey | 'settings' | 'publish-downgrade' | 'from-billing-modal' | 'payment-failed-modal';
|
|
4963
5013
|
export type SitePublishingAuth = (VisitorAuthCustomBackend | VisitorAuthIntegrationBackend) & {
|
|
4964
5014
|
/** Type of Object, always equals to "publishing-auth" */
|
|
4965
5015
|
object: 'publishing-auth';
|
|
@@ -6085,30 +6135,10 @@ export interface UpdateContentPublishingAuth {
|
|
|
6085
6135
|
*/
|
|
6086
6136
|
fallbackURL?: string;
|
|
6087
6137
|
}
|
|
6088
|
-
/** The context to send when triggering a content indexing. */
|
|
6089
|
-
export interface TriggerContentIndexingContext {
|
|
6090
|
-
/** The unique identifier of the Space to index. */
|
|
6091
|
-
spaceId: string;
|
|
6092
|
-
/** Whether to force a complete re-indexing of the Space. */
|
|
6093
|
-
force: boolean;
|
|
6094
|
-
}
|
|
6095
6138
|
/** Predefined GitBook user identifiers */
|
|
6096
6139
|
export declare enum GitBookUsers {
|
|
6097
6140
|
GitbookAgent = "gitbook:agent"
|
|
6098
6141
|
}
|
|
6099
|
-
export interface ContentPublishingAuth {
|
|
6100
|
-
/** Type of Object, always equals to "publishing-auth" */
|
|
6101
|
-
object: 'publishing-auth';
|
|
6102
|
-
/** Unique identifier for the content. */
|
|
6103
|
-
id: string;
|
|
6104
|
-
/** Private key used to sign JWT tokens. */
|
|
6105
|
-
privateKey: string;
|
|
6106
|
-
/**
|
|
6107
|
-
* URL to redirect to when the visitor auth secret is invalid.
|
|
6108
|
-
* @format uri
|
|
6109
|
-
*/
|
|
6110
|
-
fallbackURL?: string;
|
|
6111
|
-
}
|
|
6112
6142
|
export type ComputedContentSource = ComputedContentSourceDocument | ComputedContentSourceRevision;
|
|
6113
6143
|
export type InputPageBase = {
|
|
6114
6144
|
/**
|
|
@@ -6236,12 +6266,6 @@ export interface GitSyncOperation {
|
|
|
6236
6266
|
/** Error details, defined if state is `failure`. */
|
|
6237
6267
|
error?: string;
|
|
6238
6268
|
}
|
|
6239
|
-
export interface OrganizationTransferResponse {
|
|
6240
|
-
/** The unique id of the collection created in the target organization containing the content of the source organization. */
|
|
6241
|
-
collection: string;
|
|
6242
|
-
/** The new hostname if the source organization needed to change hostname. */
|
|
6243
|
-
newSourceHostname?: string;
|
|
6244
|
-
}
|
|
6245
6269
|
export type IntegrationEnvironmentSpaceInstallation = IntegrationContentInstallationBase & {
|
|
6246
6270
|
/** The space the integration is installed on. */
|
|
6247
6271
|
space: string;
|
|
@@ -6684,79 +6708,6 @@ export interface APIChannelMutationData {
|
|
|
6684
6708
|
}
|
|
6685
6709
|
/** Data passed through a realtime channel */
|
|
6686
6710
|
export type SubscriptionChannelData = GitSyncOperationChannelData | SpaceContentRefsChannelData | ChangeRequestContentRefsChannelData | OrganizationAIIndexationChannelData | APIChannelMutationData;
|
|
6687
|
-
/**
|
|
6688
|
-
* @minLength 1
|
|
6689
|
-
* @maxLength 50
|
|
6690
|
-
* @pattern ^[a-z_\-0-9]+$
|
|
6691
|
-
*/
|
|
6692
|
-
export type VariableName = string;
|
|
6693
|
-
export interface CustomizationSettings {
|
|
6694
|
-
/** Inherit customization settings from the parent collection. */
|
|
6695
|
-
inherit: boolean;
|
|
6696
|
-
/** Title to use for the published content. If not defined, it'll fallback to the content title. */
|
|
6697
|
-
title?: string;
|
|
6698
|
-
styling: {
|
|
6699
|
-
primaryColor: CustomizationThemedColor;
|
|
6700
|
-
corners: CustomizationCorners;
|
|
6701
|
-
font: CustomizationDefaultFont;
|
|
6702
|
-
/** The background style has been deprecated and will be removed in a future release. Use the `tint` settings instead. */
|
|
6703
|
-
background?: CustomizationBackground;
|
|
6704
|
-
};
|
|
6705
|
-
internationalization: {
|
|
6706
|
-
/** Language for the UI element */
|
|
6707
|
-
locale: CustomizationLocale;
|
|
6708
|
-
};
|
|
6709
|
-
favicon: CustomizationFavicon;
|
|
6710
|
-
header: {
|
|
6711
|
-
/** The header preset to use for the site. This is a legacy setting and the site styling theme should be used instead. */
|
|
6712
|
-
preset: CustomizationHeaderPreset;
|
|
6713
|
-
logo?: CustomizationThemedURL;
|
|
6714
|
-
backgroundColor?: CustomizationThemedColor;
|
|
6715
|
-
linkColor?: CustomizationThemedColor;
|
|
6716
|
-
links: CustomizationHeaderItem[];
|
|
6717
|
-
};
|
|
6718
|
-
footer: {
|
|
6719
|
-
logo?: CustomizationThemedURL;
|
|
6720
|
-
groups: CustomizationFooterGroup[];
|
|
6721
|
-
/** @maxLength 300 */
|
|
6722
|
-
copyright?: string;
|
|
6723
|
-
};
|
|
6724
|
-
themes: {
|
|
6725
|
-
default: CustomizationThemeMode;
|
|
6726
|
-
/** Should the reader be able to switch between dark and light mode */
|
|
6727
|
-
toggeable: boolean;
|
|
6728
|
-
};
|
|
6729
|
-
pdf: {
|
|
6730
|
-
/** If true, PDF export is enabled for the published content. */
|
|
6731
|
-
enabled: boolean;
|
|
6732
|
-
};
|
|
6733
|
-
feedback: {
|
|
6734
|
-
/** If true, feedback gathering is enabled */
|
|
6735
|
-
enabled: boolean;
|
|
6736
|
-
};
|
|
6737
|
-
aiSearch: {
|
|
6738
|
-
/** If true, AI search is enabled */
|
|
6739
|
-
enabled: boolean;
|
|
6740
|
-
};
|
|
6741
|
-
git: {
|
|
6742
|
-
/** Whether the public content should show a link to edit the content on the git provider set up in the GitSync */
|
|
6743
|
-
showEditLink: boolean;
|
|
6744
|
-
};
|
|
6745
|
-
pagination: {
|
|
6746
|
-
/** Whether the pagination navigation should be displayed on pages. */
|
|
6747
|
-
enabled: boolean;
|
|
6748
|
-
};
|
|
6749
|
-
trademark: {
|
|
6750
|
-
/** Whether the GitBook trademark ("Powered by GitBook") should be visible */
|
|
6751
|
-
enabled: boolean;
|
|
6752
|
-
};
|
|
6753
|
-
privacyPolicy: {
|
|
6754
|
-
url?: URL;
|
|
6755
|
-
};
|
|
6756
|
-
socialPreview: {
|
|
6757
|
-
url?: URL;
|
|
6758
|
-
};
|
|
6759
|
-
}
|
|
6760
6711
|
/** The status of ads on the site */
|
|
6761
6712
|
export declare enum SiteAdsStatus {
|
|
6762
6713
|
Pending = "pending",
|
|
@@ -7851,6 +7802,22 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
7851
7802
|
/** The user requests that were sent. */
|
|
7852
7803
|
users?: ChangeRequestRequestedReviewer[];
|
|
7853
7804
|
}, any>>;
|
|
7805
|
+
/**
|
|
7806
|
+
* No description
|
|
7807
|
+
*
|
|
7808
|
+
* @tags change-request-reviewers
|
|
7809
|
+
* @name RemoveRequestedReviewerFromChangeRequest
|
|
7810
|
+
* @summary Remove a reviewer from a change request
|
|
7811
|
+
* @request DELETE:/spaces/{spaceId}/change-requests/{changeRequestId}/requested-reviewers/{userId}
|
|
7812
|
+
* @secure
|
|
7813
|
+
*/
|
|
7814
|
+
removeRequestedReviewerFromChangeRequest: (spaceId: string, changeRequestId: string, userId: string, params?: RequestParams) => Promise<HttpResponse<void, {
|
|
7815
|
+
error: {
|
|
7816
|
+
/** @format int32 */
|
|
7817
|
+
code: 404;
|
|
7818
|
+
message: string;
|
|
7819
|
+
};
|
|
7820
|
+
}>>;
|
|
7854
7821
|
/**
|
|
7855
7822
|
* No description
|
|
7856
7823
|
*
|
|
@@ -9186,6 +9153,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
9186
9153
|
owner?: string;
|
|
9187
9154
|
/** Filter the integrations by scope */
|
|
9188
9155
|
scope?: IntegrationScope;
|
|
9156
|
+
/** Filter the integrations by target */
|
|
9157
|
+
target?: IntegrationTarget;
|
|
9189
9158
|
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
9190
9159
|
items: Integration[];
|
|
9191
9160
|
}, any>>;
|
|
@@ -10278,6 +10247,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10278
10247
|
owner?: string;
|
|
10279
10248
|
/** Filter the integrations by scope */
|
|
10280
10249
|
scope?: IntegrationScope;
|
|
10250
|
+
/** Filter the integrations by target */
|
|
10251
|
+
target?: IntegrationTarget;
|
|
10281
10252
|
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
10282
10253
|
items: Integration[];
|
|
10283
10254
|
}, any>>;
|
|
@@ -11426,6 +11397,33 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11426
11397
|
message: string;
|
|
11427
11398
|
};
|
|
11428
11399
|
}>>;
|
|
11400
|
+
/**
|
|
11401
|
+
* No description
|
|
11402
|
+
*
|
|
11403
|
+
* @tags sites
|
|
11404
|
+
* @name SortSiteStructure
|
|
11405
|
+
* @summary Move a site space, site section or site section group to a new position in the site structure.
|
|
11406
|
+
* @request PATCH:/orgs/{organizationId}/sites/{siteId}/structure/sort
|
|
11407
|
+
* @secure
|
|
11408
|
+
*/
|
|
11409
|
+
sortSiteStructure: (organizationId: string, siteId: string, data: {
|
|
11410
|
+
/** pointer to the item (site space, site section or site section group) being moved. */
|
|
11411
|
+
item: SiteStructureItemPointer;
|
|
11412
|
+
/** The position to move the item to. When not provided the item is moved to the end of the site structure. */
|
|
11413
|
+
position: SiteStructureItemMovePosition;
|
|
11414
|
+
}, params?: RequestParams) => Promise<HttpResponse<SiteStructureItem, Error | {
|
|
11415
|
+
error: {
|
|
11416
|
+
/** @format int32 */
|
|
11417
|
+
code: 400;
|
|
11418
|
+
message: string;
|
|
11419
|
+
};
|
|
11420
|
+
} | {
|
|
11421
|
+
error: {
|
|
11422
|
+
/** @format int32 */
|
|
11423
|
+
code: 404;
|
|
11424
|
+
message: string;
|
|
11425
|
+
};
|
|
11426
|
+
}>>;
|
|
11429
11427
|
/**
|
|
11430
11428
|
* No description
|
|
11431
11429
|
*
|
|
@@ -11703,11 +11701,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11703
11701
|
addSectionToSite: (organizationId: string, siteId: string, data: {
|
|
11704
11702
|
/** ID of the space to be added to the section as a site space variant */
|
|
11705
11703
|
spaceId: string;
|
|
11706
|
-
|
|
11707
|
-
|
|
11708
|
-
* @maxLength 64
|
|
11709
|
-
*/
|
|
11710
|
-
title?: string;
|
|
11704
|
+
title?: SiteSectionTitle | null;
|
|
11705
|
+
icon?: Icon | null;
|
|
11711
11706
|
}, params?: RequestParams) => Promise<HttpResponse<SiteSection, any>>;
|
|
11712
11707
|
/**
|
|
11713
11708
|
* No description
|
|
@@ -11856,6 +11851,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11856
11851
|
path?: SiteSpacePath;
|
|
11857
11852
|
/** Conditional expression used to evaluate whether the site space 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. */
|
|
11858
11853
|
condition?: Condition | null;
|
|
11854
|
+
/** The content that this site space points to. If not set, the space will remain unchanged. */
|
|
11855
|
+
spaceId?: string;
|
|
11859
11856
|
}, params?: RequestParams) => Promise<HttpResponse<SiteSpace, any>>;
|
|
11860
11857
|
/**
|
|
11861
11858
|
* No description
|
|
@@ -12033,8 +12030,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
12033
12030
|
*
|
|
12034
12031
|
* @tags site-section-groups
|
|
12035
12032
|
* @name MoveSiteSectionGroup
|
|
12036
|
-
* @summary Move a site section group to a new position
|
|
12033
|
+
* @summary Move a site section group to a new position. (Deprecated) use sortSiteStructure instead.
|
|
12037
12034
|
* @request POST:/orgs/{organizationId}/sites/{siteId}/section-groups/{siteSectionGroupId}/move
|
|
12035
|
+
* @deprecated
|
|
12038
12036
|
* @secure
|
|
12039
12037
|
*/
|
|
12040
12038
|
moveSiteSectionGroup: (organizationId: string, siteId: string, siteSectionGroupId: string, data: {
|
|
@@ -12058,8 +12056,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
12058
12056
|
*
|
|
12059
12057
|
* @tags site-sections
|
|
12060
12058
|
* @name MoveSiteSection
|
|
12061
|
-
* @summary Move a site section to a new position
|
|
12059
|
+
* @summary Move a site section to a new position. (Deprecated) use sortSiteStructure instead.
|
|
12062
12060
|
* @request POST:/orgs/{organizationId}/sites/{siteId}/sections/{siteSectionId}/move
|
|
12061
|
+
* @deprecated
|
|
12063
12062
|
* @secure
|
|
12064
12063
|
*/
|
|
12065
12064
|
moveSiteSection: (organizationId: string, siteId: string, siteSectionId: string, data: {
|
|
@@ -12083,8 +12082,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
12083
12082
|
*
|
|
12084
12083
|
* @tags site-spaces
|
|
12085
12084
|
* @name MoveSiteSpace
|
|
12086
|
-
* @summary Move a site space to a new position
|
|
12085
|
+
* @summary Move a site space to a new position. (Deprecated) use sortSiteStructure instead.
|
|
12087
12086
|
* @request POST:/orgs/{organizationId}/sites/{siteId}/site-spaces/{siteSpaceId}/move
|
|
12087
|
+
* @deprecated
|
|
12088
12088
|
* @secure
|
|
12089
12089
|
*/
|
|
12090
12090
|
moveSiteSpace: (organizationId: string, siteId: string, siteSpaceId: string, data: {
|
package/dist/index.cjs
CHANGED
|
@@ -249,6 +249,7 @@ __export(src_exports, {
|
|
|
249
249
|
SiteAdsTopic: () => SiteAdsTopic,
|
|
250
250
|
SiteAgentsContext: () => SiteAgentsContext,
|
|
251
251
|
SiteCustomizationFeature: () => SiteCustomizationFeature,
|
|
252
|
+
SiteFeatureKey: () => SiteFeatureKey,
|
|
252
253
|
SiteInsightsAdPlacement: () => SiteInsightsAdPlacement,
|
|
253
254
|
SiteInsightsEventType: () => SiteInsightsEventType,
|
|
254
255
|
SiteInsightsLinkPosition: () => SiteInsightsLinkPosition,
|
|
@@ -270,7 +271,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
270
271
|
|
|
271
272
|
// package.json
|
|
272
273
|
var name = "@gitbook/api";
|
|
273
|
-
var version = "0.
|
|
274
|
+
var version = "0.121.0";
|
|
274
275
|
|
|
275
276
|
// src/client.ts
|
|
276
277
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -652,6 +653,36 @@ var SiteAgentsContext = /* @__PURE__ */ ((SiteAgentsContext2) => {
|
|
|
652
653
|
SiteAgentsContext2["Included"] = "included";
|
|
653
654
|
return SiteAgentsContext2;
|
|
654
655
|
})(SiteAgentsContext || {});
|
|
656
|
+
var SiteFeatureKey = /* @__PURE__ */ ((SiteFeatureKey2) => {
|
|
657
|
+
SiteFeatureKey2["SitesAdaptiveContent"] = "sites-adaptive-content";
|
|
658
|
+
SiteFeatureKey2["SitesAdvancedCustomization"] = "sites-advanced-customization";
|
|
659
|
+
SiteFeatureKey2["SitesAdvancedInsights"] = "sites-advanced-insights";
|
|
660
|
+
SiteFeatureKey2["SitesAds"] = "sites-ads";
|
|
661
|
+
SiteFeatureKey2["SitesAiSearch"] = "sites-ai-search";
|
|
662
|
+
SiteFeatureKey2["SitesApiPlayground"] = "sites-api-playground";
|
|
663
|
+
SiteFeatureKey2["SitesBasicCustomization"] = "sites-basic-customization";
|
|
664
|
+
SiteFeatureKey2["SitesCustomDomain"] = "sites-custom-domain";
|
|
665
|
+
SiteFeatureKey2["SitesCustomFonts"] = "sites-custom-fonts";
|
|
666
|
+
SiteFeatureKey2["SitesCustomSubdirectory"] = "sites-custom-subdirectory";
|
|
667
|
+
SiteFeatureKey2["SitesFullTextSearch"] = "sites-full-text-search";
|
|
668
|
+
SiteFeatureKey2["SitesMultivariantSite"] = "sites-multivariant-site";
|
|
669
|
+
SiteFeatureKey2["SitesNoCustomDomain"] = "sites-no-custom-domain";
|
|
670
|
+
SiteFeatureKey2["SitesPageFeedback"] = "sites-page-feedback";
|
|
671
|
+
SiteFeatureKey2["SitesPageTrafficInsights"] = "sites-page-traffic-insights";
|
|
672
|
+
SiteFeatureKey2["SitesPdfExport"] = "sites-pdf-export";
|
|
673
|
+
SiteFeatureKey2["SitesPreviewDeployments"] = "sites-preview-deployments";
|
|
674
|
+
SiteFeatureKey2["SitesPublicVisibility"] = "sites-public-visibility";
|
|
675
|
+
SiteFeatureKey2["SitesRedirects"] = "sites-redirects";
|
|
676
|
+
SiteFeatureKey2["SitesSearchInsights"] = "sites-search-insights";
|
|
677
|
+
SiteFeatureKey2["SitesSections"] = "sites-sections";
|
|
678
|
+
SiteFeatureKey2["SitesSeo"] = "sites-seo";
|
|
679
|
+
SiteFeatureKey2["SitesShareLinks"] = "sites-share-links";
|
|
680
|
+
SiteFeatureKey2["SitesUnlistedVisibility"] = "sites-unlisted-visibility";
|
|
681
|
+
SiteFeatureKey2["SitesUserContribution"] = "sites-user-contribution";
|
|
682
|
+
SiteFeatureKey2["SitesVisitorAuthentication"] = "sites-visitor-authentication";
|
|
683
|
+
SiteFeatureKey2["SitesVisitors"] = "sites-visitors";
|
|
684
|
+
return SiteFeatureKey2;
|
|
685
|
+
})(SiteFeatureKey || {});
|
|
655
686
|
var SiteCustomizationFeature = /* @__PURE__ */ ((SiteCustomizationFeature2) => {
|
|
656
687
|
SiteCustomizationFeature2["HeaderLogo"] = "header-logo";
|
|
657
688
|
SiteCustomizationFeature2["ThemePreset"] = "theme-preset";
|
|
@@ -1616,6 +1647,12 @@ var Api = class extends HttpClient {
|
|
|
1616
1647
|
format: "json",
|
|
1617
1648
|
...params
|
|
1618
1649
|
}),
|
|
1650
|
+
removeRequestedReviewerFromChangeRequest: (spaceId, changeRequestId, userId, params = {}) => this.request({
|
|
1651
|
+
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/requested-reviewers/${userId}`,
|
|
1652
|
+
method: "DELETE",
|
|
1653
|
+
secure: true,
|
|
1654
|
+
...params
|
|
1655
|
+
}),
|
|
1619
1656
|
listChangeRequestLinks: (spaceId, changeRequestId, query, params = {}) => this.request({
|
|
1620
1657
|
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/links`,
|
|
1621
1658
|
method: "GET",
|
|
@@ -3110,6 +3147,15 @@ var Api = class extends HttpClient {
|
|
|
3110
3147
|
format: "json",
|
|
3111
3148
|
...params
|
|
3112
3149
|
}),
|
|
3150
|
+
sortSiteStructure: (organizationId, siteId, data, params = {}) => this.request({
|
|
3151
|
+
path: `/orgs/${organizationId}/sites/${siteId}/structure/sort`,
|
|
3152
|
+
method: "PATCH",
|
|
3153
|
+
body: data,
|
|
3154
|
+
secure: true,
|
|
3155
|
+
type: "application/json" /* Json */,
|
|
3156
|
+
format: "json",
|
|
3157
|
+
...params
|
|
3158
|
+
}),
|
|
3113
3159
|
getSitePublishingAuthById: (organizationId, siteId, params = {}) => this.request({
|
|
3114
3160
|
path: `/orgs/${organizationId}/sites/${siteId}/publishing/auth`,
|
|
3115
3161
|
method: "GET",
|
|
@@ -3696,6 +3742,7 @@ var GitBookAPI = class extends Api {
|
|
|
3696
3742
|
SiteAdsTopic,
|
|
3697
3743
|
SiteAgentsContext,
|
|
3698
3744
|
SiteCustomizationFeature,
|
|
3745
|
+
SiteFeatureKey,
|
|
3699
3746
|
SiteInsightsAdPlacement,
|
|
3700
3747
|
SiteInsightsEventType,
|
|
3701
3748
|
SiteInsightsLinkPosition,
|
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.121.0";
|
|
176
176
|
|
|
177
177
|
// src/client.ts
|
|
178
178
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -554,6 +554,36 @@ var SiteAgentsContext = /* @__PURE__ */ ((SiteAgentsContext2) => {
|
|
|
554
554
|
SiteAgentsContext2["Included"] = "included";
|
|
555
555
|
return SiteAgentsContext2;
|
|
556
556
|
})(SiteAgentsContext || {});
|
|
557
|
+
var SiteFeatureKey = /* @__PURE__ */ ((SiteFeatureKey2) => {
|
|
558
|
+
SiteFeatureKey2["SitesAdaptiveContent"] = "sites-adaptive-content";
|
|
559
|
+
SiteFeatureKey2["SitesAdvancedCustomization"] = "sites-advanced-customization";
|
|
560
|
+
SiteFeatureKey2["SitesAdvancedInsights"] = "sites-advanced-insights";
|
|
561
|
+
SiteFeatureKey2["SitesAds"] = "sites-ads";
|
|
562
|
+
SiteFeatureKey2["SitesAiSearch"] = "sites-ai-search";
|
|
563
|
+
SiteFeatureKey2["SitesApiPlayground"] = "sites-api-playground";
|
|
564
|
+
SiteFeatureKey2["SitesBasicCustomization"] = "sites-basic-customization";
|
|
565
|
+
SiteFeatureKey2["SitesCustomDomain"] = "sites-custom-domain";
|
|
566
|
+
SiteFeatureKey2["SitesCustomFonts"] = "sites-custom-fonts";
|
|
567
|
+
SiteFeatureKey2["SitesCustomSubdirectory"] = "sites-custom-subdirectory";
|
|
568
|
+
SiteFeatureKey2["SitesFullTextSearch"] = "sites-full-text-search";
|
|
569
|
+
SiteFeatureKey2["SitesMultivariantSite"] = "sites-multivariant-site";
|
|
570
|
+
SiteFeatureKey2["SitesNoCustomDomain"] = "sites-no-custom-domain";
|
|
571
|
+
SiteFeatureKey2["SitesPageFeedback"] = "sites-page-feedback";
|
|
572
|
+
SiteFeatureKey2["SitesPageTrafficInsights"] = "sites-page-traffic-insights";
|
|
573
|
+
SiteFeatureKey2["SitesPdfExport"] = "sites-pdf-export";
|
|
574
|
+
SiteFeatureKey2["SitesPreviewDeployments"] = "sites-preview-deployments";
|
|
575
|
+
SiteFeatureKey2["SitesPublicVisibility"] = "sites-public-visibility";
|
|
576
|
+
SiteFeatureKey2["SitesRedirects"] = "sites-redirects";
|
|
577
|
+
SiteFeatureKey2["SitesSearchInsights"] = "sites-search-insights";
|
|
578
|
+
SiteFeatureKey2["SitesSections"] = "sites-sections";
|
|
579
|
+
SiteFeatureKey2["SitesSeo"] = "sites-seo";
|
|
580
|
+
SiteFeatureKey2["SitesShareLinks"] = "sites-share-links";
|
|
581
|
+
SiteFeatureKey2["SitesUnlistedVisibility"] = "sites-unlisted-visibility";
|
|
582
|
+
SiteFeatureKey2["SitesUserContribution"] = "sites-user-contribution";
|
|
583
|
+
SiteFeatureKey2["SitesVisitorAuthentication"] = "sites-visitor-authentication";
|
|
584
|
+
SiteFeatureKey2["SitesVisitors"] = "sites-visitors";
|
|
585
|
+
return SiteFeatureKey2;
|
|
586
|
+
})(SiteFeatureKey || {});
|
|
557
587
|
var SiteCustomizationFeature = /* @__PURE__ */ ((SiteCustomizationFeature2) => {
|
|
558
588
|
SiteCustomizationFeature2["HeaderLogo"] = "header-logo";
|
|
559
589
|
SiteCustomizationFeature2["ThemePreset"] = "theme-preset";
|
|
@@ -1518,6 +1548,12 @@ var Api = class extends HttpClient {
|
|
|
1518
1548
|
format: "json",
|
|
1519
1549
|
...params
|
|
1520
1550
|
}),
|
|
1551
|
+
removeRequestedReviewerFromChangeRequest: (spaceId, changeRequestId, userId, params = {}) => this.request({
|
|
1552
|
+
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/requested-reviewers/${userId}`,
|
|
1553
|
+
method: "DELETE",
|
|
1554
|
+
secure: true,
|
|
1555
|
+
...params
|
|
1556
|
+
}),
|
|
1521
1557
|
listChangeRequestLinks: (spaceId, changeRequestId, query, params = {}) => this.request({
|
|
1522
1558
|
path: `/spaces/${spaceId}/change-requests/${changeRequestId}/links`,
|
|
1523
1559
|
method: "GET",
|
|
@@ -3012,6 +3048,15 @@ var Api = class extends HttpClient {
|
|
|
3012
3048
|
format: "json",
|
|
3013
3049
|
...params
|
|
3014
3050
|
}),
|
|
3051
|
+
sortSiteStructure: (organizationId, siteId, data, params = {}) => this.request({
|
|
3052
|
+
path: `/orgs/${organizationId}/sites/${siteId}/structure/sort`,
|
|
3053
|
+
method: "PATCH",
|
|
3054
|
+
body: data,
|
|
3055
|
+
secure: true,
|
|
3056
|
+
type: "application/json" /* Json */,
|
|
3057
|
+
format: "json",
|
|
3058
|
+
...params
|
|
3059
|
+
}),
|
|
3015
3060
|
getSitePublishingAuthById: (organizationId, siteId, params = {}) => this.request({
|
|
3016
3061
|
path: `/orgs/${organizationId}/sites/${siteId}/publishing/auth`,
|
|
3017
3062
|
method: "GET",
|
|
@@ -3597,6 +3642,7 @@ export {
|
|
|
3597
3642
|
SiteAdsTopic,
|
|
3598
3643
|
SiteAgentsContext,
|
|
3599
3644
|
SiteCustomizationFeature,
|
|
3645
|
+
SiteFeatureKey,
|
|
3600
3646
|
SiteInsightsAdPlacement,
|
|
3601
3647
|
SiteInsightsEventType,
|
|
3602
3648
|
SiteInsightsLinkPosition,
|