@gitbook/api 0.160.1 → 0.161.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 +291 -33
- package/dist/index.cjs +59 -1
- package/dist/index.js +59 -1
- package/package.json +1 -1
- package/spec/openapi.json +686 -75
- package/spec/openapi.yaml +422 -65
package/dist/client.d.ts
CHANGED
|
@@ -302,6 +302,8 @@ export interface Space {
|
|
|
302
302
|
changeRequestsDraft: number;
|
|
303
303
|
/** Whether the space is powered by V2 of the content system. */
|
|
304
304
|
internal_poweredByV2?: boolean;
|
|
305
|
+
/** Whether the space uses a single websocket connection for all real-time communication. */
|
|
306
|
+
internal_singleWebsocket?: boolean;
|
|
305
307
|
/** The set of permissions for the space */
|
|
306
308
|
permissions: {
|
|
307
309
|
/** Can the user view the space content. */
|
|
@@ -814,6 +816,8 @@ export interface DocumentBlockHint {
|
|
|
814
816
|
key?: string;
|
|
815
817
|
data: {
|
|
816
818
|
style: 'info' | 'warning' | 'danger' | 'success';
|
|
819
|
+
/** Name of the icon */
|
|
820
|
+
icon?: Icon;
|
|
817
821
|
};
|
|
818
822
|
nodes: DocumentBlocksEssentials[];
|
|
819
823
|
isVoid?: false;
|
|
@@ -1439,7 +1443,7 @@ export type RevisionPageDocument = RevisionPageBase & Document & {
|
|
|
1439
1443
|
/** Meta links associated with the page. */
|
|
1440
1444
|
metaLinks?: RevisionPageMetaLinks;
|
|
1441
1445
|
/** A list of all the tags added to this page */
|
|
1442
|
-
tags
|
|
1446
|
+
tags: RevisionPageTag[];
|
|
1443
1447
|
} & ({
|
|
1444
1448
|
computed: ComputedContentSourceDocument;
|
|
1445
1449
|
/** Seed to use for the generation of IDs. */
|
|
@@ -1601,6 +1605,8 @@ export interface RevisionPageLayoutOptions {
|
|
|
1601
1605
|
pagination: boolean;
|
|
1602
1606
|
/** Should the page metadata (last modified, author, etc.) be visible? */
|
|
1603
1607
|
metadata: boolean;
|
|
1608
|
+
/** Should the tags be visible on the page? */
|
|
1609
|
+
tags: boolean;
|
|
1604
1610
|
}
|
|
1605
1611
|
export interface RevisionPageDocumentCover {
|
|
1606
1612
|
/** Content reference pointing to the source image. */
|
|
@@ -1733,7 +1739,7 @@ export interface RevisionBase {
|
|
|
1733
1739
|
files: RevisionFile[];
|
|
1734
1740
|
reusableContents: RevisionReusableContent[];
|
|
1735
1741
|
/** List of available tags within this revision */
|
|
1736
|
-
tags
|
|
1742
|
+
tags: RevisionTag[];
|
|
1737
1743
|
variables?: Variables;
|
|
1738
1744
|
/** When the revision was created. */
|
|
1739
1745
|
createdAt: Timestamp;
|
|
@@ -4636,7 +4642,7 @@ export interface SearchAIQuery {
|
|
|
4636
4642
|
* Page source
|
|
4637
4643
|
* The source points to a page in a space.
|
|
4638
4644
|
*/
|
|
4639
|
-
export interface
|
|
4645
|
+
export interface SearchAIAnswerSourcePage {
|
|
4640
4646
|
type: 'page';
|
|
4641
4647
|
/** Short explanation of how the source was used to answer. */
|
|
4642
4648
|
reason?: string;
|
|
@@ -4649,6 +4655,27 @@ export interface SearchAIAnswerSource {
|
|
|
4649
4655
|
/** The IDs of the sections of the page that were used to answer the question. */
|
|
4650
4656
|
sections: string[];
|
|
4651
4657
|
}
|
|
4658
|
+
/**
|
|
4659
|
+
* Site context record source
|
|
4660
|
+
* The source points to an ingested site context record.
|
|
4661
|
+
*/
|
|
4662
|
+
export interface SearchAIAnswerSourceRecord {
|
|
4663
|
+
type: 'record';
|
|
4664
|
+
/** Short explanation of how the source was used to answer. */
|
|
4665
|
+
reason?: string;
|
|
4666
|
+
/** The context record ID of the source. */
|
|
4667
|
+
record: string;
|
|
4668
|
+
/** The site ID owning the source record. */
|
|
4669
|
+
site: string;
|
|
4670
|
+
/** The title of the source record. */
|
|
4671
|
+
title: string;
|
|
4672
|
+
/**
|
|
4673
|
+
* The source URL of the context record.
|
|
4674
|
+
* @format uri
|
|
4675
|
+
*/
|
|
4676
|
+
url: string;
|
|
4677
|
+
}
|
|
4678
|
+
export type SearchAIAnswerSource = SearchAIAnswerSourcePage | SearchAIAnswerSourceRecord;
|
|
4652
4679
|
/** Answer from AI for a question asked on a content. */
|
|
4653
4680
|
export interface SearchAIAnswer {
|
|
4654
4681
|
answer?: Document;
|
|
@@ -5742,7 +5769,7 @@ export declare enum ContextRecordType {
|
|
|
5742
5769
|
Document = "document"
|
|
5743
5770
|
}
|
|
5744
5771
|
/** Integration source */
|
|
5745
|
-
export type ContextConnector = string | 'builtin:email' | 'builtin:api' | 'builtin:website';
|
|
5772
|
+
export type ContextConnector = string | 'builtin:email' | 'builtin:api' | 'builtin:website' | 'builtin:youtube';
|
|
5746
5773
|
/**
|
|
5747
5774
|
* Title for the context record
|
|
5748
5775
|
* @minLength 1
|
|
@@ -5832,6 +5859,12 @@ export type ContextConnectorSetup = {
|
|
|
5832
5859
|
/** @format uri */
|
|
5833
5860
|
url: string;
|
|
5834
5861
|
};
|
|
5862
|
+
} | {
|
|
5863
|
+
connector: 'builtin:youtube';
|
|
5864
|
+
setupSettings: {
|
|
5865
|
+
/** @pattern ^UC[A-Za-z0-9_-]{22}$ */
|
|
5866
|
+
channelId: string;
|
|
5867
|
+
};
|
|
5835
5868
|
};
|
|
5836
5869
|
export type ContextConnection = {
|
|
5837
5870
|
object: 'context-connection';
|
|
@@ -5931,6 +5964,16 @@ export interface SiteSpaceMovePosition {
|
|
|
5931
5964
|
before?: SiteSpacePointer;
|
|
5932
5965
|
after?: SiteSpacePointer;
|
|
5933
5966
|
}
|
|
5967
|
+
export type InviteSiteUsersAndTeams = ({
|
|
5968
|
+
/** @minItems 1 */
|
|
5969
|
+
teams: string[];
|
|
5970
|
+
} | {
|
|
5971
|
+
/** @minItems 1 */
|
|
5972
|
+
users: string[];
|
|
5973
|
+
}) & {
|
|
5974
|
+
/** Role to set. */
|
|
5975
|
+
role: MemberRole;
|
|
5976
|
+
};
|
|
5934
5977
|
export interface OrganizationPointer {
|
|
5935
5978
|
type: 'organization';
|
|
5936
5979
|
/** Unique identifier for the organization */
|
|
@@ -5944,6 +5987,34 @@ export interface UserSitePermission {
|
|
|
5944
5987
|
/** The content or organization that enforced this permission level. */
|
|
5945
5988
|
origin: SpacePointer | OrganizationPointer;
|
|
5946
5989
|
}
|
|
5990
|
+
/** Permission override of a user in a site. */
|
|
5991
|
+
export interface UserSitePermissionOverride {
|
|
5992
|
+
/**
|
|
5993
|
+
* "The role of a member in an organization.
|
|
5994
|
+
* "admin": Can administrate the content: create, delete spaces, ...
|
|
5995
|
+
* "create": Can create content.
|
|
5996
|
+
* "review": Can review content.
|
|
5997
|
+
* "edit": Can edit the content (live or change requests).
|
|
5998
|
+
* "comment": Can access the content and its discussions.
|
|
5999
|
+
* "read": Can access the content, but cannot update it in any way.
|
|
6000
|
+
*/
|
|
6001
|
+
permission: MemberRole;
|
|
6002
|
+
user: User;
|
|
6003
|
+
}
|
|
6004
|
+
/** Permission override of a team in a site. */
|
|
6005
|
+
export interface TeamSitePermissionOverride {
|
|
6006
|
+
/**
|
|
6007
|
+
* "The role of a member in an organization.
|
|
6008
|
+
* "admin": Can administrate the content: create, delete spaces, ...
|
|
6009
|
+
* "create": Can create content.
|
|
6010
|
+
* "review": Can review content.
|
|
6011
|
+
* "edit": Can edit the content (live or change requests).
|
|
6012
|
+
* "comment": Can access the content and its discussions.
|
|
6013
|
+
* "read": Can access the content, but cannot update it in any way.
|
|
6014
|
+
*/
|
|
6015
|
+
permission: MemberRole;
|
|
6016
|
+
team: OrganizationTeam;
|
|
6017
|
+
}
|
|
5947
6018
|
/** Context about the current user sending a message. */
|
|
5948
6019
|
export interface AIMessageContext {
|
|
5949
6020
|
location?: {
|
|
@@ -6106,8 +6177,12 @@ export interface AIToolCallGetReusableContents {
|
|
|
6106
6177
|
/** The revision ID of the space. */
|
|
6107
6178
|
revisionId: string;
|
|
6108
6179
|
}
|
|
6109
|
-
/**
|
|
6110
|
-
|
|
6180
|
+
/**
|
|
6181
|
+
* Page result
|
|
6182
|
+
* Result of a search matching a page.
|
|
6183
|
+
*/
|
|
6184
|
+
export interface AIToolCallSearchResultPage {
|
|
6185
|
+
type: 'page';
|
|
6111
6186
|
/** The ID of the space */
|
|
6112
6187
|
spaceId: string;
|
|
6113
6188
|
/** The ID of the page */
|
|
@@ -6121,6 +6196,28 @@ export interface AIToolCallSearchResult {
|
|
|
6121
6196
|
/** The description of the result */
|
|
6122
6197
|
description?: string;
|
|
6123
6198
|
}
|
|
6199
|
+
/**
|
|
6200
|
+
* Site context record result
|
|
6201
|
+
* Result of a search matching a site context record.
|
|
6202
|
+
*/
|
|
6203
|
+
export interface AIToolCallSearchResultRecord {
|
|
6204
|
+
type: 'record';
|
|
6205
|
+
/** The ID of the site owning the context record */
|
|
6206
|
+
siteId: string;
|
|
6207
|
+
/** The ID of the context record */
|
|
6208
|
+
recordId: string;
|
|
6209
|
+
/** The title of the record */
|
|
6210
|
+
title: string;
|
|
6211
|
+
/** The description of the record */
|
|
6212
|
+
description?: string;
|
|
6213
|
+
/**
|
|
6214
|
+
* URL of the record in its original source
|
|
6215
|
+
* @format uri
|
|
6216
|
+
*/
|
|
6217
|
+
url?: string;
|
|
6218
|
+
}
|
|
6219
|
+
/** Result of a search */
|
|
6220
|
+
export type AIToolCallSearchResult = AIToolCallSearchResultPage | AIToolCallSearchResultRecord;
|
|
6124
6221
|
/** Tool to search for content */
|
|
6125
6222
|
export interface AIToolCallSearch {
|
|
6126
6223
|
tool: 'search';
|
|
@@ -7088,6 +7185,17 @@ export type BackOfficeSite = Site & {
|
|
|
7088
7185
|
/** ID of the organization owning this site */
|
|
7089
7186
|
organization: string;
|
|
7090
7187
|
};
|
|
7188
|
+
export type PublishedContentRedirect = {
|
|
7189
|
+
/** Type of target for the redirect */
|
|
7190
|
+
target: 'application' | 'content';
|
|
7191
|
+
redirect: URL;
|
|
7192
|
+
} | {
|
|
7193
|
+
/** Type of target for the redirect */
|
|
7194
|
+
target: 'external';
|
|
7195
|
+
/** ID of the resolved site. */
|
|
7196
|
+
site: string;
|
|
7197
|
+
redirect: URL;
|
|
7198
|
+
};
|
|
7091
7199
|
/** Site Content */
|
|
7092
7200
|
export interface PublishedSiteContent {
|
|
7093
7201
|
/** ID of the site matching. */
|
|
@@ -7121,11 +7229,7 @@ export interface PublishedSiteContent {
|
|
|
7121
7229
|
/** The canonical URL of the resolution. */
|
|
7122
7230
|
canonicalUrl: string;
|
|
7123
7231
|
}
|
|
7124
|
-
export type PublishedSiteContentLookup =
|
|
7125
|
-
/** Type of target for the redirect */
|
|
7126
|
-
target: 'application' | 'content' | 'external';
|
|
7127
|
-
redirect: URL;
|
|
7128
|
-
} | PublishedSiteContent;
|
|
7232
|
+
export type PublishedSiteContentLookup = PublishedContentRedirect | PublishedSiteContent;
|
|
7129
7233
|
/** An object that describes the payload of site visitor info. It can include a jwt token with signed claims and/or a record of its unsigned claims. */
|
|
7130
7234
|
export interface SiteVisitorPayload {
|
|
7131
7235
|
/** JWT token generated for a authenticated access session. */
|
|
@@ -8340,7 +8444,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8340
8444
|
/**
|
|
8341
8445
|
* No description
|
|
8342
8446
|
*
|
|
8343
|
-
* @tags space-
|
|
8447
|
+
* @tags space-permissions
|
|
8344
8448
|
* @name InviteToSpace
|
|
8345
8449
|
* @summary Invite a user or a team to a space
|
|
8346
8450
|
* @request POST:/spaces/{spaceId}/permissions
|
|
@@ -8356,9 +8460,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8356
8460
|
/**
|
|
8357
8461
|
* No description
|
|
8358
8462
|
*
|
|
8359
|
-
* @tags space-
|
|
8463
|
+
* @tags space-permissions
|
|
8360
8464
|
* @name UpdateTeamPermissionInSpace
|
|
8361
|
-
* @summary Update
|
|
8465
|
+
* @summary Update an org team's permission in a space
|
|
8362
8466
|
* @request PATCH:/spaces/{spaceId}/permissions/teams/{teamId}
|
|
8363
8467
|
* @secure
|
|
8364
8468
|
*/
|
|
@@ -8375,9 +8479,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8375
8479
|
/**
|
|
8376
8480
|
* No description
|
|
8377
8481
|
*
|
|
8378
|
-
* @tags space-
|
|
8482
|
+
* @tags space-permissions
|
|
8379
8483
|
* @name RemoveTeamFromSpace
|
|
8380
|
-
* @summary Remove a space
|
|
8484
|
+
* @summary Remove an org team from a space
|
|
8381
8485
|
* @request DELETE:/spaces/{spaceId}/permissions/teams/{teamId}
|
|
8382
8486
|
* @secure
|
|
8383
8487
|
*/
|
|
@@ -8391,7 +8495,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8391
8495
|
/**
|
|
8392
8496
|
* No description
|
|
8393
8497
|
*
|
|
8394
|
-
* @tags space-
|
|
8498
|
+
* @tags space-permissions
|
|
8395
8499
|
* @name ListUserPermissionsInSpace
|
|
8396
8500
|
* @summary List space user permissions
|
|
8397
8501
|
* @request GET:/spaces/{spaceId}/permissions/users
|
|
@@ -8418,7 +8522,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8418
8522
|
/**
|
|
8419
8523
|
* No description
|
|
8420
8524
|
*
|
|
8421
|
-
* @tags space-
|
|
8525
|
+
* @tags space-permissions
|
|
8422
8526
|
* @name UpdateUserPermissionInSpace
|
|
8423
8527
|
* @summary Update space user permissions
|
|
8424
8528
|
* @request PATCH:/spaces/{spaceId}/permissions/users/{userId}
|
|
@@ -8437,7 +8541,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8437
8541
|
/**
|
|
8438
8542
|
* No description
|
|
8439
8543
|
*
|
|
8440
|
-
* @tags space-
|
|
8544
|
+
* @tags space-permissions
|
|
8441
8545
|
* @name RemoveUserFromSpace
|
|
8442
8546
|
* @summary Remove a space user
|
|
8443
8547
|
* @request DELETE:/spaces/{spaceId}/permissions/users/{userId}
|
|
@@ -8447,9 +8551,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
8447
8551
|
/**
|
|
8448
8552
|
* No description
|
|
8449
8553
|
*
|
|
8450
|
-
* @tags space-
|
|
8554
|
+
* @tags space-permissions
|
|
8451
8555
|
* @name ListTeamPermissionsInSpace
|
|
8452
|
-
* @summary List
|
|
8556
|
+
* @summary List an org team's permission in a space
|
|
8453
8557
|
* @request GET:/spaces/{spaceId}/permissions/teams
|
|
8454
8558
|
* @secure
|
|
8455
8559
|
*/
|
|
@@ -10027,7 +10131,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10027
10131
|
/**
|
|
10028
10132
|
* No description
|
|
10029
10133
|
*
|
|
10030
|
-
* @tags space-
|
|
10134
|
+
* @tags space-permissions
|
|
10031
10135
|
* @name ListPermissionsAggregateInSpace
|
|
10032
10136
|
* @summary List all space users permissions
|
|
10033
10137
|
* @request GET:/spaces/{spaceId}/permissions/aggregate
|
|
@@ -10258,7 +10362,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10258
10362
|
/**
|
|
10259
10363
|
* No description
|
|
10260
10364
|
*
|
|
10261
|
-
* @tags collection-
|
|
10365
|
+
* @tags collection-permissions
|
|
10262
10366
|
* @name InviteToCollection
|
|
10263
10367
|
* @summary Invite to a collection
|
|
10264
10368
|
* @request POST:/collections/{collectionId}/permissions
|
|
@@ -10274,9 +10378,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10274
10378
|
/**
|
|
10275
10379
|
* No description
|
|
10276
10380
|
*
|
|
10277
|
-
* @tags collection-
|
|
10381
|
+
* @tags collection-permissions
|
|
10278
10382
|
* @name ListTeamPermissionsInCollection
|
|
10279
|
-
* @summary List
|
|
10383
|
+
* @summary List an org team's permission in collection
|
|
10280
10384
|
* @request GET:/collections/{collectionId}/permissions/teams
|
|
10281
10385
|
* @secure
|
|
10282
10386
|
*/
|
|
@@ -10307,9 +10411,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10307
10411
|
/**
|
|
10308
10412
|
* No description
|
|
10309
10413
|
*
|
|
10310
|
-
* @tags collection-
|
|
10414
|
+
* @tags collection-permissions
|
|
10311
10415
|
* @name UpdateTeamPermissionInCollection
|
|
10312
|
-
* @summary Update
|
|
10416
|
+
* @summary Update an org team's permission in a collection
|
|
10313
10417
|
* @request PATCH:/collections/{collectionId}/permissions/teams/{teamId}
|
|
10314
10418
|
* @secure
|
|
10315
10419
|
*/
|
|
@@ -10326,9 +10430,9 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10326
10430
|
/**
|
|
10327
10431
|
* No description
|
|
10328
10432
|
*
|
|
10329
|
-
* @tags collection-
|
|
10433
|
+
* @tags collection-permissions
|
|
10330
10434
|
* @name RemoveTeamFromCollection
|
|
10331
|
-
* @summary Remove
|
|
10435
|
+
* @summary Remove an org team from a collection
|
|
10332
10436
|
* @request DELETE:/collections/{collectionId}/permissions/teams/{teamId}
|
|
10333
10437
|
* @secure
|
|
10334
10438
|
*/
|
|
@@ -10336,7 +10440,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10336
10440
|
/**
|
|
10337
10441
|
* No description
|
|
10338
10442
|
*
|
|
10339
|
-
* @tags collection-
|
|
10443
|
+
* @tags collection-permissions
|
|
10340
10444
|
* @name ListUserPermissionsInCollection
|
|
10341
10445
|
* @summary List collection user permissions
|
|
10342
10446
|
* @request GET:/collections/{collectionId}/permissions/users
|
|
@@ -10363,7 +10467,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10363
10467
|
/**
|
|
10364
10468
|
* No description
|
|
10365
10469
|
*
|
|
10366
|
-
* @tags collection-
|
|
10470
|
+
* @tags collection-permissions
|
|
10367
10471
|
* @name UpdateUserPermissionInCollection
|
|
10368
10472
|
* @summary Update a collection user permission
|
|
10369
10473
|
* @request PATCH:/collections/{collectionId}/permissions/users/{userId}
|
|
@@ -10382,7 +10486,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10382
10486
|
/**
|
|
10383
10487
|
* No description
|
|
10384
10488
|
*
|
|
10385
|
-
* @tags collection-
|
|
10489
|
+
* @tags collection-permissions
|
|
10386
10490
|
* @name RemoveUserFromCollection
|
|
10387
10491
|
* @summary Remove a user from a collection
|
|
10388
10492
|
* @request DELETE:/collections/{collectionId}/permissions/users/{userId}
|
|
@@ -10392,7 +10496,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
10392
10496
|
/**
|
|
10393
10497
|
* No description
|
|
10394
10498
|
*
|
|
10395
|
-
* @tags
|
|
10499
|
+
* @tags space-permissions
|
|
10396
10500
|
* @name ListPermissionsAggregateInCollection
|
|
10397
10501
|
* @summary List all collections users permissions
|
|
10398
10502
|
* @request GET:/collections/{collectionId}/permissions/aggregate
|
|
@@ -13349,6 +13453,16 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
13349
13453
|
/** Optional label for the connection */
|
|
13350
13454
|
label?: ContextConnectionLabel;
|
|
13351
13455
|
}, params?: RequestParams) => Promise<HttpResponse<ContextConnection, any>>;
|
|
13456
|
+
/**
|
|
13457
|
+
* No description
|
|
13458
|
+
*
|
|
13459
|
+
* @tags site-context
|
|
13460
|
+
* @name DeleteSiteContextConnectionById
|
|
13461
|
+
* @summary Delete a context connection
|
|
13462
|
+
* @request DELETE:/orgs/{organizationId}/sites/{siteId}/context-connections/{siteContextConnectionId}
|
|
13463
|
+
* @secure
|
|
13464
|
+
*/
|
|
13465
|
+
deleteSiteContextConnectionById: (organizationId: string, siteId: string, siteContextConnectionId: string, params?: RequestParams) => Promise<HttpResponse<void, any>>;
|
|
13352
13466
|
/**
|
|
13353
13467
|
* No description
|
|
13354
13468
|
*
|
|
@@ -13682,6 +13796,22 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
13682
13796
|
message: string;
|
|
13683
13797
|
};
|
|
13684
13798
|
}>>;
|
|
13799
|
+
/**
|
|
13800
|
+
* No description
|
|
13801
|
+
*
|
|
13802
|
+
* @tags site-permissions
|
|
13803
|
+
* @name InviteToSite
|
|
13804
|
+
* @summary Invite a user or a team to a site
|
|
13805
|
+
* @request POST:/orgs/{organizationId}/sites/{siteId}/permissions
|
|
13806
|
+
* @secure
|
|
13807
|
+
*/
|
|
13808
|
+
inviteToSite: (organizationId: string, siteId: string, data: InviteSiteUsersAndTeams, params?: RequestParams) => Promise<HttpResponse<void, {
|
|
13809
|
+
error: {
|
|
13810
|
+
/** @format int32 */
|
|
13811
|
+
code: 404;
|
|
13812
|
+
message: string;
|
|
13813
|
+
};
|
|
13814
|
+
}>>;
|
|
13685
13815
|
/**
|
|
13686
13816
|
* No description
|
|
13687
13817
|
*
|
|
@@ -13703,6 +13833,134 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
13703
13833
|
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
13704
13834
|
items: UserSitePermission[];
|
|
13705
13835
|
}, any>>;
|
|
13836
|
+
/**
|
|
13837
|
+
* No description
|
|
13838
|
+
*
|
|
13839
|
+
* @tags site-users
|
|
13840
|
+
* @name ListUserPermissionsInSite
|
|
13841
|
+
* @summary List site user permissions
|
|
13842
|
+
* @request GET:/orgs/{organizationId}/sites/{siteId}/permissions/users
|
|
13843
|
+
* @secure
|
|
13844
|
+
*/
|
|
13845
|
+
listUserPermissionsInSite: (organizationId: string, siteId: string, query?: {
|
|
13846
|
+
/** Identifier of the page results to fetch. */
|
|
13847
|
+
page?: string;
|
|
13848
|
+
/**
|
|
13849
|
+
* The number of results per page
|
|
13850
|
+
* @min 0
|
|
13851
|
+
* @max 1000
|
|
13852
|
+
*/
|
|
13853
|
+
limit?: number;
|
|
13854
|
+
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
13855
|
+
items: UserSitePermissionOverride[];
|
|
13856
|
+
}, {
|
|
13857
|
+
error: {
|
|
13858
|
+
/** @format int32 */
|
|
13859
|
+
code: 404;
|
|
13860
|
+
message: string;
|
|
13861
|
+
};
|
|
13862
|
+
}>>;
|
|
13863
|
+
/**
|
|
13864
|
+
* No description
|
|
13865
|
+
*
|
|
13866
|
+
* @tags site-users
|
|
13867
|
+
* @name UpdateUserPermissionInSite
|
|
13868
|
+
* @summary Update site user permissions
|
|
13869
|
+
* @request PATCH:/orgs/{organizationId}/sites/{siteId}/permissions/users/{userId}
|
|
13870
|
+
* @secure
|
|
13871
|
+
*/
|
|
13872
|
+
updateUserPermissionInSite: (organizationId: string, siteId: string, userId: string, data: {
|
|
13873
|
+
/**
|
|
13874
|
+
* "The role of a member in an organization.
|
|
13875
|
+
* "admin": Can administrate the content: create, delete spaces, ...
|
|
13876
|
+
* "create": Can create content.
|
|
13877
|
+
* "review": Can review content.
|
|
13878
|
+
* "edit": Can edit the content (live or change requests).
|
|
13879
|
+
* "comment": Can access the content and its discussions.
|
|
13880
|
+
* "read": Can access the content, but cannot update it in any way.
|
|
13881
|
+
*/
|
|
13882
|
+
role?: MemberRole;
|
|
13883
|
+
}, params?: RequestParams) => Promise<HttpResponse<void, {
|
|
13884
|
+
error: {
|
|
13885
|
+
/** @format int32 */
|
|
13886
|
+
code: 404;
|
|
13887
|
+
message: string;
|
|
13888
|
+
};
|
|
13889
|
+
}>>;
|
|
13890
|
+
/**
|
|
13891
|
+
* No description
|
|
13892
|
+
*
|
|
13893
|
+
* @tags site-users
|
|
13894
|
+
* @name RemoveUserFromSite
|
|
13895
|
+
* @summary Remove a site user
|
|
13896
|
+
* @request DELETE:/orgs/{organizationId}/sites/{siteId}/permissions/users/{userId}
|
|
13897
|
+
* @secure
|
|
13898
|
+
*/
|
|
13899
|
+
removeUserFromSite: (organizationId: string, siteId: string, userId: string, params?: RequestParams) => Promise<HttpResponse<void, any>>;
|
|
13900
|
+
/**
|
|
13901
|
+
* No description
|
|
13902
|
+
*
|
|
13903
|
+
* @tags site-permissions
|
|
13904
|
+
* @name ListTeamPermissionsInSite
|
|
13905
|
+
* @summary List an org team's permission in a site
|
|
13906
|
+
* @request GET:/orgs/{organizationId}/sites/{siteId}/permissions/teams
|
|
13907
|
+
* @secure
|
|
13908
|
+
*/
|
|
13909
|
+
listTeamPermissionsInSite: (organizationId: string, siteId: string, query?: {
|
|
13910
|
+
/** Identifier of the page results to fetch. */
|
|
13911
|
+
page?: string;
|
|
13912
|
+
/**
|
|
13913
|
+
* The number of results per page
|
|
13914
|
+
* @min 0
|
|
13915
|
+
* @max 1000
|
|
13916
|
+
*/
|
|
13917
|
+
limit?: number;
|
|
13918
|
+
}, params?: RequestParams) => Promise<HttpResponse<List & {
|
|
13919
|
+
items: TeamSitePermissionOverride[];
|
|
13920
|
+
}, {
|
|
13921
|
+
error: {
|
|
13922
|
+
/** @format int32 */
|
|
13923
|
+
code: 404;
|
|
13924
|
+
message: string;
|
|
13925
|
+
};
|
|
13926
|
+
}>>;
|
|
13927
|
+
/**
|
|
13928
|
+
* No description
|
|
13929
|
+
*
|
|
13930
|
+
* @tags site-permissions
|
|
13931
|
+
* @name UpdateTeamPermissionInSite
|
|
13932
|
+
* @summary Update an org team's permission in a site
|
|
13933
|
+
* @request PATCH:/orgs/{organizationId}/sites/{siteId}/permissions/teams/{teamId}
|
|
13934
|
+
* @secure
|
|
13935
|
+
*/
|
|
13936
|
+
updateTeamPermissionInSite: (organizationId: string, siteId: string, teamId: string, data: {
|
|
13937
|
+
/**
|
|
13938
|
+
* "The role of a member in an organization.
|
|
13939
|
+
* "admin": Can administrate the content: create, delete spaces, ...
|
|
13940
|
+
* "create": Can create content.
|
|
13941
|
+
* "review": Can review content.
|
|
13942
|
+
* "edit": Can edit the content (live or change requests).
|
|
13943
|
+
* "comment": Can access the content and its discussions.
|
|
13944
|
+
* "read": Can access the content, but cannot update it in any way.
|
|
13945
|
+
*/
|
|
13946
|
+
role?: MemberRole;
|
|
13947
|
+
}, params?: RequestParams) => Promise<HttpResponse<void, {
|
|
13948
|
+
error: {
|
|
13949
|
+
/** @format int32 */
|
|
13950
|
+
code: 404;
|
|
13951
|
+
message: string;
|
|
13952
|
+
};
|
|
13953
|
+
}>>;
|
|
13954
|
+
/**
|
|
13955
|
+
* No description
|
|
13956
|
+
*
|
|
13957
|
+
* @tags site-permissions
|
|
13958
|
+
* @name RemoveTeamFromSite
|
|
13959
|
+
* @summary Remove an org team from a site
|
|
13960
|
+
* @request DELETE:/orgs/{organizationId}/sites/{siteId}/permissions/teams/{teamId}
|
|
13961
|
+
* @secure
|
|
13962
|
+
*/
|
|
13963
|
+
removeTeamFromSite: (organizationId: string, siteId: string, teamId: string, params?: RequestParams) => Promise<HttpResponse<void, any>>;
|
|
13706
13964
|
/**
|
|
13707
13965
|
* @description Generate an AI response in a conversation.
|
|
13708
13966
|
*
|
package/dist/index.cjs
CHANGED
|
@@ -464,7 +464,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
464
464
|
|
|
465
465
|
// package.json
|
|
466
466
|
var name = "@gitbook/api";
|
|
467
|
-
var version = "0.
|
|
467
|
+
var version = "0.161.0";
|
|
468
468
|
|
|
469
469
|
// src/client.ts
|
|
470
470
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -3840,6 +3840,12 @@ var Api = class extends HttpClient {
|
|
|
3840
3840
|
format: "json",
|
|
3841
3841
|
...params
|
|
3842
3842
|
}),
|
|
3843
|
+
deleteSiteContextConnectionById: (organizationId, siteId, siteContextConnectionId, params = {}) => this.request({
|
|
3844
|
+
path: `/orgs/${organizationId}/sites/${siteId}/context-connections/${siteContextConnectionId}`,
|
|
3845
|
+
method: "DELETE",
|
|
3846
|
+
secure: true,
|
|
3847
|
+
...params
|
|
3848
|
+
}),
|
|
3843
3849
|
syncSiteContextConnection: (organizationId, siteId, siteContextConnectionId, params = {}) => this.request({
|
|
3844
3850
|
path: `/orgs/${organizationId}/sites/${siteId}/context-connections/${siteContextConnectionId}/sync`,
|
|
3845
3851
|
method: "POST",
|
|
@@ -3935,6 +3941,14 @@ var Api = class extends HttpClient {
|
|
|
3935
3941
|
format: "json",
|
|
3936
3942
|
...params
|
|
3937
3943
|
}),
|
|
3944
|
+
inviteToSite: (organizationId, siteId, data, params = {}) => this.request({
|
|
3945
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions`,
|
|
3946
|
+
method: "POST",
|
|
3947
|
+
body: data,
|
|
3948
|
+
secure: true,
|
|
3949
|
+
type: "application/json" /* Json */,
|
|
3950
|
+
...params
|
|
3951
|
+
}),
|
|
3938
3952
|
listPermissionsAggregateInSite: (organizationId, siteId, query, params = {}) => this.request({
|
|
3939
3953
|
path: `/orgs/${organizationId}/sites/${siteId}/permissions/aggregate`,
|
|
3940
3954
|
method: "GET",
|
|
@@ -3943,6 +3957,50 @@ var Api = class extends HttpClient {
|
|
|
3943
3957
|
format: "json",
|
|
3944
3958
|
...params
|
|
3945
3959
|
}),
|
|
3960
|
+
listUserPermissionsInSite: (organizationId, siteId, query, params = {}) => this.request({
|
|
3961
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions/users`,
|
|
3962
|
+
method: "GET",
|
|
3963
|
+
query,
|
|
3964
|
+
secure: true,
|
|
3965
|
+
format: "json",
|
|
3966
|
+
...params
|
|
3967
|
+
}),
|
|
3968
|
+
updateUserPermissionInSite: (organizationId, siteId, userId, data, params = {}) => this.request({
|
|
3969
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions/users/${userId}`,
|
|
3970
|
+
method: "PATCH",
|
|
3971
|
+
body: data,
|
|
3972
|
+
secure: true,
|
|
3973
|
+
type: "application/json" /* Json */,
|
|
3974
|
+
...params
|
|
3975
|
+
}),
|
|
3976
|
+
removeUserFromSite: (organizationId, siteId, userId, params = {}) => this.request({
|
|
3977
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions/users/${userId}`,
|
|
3978
|
+
method: "DELETE",
|
|
3979
|
+
secure: true,
|
|
3980
|
+
...params
|
|
3981
|
+
}),
|
|
3982
|
+
listTeamPermissionsInSite: (organizationId, siteId, query, params = {}) => this.request({
|
|
3983
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions/teams`,
|
|
3984
|
+
method: "GET",
|
|
3985
|
+
query,
|
|
3986
|
+
secure: true,
|
|
3987
|
+
format: "json",
|
|
3988
|
+
...params
|
|
3989
|
+
}),
|
|
3990
|
+
updateTeamPermissionInSite: (organizationId, siteId, teamId, data, params = {}) => this.request({
|
|
3991
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions/teams/${teamId}`,
|
|
3992
|
+
method: "PATCH",
|
|
3993
|
+
body: data,
|
|
3994
|
+
secure: true,
|
|
3995
|
+
type: "application/json" /* Json */,
|
|
3996
|
+
...params
|
|
3997
|
+
}),
|
|
3998
|
+
removeTeamFromSite: (organizationId, siteId, teamId, params = {}) => this.request({
|
|
3999
|
+
path: `/orgs/${organizationId}/sites/${siteId}/permissions/teams/${teamId}`,
|
|
4000
|
+
method: "DELETE",
|
|
4001
|
+
secure: true,
|
|
4002
|
+
...params
|
|
4003
|
+
}),
|
|
3946
4004
|
streamAiResponseInSite: (organizationId, siteId, data, params = {}) => this.streamRequest({
|
|
3947
4005
|
path: `/orgs/${organizationId}/sites/${siteId}/ai/response`,
|
|
3948
4006
|
method: "POST",
|