@gitbook/api 0.66.0 → 0.68.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 +184 -46
- package/dist/index.cjs +31 -9
- package/dist/index.js +31 -9
- package/package.json +1 -1
- package/spec/openapi.json +703 -173
- package/spec/openapi.yaml +436 -114
package/dist/client.d.ts
CHANGED
|
@@ -149,8 +149,12 @@ export interface ContentRefSyncedBlock {
|
|
|
149
149
|
kind: 'synced-block';
|
|
150
150
|
syncedBlock: string;
|
|
151
151
|
}
|
|
152
|
+
export interface ContentRefReusableContent {
|
|
153
|
+
kind: 'reusable-content';
|
|
154
|
+
reusableContent: string;
|
|
155
|
+
}
|
|
152
156
|
/** A relative reference to content in GitBook. */
|
|
153
|
-
export type ContentRef = ContentRefFile | ContentRefURL | ContentRefPage | ContentRefAnchor | ContentRefUser | ContentRefCollection | ContentRefSpace | ContentRefSnippet | ContentRefSyncedBlock;
|
|
157
|
+
export type ContentRef = ContentRefFile | ContentRefURL | ContentRefPage | ContentRefAnchor | ContentRefUser | ContentRefCollection | ContentRefSpace | ContentRefSnippet | ContentRefSyncedBlock | ContentRefReusableContent;
|
|
154
158
|
export interface DocumentInlineLink {
|
|
155
159
|
object: 'inline';
|
|
156
160
|
type: 'link';
|
|
@@ -530,7 +534,7 @@ export type ContentKitDefaultAction = {
|
|
|
530
534
|
action: '@ui.modal.close';
|
|
531
535
|
returnValue: PlainObject;
|
|
532
536
|
} | {
|
|
533
|
-
action: '@ui.
|
|
537
|
+
action: '@ui.complete';
|
|
534
538
|
returnValue: PlainObject;
|
|
535
539
|
} | {
|
|
536
540
|
action: '@ui.url.open';
|
|
@@ -625,7 +629,34 @@ export interface DocumentBlockSyncedBlock {
|
|
|
625
629
|
};
|
|
626
630
|
isVoid: true;
|
|
627
631
|
}
|
|
628
|
-
export
|
|
632
|
+
export interface DocumentBlockReusableContent {
|
|
633
|
+
object: 'block';
|
|
634
|
+
type: 'reusable-content';
|
|
635
|
+
key?: string;
|
|
636
|
+
data: {
|
|
637
|
+
ref: ContentRefReusableContent;
|
|
638
|
+
};
|
|
639
|
+
isVoid: true;
|
|
640
|
+
}
|
|
641
|
+
export interface DocumentBlockStepperStep {
|
|
642
|
+
object: 'block';
|
|
643
|
+
type: 'stepper-step';
|
|
644
|
+
key?: string;
|
|
645
|
+
nodes: (DocumentBlocksEssentials | DocumentBlockContentRef | DocumentBlockCode | DocumentBlockEmbed | DocumentBlockFile | DocumentBlockImages | DocumentBlockDrawing | DocumentBlockHint | DocumentBlockQuote | DocumentBlockMath | DocumentBlockIntegration)[];
|
|
646
|
+
data: {
|
|
647
|
+
icon?: string;
|
|
648
|
+
};
|
|
649
|
+
isVoid?: false;
|
|
650
|
+
}
|
|
651
|
+
export interface DocumentBlockStepper {
|
|
652
|
+
object: 'block';
|
|
653
|
+
type: 'stepper';
|
|
654
|
+
key?: string;
|
|
655
|
+
nodes: DocumentBlockStepperStep[];
|
|
656
|
+
isVoid?: false;
|
|
657
|
+
data?: object;
|
|
658
|
+
}
|
|
659
|
+
export type DocumentBlocksTopLevels = DocumentBlocksEssentials | DocumentBlockQuote | DocumentBlockHint | DocumentBlockImages | DocumentBlockFile | DocumentBlockDrawing | DocumentBlockEmbed | DocumentBlockCode | DocumentBlockMath | DocumentBlockExpandable | DocumentBlockTabs | DocumentBlockTable | DocumentBlockSwagger | DocumentBlockContentRef | DocumentBlockIntegration | DocumentBlockSyncedBlock | DocumentBlockReusableContent | DocumentBlockStepper;
|
|
629
660
|
export interface JSONDocument {
|
|
630
661
|
object: 'document';
|
|
631
662
|
data: {
|
|
@@ -1628,9 +1659,12 @@ export type IntegrationDescription = string;
|
|
|
1628
1659
|
* @maxLength 2048
|
|
1629
1660
|
*/
|
|
1630
1661
|
export type IntegrationSummary = string;
|
|
1662
|
+
/** The target on which the integration can operate and needs to be configured for */
|
|
1631
1663
|
export declare enum IntegrationTarget {
|
|
1632
|
-
|
|
1633
|
-
|
|
1664
|
+
All = "all",
|
|
1665
|
+
Site = "site",
|
|
1666
|
+
Space = "space",
|
|
1667
|
+
Organization = "organization"
|
|
1634
1668
|
}
|
|
1635
1669
|
export declare enum IntegrationVisibility {
|
|
1636
1670
|
Public = "public",
|
|
@@ -1789,6 +1823,7 @@ export interface Integration {
|
|
|
1789
1823
|
* @maxItems 3
|
|
1790
1824
|
*/
|
|
1791
1825
|
previewImages: string[];
|
|
1826
|
+
/** The target on which the integration can operate and needs to be configured for */
|
|
1792
1827
|
target: IntegrationTarget;
|
|
1793
1828
|
/** If true, the integration has been verified by the GitBook team */
|
|
1794
1829
|
verified: boolean;
|
|
@@ -2277,7 +2312,29 @@ export interface RevisionSemanticChangeCustomFieldsEdited {
|
|
|
2277
2312
|
type: 'custom_fields_edited';
|
|
2278
2313
|
customFields: ChangeAttributeCustomFields;
|
|
2279
2314
|
}
|
|
2280
|
-
export
|
|
2315
|
+
export interface ChangedRevisionReusableContent {
|
|
2316
|
+
id: string;
|
|
2317
|
+
title: string;
|
|
2318
|
+
document?: string;
|
|
2319
|
+
}
|
|
2320
|
+
export interface RevisionSemanticChangeReusableContentCreated {
|
|
2321
|
+
type: 'reusable_content_created';
|
|
2322
|
+
reusableContent: ChangedRevisionReusableContent;
|
|
2323
|
+
}
|
|
2324
|
+
export interface RevisionSemanticChangeReusableContentDeleted {
|
|
2325
|
+
type: 'reusable_content_deleted';
|
|
2326
|
+
reusableContent: ChangedRevisionReusableContent;
|
|
2327
|
+
}
|
|
2328
|
+
export interface RevisionReusableContentChangeAttributes {
|
|
2329
|
+
title?: ChangeAttributeString;
|
|
2330
|
+
document?: ChangeAttributeString;
|
|
2331
|
+
}
|
|
2332
|
+
export interface RevisionSemanticChangeReusableContentEdited {
|
|
2333
|
+
type: 'reusable_content_edited';
|
|
2334
|
+
reusableContent: ChangedRevisionReusableContent;
|
|
2335
|
+
attributes: RevisionReusableContentChangeAttributes;
|
|
2336
|
+
}
|
|
2337
|
+
export type RevisionSemanticChange = RevisionSemanticChangePageCreated | RevisionSemanticChangePageEdited | RevisionSemanticChangePageDeleted | RevisionSemanticChangePageMoved | RevisionSemanticChangeFileCreated | RevisionSemanticChangeFileEdited | RevisionSemanticChangeFileDeleted | RevisionSemanticChangeCustomFieldsEdited | RevisionSemanticChangeReusableContentCreated | RevisionSemanticChangeReusableContentDeleted | RevisionSemanticChangeReusableContentEdited;
|
|
2281
2338
|
export interface RevisionSemanticChanges {
|
|
2282
2339
|
changes: RevisionSemanticChange[];
|
|
2283
2340
|
/** How many changes were omitted because above the result limit */
|
|
@@ -2896,6 +2953,8 @@ export type ContentKitContextConfigurationContentSource = ContentKitContextBase
|
|
|
2896
2953
|
type: 'configuration_contentsource';
|
|
2897
2954
|
/** ID of the organization the content source installation configuration is in. */
|
|
2898
2955
|
organizationId: string;
|
|
2956
|
+
/** Optional ID of the space the content source installation configuration is in. */
|
|
2957
|
+
spaceId?: string;
|
|
2899
2958
|
};
|
|
2900
2959
|
/** Context while rendering in a document. */
|
|
2901
2960
|
export type ContentKitContextDocument = ContentKitContextBase & {
|
|
@@ -3492,6 +3551,37 @@ export interface InviteUsersToOrganization {
|
|
|
3492
3551
|
/** If true, invites the user as an SSO user of the organization. Defaults to false. */
|
|
3493
3552
|
sso?: boolean;
|
|
3494
3553
|
}
|
|
3554
|
+
/** An invite link to a specific collection in an organization */
|
|
3555
|
+
export interface InviteLinkToCollection {
|
|
3556
|
+
/** Type of Object, always equals to "invite" */
|
|
3557
|
+
object: 'invite';
|
|
3558
|
+
/** Unique identifier for the invite link to the collection */
|
|
3559
|
+
id: string;
|
|
3560
|
+
/** The level of the member in the target collection */
|
|
3561
|
+
level: MemberRoleOrGuest;
|
|
3562
|
+
/** The collection the member has been invited to */
|
|
3563
|
+
collection: Collection;
|
|
3564
|
+
}
|
|
3565
|
+
/** An invite link to a specific space in an organization */
|
|
3566
|
+
export interface InviteLinkToSpace {
|
|
3567
|
+
/** Type of Object, always equals to "invite" */
|
|
3568
|
+
object: 'invite';
|
|
3569
|
+
/** Unique identifier for the invite link to the space */
|
|
3570
|
+
id: string;
|
|
3571
|
+
/** The level of the member in the target space */
|
|
3572
|
+
level: MemberRoleOrGuest;
|
|
3573
|
+
/** The space the member has been invited to */
|
|
3574
|
+
space: Space;
|
|
3575
|
+
}
|
|
3576
|
+
/** An invite link to an organization */
|
|
3577
|
+
export interface InviteLinkToOrganization {
|
|
3578
|
+
/** Type of Object, always equals to "invite" */
|
|
3579
|
+
object: 'invite';
|
|
3580
|
+
/** Unique identifier for the invite link to the organization */
|
|
3581
|
+
id: string;
|
|
3582
|
+
/** The role of the member in the organization */
|
|
3583
|
+
role: MemberRoleOrGuest;
|
|
3584
|
+
}
|
|
3495
3585
|
export interface CreateInviteToOrganization {
|
|
3496
3586
|
/** The role of the member in the organization */
|
|
3497
3587
|
role: MemberRoleOrGuest;
|
|
@@ -3509,28 +3599,8 @@ export interface CreateInviteToCollection {
|
|
|
3509
3599
|
collection: string;
|
|
3510
3600
|
}
|
|
3511
3601
|
export type CreateOrganizationInvite = CreateInviteToOrganization | CreateInviteToSpace | CreateInviteToCollection;
|
|
3512
|
-
|
|
3513
|
-
|
|
3514
|
-
role: MemberRoleOrGuest;
|
|
3515
|
-
}
|
|
3516
|
-
export interface InviteToSpace {
|
|
3517
|
-
/** The level of the member in the target space */
|
|
3518
|
-
level: MemberRoleOrGuest;
|
|
3519
|
-
/** The space the member has been invited to */
|
|
3520
|
-
space: Space;
|
|
3521
|
-
}
|
|
3522
|
-
export interface InviteToCollection {
|
|
3523
|
-
/** The level of the member in the target collection */
|
|
3524
|
-
level: MemberRoleOrGuest;
|
|
3525
|
-
/** The collection the member has been invited to */
|
|
3526
|
-
collection: Collection;
|
|
3527
|
-
}
|
|
3528
|
-
export type OrganizationInvite = {
|
|
3529
|
-
/** Type of Object, always equals to "invite" */
|
|
3530
|
-
object: 'invite';
|
|
3531
|
-
/** Unique identifier for the organization invite */
|
|
3532
|
-
id: string;
|
|
3533
|
-
} & (InviteToOrganization | InviteToSpace | InviteToCollection);
|
|
3602
|
+
/** An invite link created in an organization */
|
|
3603
|
+
export type OrganizationInviteLink = InviteLinkToOrganization | InviteLinkToSpace | InviteLinkToCollection;
|
|
3534
3604
|
export interface BillingPortal {
|
|
3535
3605
|
/** URL to the billing portal for an organization */
|
|
3536
3606
|
url: string;
|
|
@@ -4436,13 +4506,12 @@ export type BackOfficeSite = Site & {
|
|
|
4436
4506
|
/** ID of the organization owning this site */
|
|
4437
4507
|
organization: string;
|
|
4438
4508
|
};
|
|
4439
|
-
|
|
4440
|
-
|
|
4441
|
-
target: 'application' | 'content' | 'external';
|
|
4442
|
-
redirect: URL;
|
|
4443
|
-
} | {
|
|
4509
|
+
/** Site Content */
|
|
4510
|
+
export interface PublishedSiteContent {
|
|
4444
4511
|
/** ID of the site matching. */
|
|
4445
4512
|
site: string;
|
|
4513
|
+
/** ID of the site-section matching. */
|
|
4514
|
+
siteSection?: string;
|
|
4446
4515
|
/** ID of the site-space matching. */
|
|
4447
4516
|
siteSpace: string;
|
|
4448
4517
|
/** ID of the space matching. */
|
|
@@ -4463,7 +4532,12 @@ export type PublishedSiteContentLookup = {
|
|
|
4463
4532
|
shareKey?: string;
|
|
4464
4533
|
/** Whether the resolved site URL is complete and at it's terminal point, meaning no more site path segments can be further expected before any page path segments. */
|
|
4465
4534
|
complete: boolean;
|
|
4466
|
-
}
|
|
4535
|
+
}
|
|
4536
|
+
export type PublishedSiteContentLookup = {
|
|
4537
|
+
/** Type of target for the redirect */
|
|
4538
|
+
target: 'application' | 'content' | 'external';
|
|
4539
|
+
redirect: URL;
|
|
4540
|
+
} | PublishedSiteContent;
|
|
4467
4541
|
export interface UpdateContentPublishingAuth {
|
|
4468
4542
|
/**
|
|
4469
4543
|
* A fallback URL that will be used if authentication fails.
|
|
@@ -4491,7 +4565,7 @@ export interface ContentPublishingAuth {
|
|
|
4491
4565
|
*/
|
|
4492
4566
|
fallbackURL?: string;
|
|
4493
4567
|
}
|
|
4494
|
-
export type DocumentBlock = DocumentBlockParagraph | DocumentBlockHeading | DocumentBlockListOrdered | DocumentBlockListUnordered | DocumentBlockListTasks | DocumentBlockListItem | DocumentBlockDivider | DocumentBlockQuote | DocumentBlockHint | DocumentBlockImages | DocumentBlockImage | DocumentBlockFile | DocumentBlockDrawing | DocumentBlockEmbed | DocumentBlockCode | DocumentBlockCodeLine | DocumentBlockMath | DocumentBlockExpandable | DocumentBlockTabs | DocumentBlockTabsItem | DocumentBlockTable | DocumentBlockSwagger | DocumentBlockContentRef | DocumentBlockIntegration | DocumentBlockSyncedBlock;
|
|
4568
|
+
export type DocumentBlock = DocumentBlockParagraph | DocumentBlockHeading | DocumentBlockListOrdered | DocumentBlockListUnordered | DocumentBlockListTasks | DocumentBlockListItem | DocumentBlockDivider | DocumentBlockQuote | DocumentBlockHint | DocumentBlockImages | DocumentBlockImage | DocumentBlockFile | DocumentBlockDrawing | DocumentBlockEmbed | DocumentBlockCode | DocumentBlockCodeLine | DocumentBlockMath | DocumentBlockExpandable | DocumentBlockTabs | DocumentBlockTabsItem | DocumentBlockTable | DocumentBlockSwagger | DocumentBlockContentRef | DocumentBlockIntegration | DocumentBlockSyncedBlock | DocumentBlockReusableContent;
|
|
4495
4569
|
export type InputPageBase = {
|
|
4496
4570
|
/**
|
|
4497
4571
|
* Optional unique identifier for the page.
|
|
@@ -4739,6 +4813,10 @@ export interface OrganizationInfoChannel {
|
|
|
4739
4813
|
channel: 'organization';
|
|
4740
4814
|
organization: string;
|
|
4741
4815
|
}
|
|
4816
|
+
export interface OrganizationInviteLinksChannel {
|
|
4817
|
+
channel: 'organization-link-invites';
|
|
4818
|
+
organization: string;
|
|
4819
|
+
}
|
|
4742
4820
|
export interface OrganizationMembersChannel {
|
|
4743
4821
|
channel: 'organization-members';
|
|
4744
4822
|
organization: string;
|
|
@@ -4924,7 +5002,7 @@ export interface CustomHostnameChannel {
|
|
|
4924
5002
|
customHostname: string;
|
|
4925
5003
|
}
|
|
4926
5004
|
/** Channel to subscribe to for API updates. */
|
|
4927
|
-
export type SubscriptionChannel = SpaceInfoChannel | SpaceGitInfoChannel | SpacePublishingAuthChannel | SpacePublishingCustomizationChannel | SpaceCustomFieldsChannel | SpaceBrokenLinksChannel | BackofficeUserInfoChannel | SpaceIntegrationsChannel | OrganizationCustomFieldsChannel | UserAPITokensChannel | UserOrganizationsChannel | UserProfileChannel | ChangeRequestChannel | ChangeRequestsChannel | ChangeRequestReviewsChannel | ChangeRequestBrokenLinksChannel | CollectionChannel | CollectionPublishingCustomizationChannel | OrganizationInfoChannel | OrganizationMembersChannel | OrganizationMemberChannel | OrganizationSAMLChannel | OrganizationTeamsChannel | OrganizationTeamChannel | OrganizationTeamMembersChannel | OrganizationTeamMemberChannel | OrganizationSpacesChannel | OrganizationCollectionsChannel | OrganizationCapturesChannel | OrganizationIntegrationsChannel | OrganizationInstallationsChannel | OrganizationSitesChannel | OrganizationExperimentalFeaturesChannel | OrganizationSyncedBlocksChannel | OrganizationSyncedBlockChannel | CommentsChannel | CommentInfoChannel | CommentReplyInfoChannel | CommentRepliesChannel | IntegrationChannel | IntegrationInstallationChannel | IntegrationSpaceInstallationChannel | IntegrationSpaceInstallationsChannel | IntegrationSiteInstallationChannel | IntegrationSiteInstallationsChannel | SiteChannel | SiteCustomizationChannel | SiteIntegrationsChannel | SiteSpaceChannel | SiteSpaceCustomizationChannel | SiteSpacesChannel | SitePublishingAuthChannel | SiteShareLinksChannel | SiteShareLinkChannel | SiteSectionsChannel | SiteSectionChannel | CustomHostnameChannel;
|
|
5005
|
+
export type SubscriptionChannel = SpaceInfoChannel | SpaceGitInfoChannel | SpacePublishingAuthChannel | SpacePublishingCustomizationChannel | SpaceCustomFieldsChannel | SpaceBrokenLinksChannel | BackofficeUserInfoChannel | SpaceIntegrationsChannel | OrganizationCustomFieldsChannel | UserAPITokensChannel | UserOrganizationsChannel | UserProfileChannel | ChangeRequestChannel | ChangeRequestsChannel | ChangeRequestReviewsChannel | ChangeRequestBrokenLinksChannel | CollectionChannel | CollectionPublishingCustomizationChannel | OrganizationInfoChannel | OrganizationInviteLinksChannel | OrganizationMembersChannel | OrganizationMemberChannel | OrganizationSAMLChannel | OrganizationTeamsChannel | OrganizationTeamChannel | OrganizationTeamMembersChannel | OrganizationTeamMemberChannel | OrganizationSpacesChannel | OrganizationCollectionsChannel | OrganizationCapturesChannel | OrganizationIntegrationsChannel | OrganizationInstallationsChannel | OrganizationSitesChannel | OrganizationExperimentalFeaturesChannel | OrganizationSyncedBlocksChannel | OrganizationSyncedBlockChannel | CommentsChannel | CommentInfoChannel | CommentReplyInfoChannel | CommentRepliesChannel | IntegrationChannel | IntegrationInstallationChannel | IntegrationSpaceInstallationChannel | IntegrationSpaceInstallationsChannel | IntegrationSiteInstallationChannel | IntegrationSiteInstallationsChannel | SiteChannel | SiteCustomizationChannel | SiteIntegrationsChannel | SiteSpaceChannel | SiteSpaceCustomizationChannel | SiteSpacesChannel | SitePublishingAuthChannel | SiteShareLinksChannel | SiteShareLinkChannel | SiteSectionsChannel | SiteSectionChannel | CustomHostnameChannel;
|
|
4928
5006
|
/** The status of ads on the site */
|
|
4929
5007
|
export declare enum SiteAdsStatus {
|
|
4930
5008
|
Pending = "pending",
|
|
@@ -5743,18 +5821,34 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
5743
5821
|
/**
|
|
5744
5822
|
* No description
|
|
5745
5823
|
*
|
|
5746
|
-
* @name
|
|
5824
|
+
* @name GetComputedDocument
|
|
5747
5825
|
* @summary Get the document for a page in a computed content.
|
|
5748
|
-
* @request
|
|
5826
|
+
* @request GET:/spaces/{spaceId}/content/computed/document
|
|
5749
5827
|
* @secure
|
|
5750
5828
|
*/
|
|
5751
|
-
|
|
5752
|
-
/** Parameters for a computed content */
|
|
5753
|
-
source: ComputedContentSource;
|
|
5754
|
-
}, query?: {
|
|
5829
|
+
getComputedDocument: (spaceId: string, query: {
|
|
5755
5830
|
/** Output format for the content. */
|
|
5756
5831
|
format?: "document" | "markdown";
|
|
5832
|
+
/** LZ-string compressed JSON request */
|
|
5833
|
+
request: string;
|
|
5757
5834
|
}, params?: RequestParams) => Promise<HttpResponse<Document, Error>>;
|
|
5835
|
+
/**
|
|
5836
|
+
* No description
|
|
5837
|
+
*
|
|
5838
|
+
* @name GetComputedPage
|
|
5839
|
+
* @summary Get the computed pages for a page in a computed content.
|
|
5840
|
+
* @request GET:/spaces/{spaceId}/content/computed/page
|
|
5841
|
+
* @secure
|
|
5842
|
+
*/
|
|
5843
|
+
getComputedPage: (spaceId: string, query: {
|
|
5844
|
+
/** Output format for the content. */
|
|
5845
|
+
format?: "document" | "markdown";
|
|
5846
|
+
/** LZ-string compressed JSON request */
|
|
5847
|
+
request: string;
|
|
5848
|
+
}, params?: RequestParams) => Promise<HttpResponse<{
|
|
5849
|
+
pages: RevisionPage[];
|
|
5850
|
+
files: RevisionFile[];
|
|
5851
|
+
}, Error>>;
|
|
5758
5852
|
/**
|
|
5759
5853
|
* No description
|
|
5760
5854
|
*
|
|
@@ -8040,6 +8134,52 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8040
8134
|
* @secure
|
|
8041
8135
|
*/
|
|
8042
8136
|
joinOrganizationWithInvite: (organizationId: string, inviteId: string, params?: RequestParams) => Promise<HttpResponse<object, Error>>;
|
|
8137
|
+
/**
|
|
8138
|
+
* No description
|
|
8139
|
+
*
|
|
8140
|
+
* @tags organizations
|
|
8141
|
+
* @name ListOrganizationContentInviteLinks
|
|
8142
|
+
* @summary List invite links to content in an organization
|
|
8143
|
+
* @request GET:/orgs/{organizationId}/content-link-invites
|
|
8144
|
+
* @secure
|
|
8145
|
+
*/
|
|
8146
|
+
listOrganizationContentInviteLinks: (organizationId: string, query?: {
|
|
8147
|
+
/** Identifier of the page results to fetch. */
|
|
8148
|
+
page?: string;
|
|
8149
|
+
/**
|
|
8150
|
+
* The number of results per page
|
|
8151
|
+
* @min 0
|
|
8152
|
+
* @max 1000
|
|
8153
|
+
*/
|
|
8154
|
+
limit?: number;
|
|
8155
|
+
/** If specified, only return invite links that provide specific permissions on the given space. */
|
|
8156
|
+
space?: string;
|
|
8157
|
+
/** If specified, only return invite links that provide permissions on the given collection. */
|
|
8158
|
+
collection?: string;
|
|
8159
|
+
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
8160
|
+
items: (InviteLinkToCollection | InviteLinkToSpace)[];
|
|
8161
|
+
}, Error>>;
|
|
8162
|
+
/**
|
|
8163
|
+
* No description
|
|
8164
|
+
*
|
|
8165
|
+
* @tags organizations
|
|
8166
|
+
* @name ListOrganizationInviteLinks
|
|
8167
|
+
* @summary List invite links to an organization
|
|
8168
|
+
* @request GET:/orgs/{organizationId}/link-invites
|
|
8169
|
+
* @secure
|
|
8170
|
+
*/
|
|
8171
|
+
listOrganizationInviteLinks: (organizationId: string, query?: {
|
|
8172
|
+
/** Identifier of the page results to fetch. */
|
|
8173
|
+
page?: string;
|
|
8174
|
+
/**
|
|
8175
|
+
* The number of results per page
|
|
8176
|
+
* @min 0
|
|
8177
|
+
* @max 1000
|
|
8178
|
+
*/
|
|
8179
|
+
limit?: number;
|
|
8180
|
+
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
8181
|
+
items: InviteLinkToOrganization[];
|
|
8182
|
+
}, Error>>;
|
|
8043
8183
|
/**
|
|
8044
8184
|
* No description
|
|
8045
8185
|
*
|
|
@@ -8049,7 +8189,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8049
8189
|
* @request POST:/orgs/{organizationId}/link-invites
|
|
8050
8190
|
* @secure
|
|
8051
8191
|
*/
|
|
8052
|
-
createOrganizationInvite: (organizationId: string, data: CreateOrganizationInvite, params?: RequestParams) => Promise<HttpResponse<
|
|
8192
|
+
createOrganizationInvite: (organizationId: string, data: CreateOrganizationInvite, params?: RequestParams) => Promise<HttpResponse<OrganizationInviteLink, Error>>;
|
|
8053
8193
|
/**
|
|
8054
8194
|
* No description
|
|
8055
8195
|
*
|
|
@@ -8065,7 +8205,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8065
8205
|
} | {
|
|
8066
8206
|
/** The role of a member in an organization, null for guests */
|
|
8067
8207
|
level: MemberRoleOrGuest;
|
|
8068
|
-
}, params?: RequestParams) => Promise<HttpResponse<
|
|
8208
|
+
}, params?: RequestParams) => Promise<HttpResponse<OrganizationInviteLink, Error>>;
|
|
8069
8209
|
/**
|
|
8070
8210
|
* No description
|
|
8071
8211
|
*
|
|
@@ -8172,8 +8312,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8172
8312
|
* @max 1000
|
|
8173
8313
|
*/
|
|
8174
8314
|
limit?: number;
|
|
8175
|
-
/** If defined, only content with this visibility will be returned. */
|
|
8176
|
-
visibility?: ContentVisibility;
|
|
8177
8315
|
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
8178
8316
|
items: Space[];
|
|
8179
8317
|
}, Error>>;
|
package/dist/index.cjs
CHANGED
|
@@ -242,7 +242,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
242
242
|
|
|
243
243
|
// package.json
|
|
244
244
|
var name = "@gitbook/api";
|
|
245
|
-
var version = "0.
|
|
245
|
+
var version = "0.68.0";
|
|
246
246
|
|
|
247
247
|
// src/client.ts
|
|
248
248
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -460,8 +460,10 @@ var OrganizationCommunityType = /* @__PURE__ */ ((OrganizationCommunityType2) =>
|
|
|
460
460
|
return OrganizationCommunityType2;
|
|
461
461
|
})(OrganizationCommunityType || {});
|
|
462
462
|
var IntegrationTarget = /* @__PURE__ */ ((IntegrationTarget2) => {
|
|
463
|
-
IntegrationTarget2["Organization"] = "organization";
|
|
464
463
|
IntegrationTarget2["All"] = "all";
|
|
464
|
+
IntegrationTarget2["Site"] = "site";
|
|
465
|
+
IntegrationTarget2["Space"] = "space";
|
|
466
|
+
IntegrationTarget2["Organization"] = "organization";
|
|
465
467
|
return IntegrationTarget2;
|
|
466
468
|
})(IntegrationTarget || {});
|
|
467
469
|
var IntegrationVisibility = /* @__PURE__ */ ((IntegrationVisibility2) => {
|
|
@@ -805,9 +807,7 @@ var HttpClient = class {
|
|
|
805
807
|
};
|
|
806
808
|
encodeQueryParam(key, value) {
|
|
807
809
|
const encodedKey = encodeURIComponent(key);
|
|
808
|
-
return `${encodedKey}=${encodeURIComponent(
|
|
809
|
-
typeof value === "number" ? value : `${value}`
|
|
810
|
-
)}`;
|
|
810
|
+
return `${encodedKey}=${encodeURIComponent(typeof value === "number" ? value : `${value}`)}`;
|
|
811
811
|
}
|
|
812
812
|
addQueryParam(query, key) {
|
|
813
813
|
return this.encodeQueryParam(key, query[key]);
|
|
@@ -1315,13 +1315,19 @@ var Api = class extends HttpClient {
|
|
|
1315
1315
|
format: "json",
|
|
1316
1316
|
...params
|
|
1317
1317
|
}),
|
|
1318
|
-
|
|
1318
|
+
getComputedDocument: (spaceId, query, params = {}) => this.request({
|
|
1319
1319
|
path: `/spaces/${spaceId}/content/computed/document`,
|
|
1320
|
-
method: "
|
|
1320
|
+
method: "GET",
|
|
1321
|
+
query,
|
|
1322
|
+
secure: true,
|
|
1323
|
+
format: "json",
|
|
1324
|
+
...params
|
|
1325
|
+
}),
|
|
1326
|
+
getComputedPage: (spaceId, query, params = {}) => this.request({
|
|
1327
|
+
path: `/spaces/${spaceId}/content/computed/page`,
|
|
1328
|
+
method: "GET",
|
|
1321
1329
|
query,
|
|
1322
|
-
body: data,
|
|
1323
1330
|
secure: true,
|
|
1324
|
-
type: "application/json" /* Json */,
|
|
1325
1331
|
format: "json",
|
|
1326
1332
|
...params
|
|
1327
1333
|
}),
|
|
@@ -2378,6 +2384,22 @@ var Api = class extends HttpClient {
|
|
|
2378
2384
|
format: "json",
|
|
2379
2385
|
...params
|
|
2380
2386
|
}),
|
|
2387
|
+
listOrganizationContentInviteLinks: (organizationId, query, params = {}) => this.request({
|
|
2388
|
+
path: `/orgs/${organizationId}/content-link-invites`,
|
|
2389
|
+
method: "GET",
|
|
2390
|
+
query,
|
|
2391
|
+
secure: true,
|
|
2392
|
+
format: "json",
|
|
2393
|
+
...params
|
|
2394
|
+
}),
|
|
2395
|
+
listOrganizationInviteLinks: (organizationId, query, params = {}) => this.request({
|
|
2396
|
+
path: `/orgs/${organizationId}/link-invites`,
|
|
2397
|
+
method: "GET",
|
|
2398
|
+
query,
|
|
2399
|
+
secure: true,
|
|
2400
|
+
format: "json",
|
|
2401
|
+
...params
|
|
2402
|
+
}),
|
|
2381
2403
|
createOrganizationInvite: (organizationId, data, params = {}) => this.request({
|
|
2382
2404
|
path: `/orgs/${organizationId}/link-invites`,
|
|
2383
2405
|
method: "POST",
|
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.68.0";
|
|
176
176
|
|
|
177
177
|
// src/client.ts
|
|
178
178
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -390,8 +390,10 @@ var OrganizationCommunityType = /* @__PURE__ */ ((OrganizationCommunityType2) =>
|
|
|
390
390
|
return OrganizationCommunityType2;
|
|
391
391
|
})(OrganizationCommunityType || {});
|
|
392
392
|
var IntegrationTarget = /* @__PURE__ */ ((IntegrationTarget2) => {
|
|
393
|
-
IntegrationTarget2["Organization"] = "organization";
|
|
394
393
|
IntegrationTarget2["All"] = "all";
|
|
394
|
+
IntegrationTarget2["Site"] = "site";
|
|
395
|
+
IntegrationTarget2["Space"] = "space";
|
|
396
|
+
IntegrationTarget2["Organization"] = "organization";
|
|
395
397
|
return IntegrationTarget2;
|
|
396
398
|
})(IntegrationTarget || {});
|
|
397
399
|
var IntegrationVisibility = /* @__PURE__ */ ((IntegrationVisibility2) => {
|
|
@@ -735,9 +737,7 @@ var HttpClient = class {
|
|
|
735
737
|
};
|
|
736
738
|
encodeQueryParam(key, value) {
|
|
737
739
|
const encodedKey = encodeURIComponent(key);
|
|
738
|
-
return `${encodedKey}=${encodeURIComponent(
|
|
739
|
-
typeof value === "number" ? value : `${value}`
|
|
740
|
-
)}`;
|
|
740
|
+
return `${encodedKey}=${encodeURIComponent(typeof value === "number" ? value : `${value}`)}`;
|
|
741
741
|
}
|
|
742
742
|
addQueryParam(query, key) {
|
|
743
743
|
return this.encodeQueryParam(key, query[key]);
|
|
@@ -1245,13 +1245,19 @@ var Api = class extends HttpClient {
|
|
|
1245
1245
|
format: "json",
|
|
1246
1246
|
...params
|
|
1247
1247
|
}),
|
|
1248
|
-
|
|
1248
|
+
getComputedDocument: (spaceId, query, params = {}) => this.request({
|
|
1249
1249
|
path: `/spaces/${spaceId}/content/computed/document`,
|
|
1250
|
-
method: "
|
|
1250
|
+
method: "GET",
|
|
1251
|
+
query,
|
|
1252
|
+
secure: true,
|
|
1253
|
+
format: "json",
|
|
1254
|
+
...params
|
|
1255
|
+
}),
|
|
1256
|
+
getComputedPage: (spaceId, query, params = {}) => this.request({
|
|
1257
|
+
path: `/spaces/${spaceId}/content/computed/page`,
|
|
1258
|
+
method: "GET",
|
|
1251
1259
|
query,
|
|
1252
|
-
body: data,
|
|
1253
1260
|
secure: true,
|
|
1254
|
-
type: "application/json" /* Json */,
|
|
1255
1261
|
format: "json",
|
|
1256
1262
|
...params
|
|
1257
1263
|
}),
|
|
@@ -2308,6 +2314,22 @@ var Api = class extends HttpClient {
|
|
|
2308
2314
|
format: "json",
|
|
2309
2315
|
...params
|
|
2310
2316
|
}),
|
|
2317
|
+
listOrganizationContentInviteLinks: (organizationId, query, params = {}) => this.request({
|
|
2318
|
+
path: `/orgs/${organizationId}/content-link-invites`,
|
|
2319
|
+
method: "GET",
|
|
2320
|
+
query,
|
|
2321
|
+
secure: true,
|
|
2322
|
+
format: "json",
|
|
2323
|
+
...params
|
|
2324
|
+
}),
|
|
2325
|
+
listOrganizationInviteLinks: (organizationId, query, params = {}) => this.request({
|
|
2326
|
+
path: `/orgs/${organizationId}/link-invites`,
|
|
2327
|
+
method: "GET",
|
|
2328
|
+
query,
|
|
2329
|
+
secure: true,
|
|
2330
|
+
format: "json",
|
|
2331
|
+
...params
|
|
2332
|
+
}),
|
|
2311
2333
|
createOrganizationInvite: (organizationId, data, params = {}) => this.request({
|
|
2312
2334
|
path: `/orgs/${organizationId}/link-invites`,
|
|
2313
2335
|
method: "POST",
|