@gitbook/api 0.40.0 → 0.41.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 +26 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/spec/openapi.json +72 -2
- package/spec/openapi.yaml +49 -0
package/dist/client.d.ts
CHANGED
|
@@ -524,6 +524,8 @@ export declare type PublishedSiteContentLookup = {
|
|
|
524
524
|
basePath: string;
|
|
525
525
|
/** Short-lived API token to fetch content related to the space in the context of the URL. */
|
|
526
526
|
apiToken: string;
|
|
527
|
+
/** ID of the organization. */
|
|
528
|
+
organization: string;
|
|
527
529
|
};
|
|
528
530
|
export interface SpacePointer {
|
|
529
531
|
type: 'space';
|
|
@@ -4328,6 +4330,8 @@ export interface Site {
|
|
|
4328
4330
|
*/
|
|
4329
4331
|
export declare type SiteTitle = string;
|
|
4330
4332
|
export interface SiteCustomizationSettings {
|
|
4333
|
+
/** Title to use for the published site. If not defined, it'll fallback to the default content title. */
|
|
4334
|
+
title?: SiteTitle;
|
|
4331
4335
|
styling: {
|
|
4332
4336
|
primaryColor: CustomizationThemedColor;
|
|
4333
4337
|
corners: CustomizationCorners;
|
|
@@ -4394,6 +4398,8 @@ export interface SiteCustomizationSettings {
|
|
|
4394
4398
|
};
|
|
4395
4399
|
}
|
|
4396
4400
|
export interface SiteSpaceCustomizationOverrides {
|
|
4401
|
+
/** Title to use for the published site variant. If not defined, it'll fallback to the content title. */
|
|
4402
|
+
title?: SiteTitle;
|
|
4397
4403
|
styling?: {
|
|
4398
4404
|
/** The primary color used for links and UI text. Set to null to reset the override. */
|
|
4399
4405
|
primaryColor?: CustomizationThemedColor | null;
|
|
@@ -4530,6 +4536,14 @@ export interface SiteSpace {
|
|
|
4530
4536
|
space: Space;
|
|
4531
4537
|
/** Whether this is the default space for the site */
|
|
4532
4538
|
default?: boolean;
|
|
4539
|
+
/** URLs associated with the object */
|
|
4540
|
+
urls: {
|
|
4541
|
+
/**
|
|
4542
|
+
* URL of the published version of the site-space. Only defined when site is not "unpublished"
|
|
4543
|
+
* @format uri
|
|
4544
|
+
*/
|
|
4545
|
+
published?: string;
|
|
4546
|
+
};
|
|
4533
4547
|
}
|
|
4534
4548
|
/**
|
|
4535
4549
|
* Path to the space on the site
|
|
@@ -4910,6 +4924,12 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
4910
4924
|
code: 409;
|
|
4911
4925
|
message: string;
|
|
4912
4926
|
};
|
|
4927
|
+
} | {
|
|
4928
|
+
error: {
|
|
4929
|
+
/** @format int32 */
|
|
4930
|
+
code: 412;
|
|
4931
|
+
message: string;
|
|
4932
|
+
};
|
|
4913
4933
|
}>>;
|
|
4914
4934
|
/**
|
|
4915
4935
|
* No description
|
|
@@ -6442,6 +6462,12 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
6442
6462
|
code: 409;
|
|
6443
6463
|
message: string;
|
|
6444
6464
|
};
|
|
6465
|
+
} | {
|
|
6466
|
+
error: {
|
|
6467
|
+
/** @format int32 */
|
|
6468
|
+
code: 412;
|
|
6469
|
+
message: string;
|
|
6470
|
+
};
|
|
6445
6471
|
}>>;
|
|
6446
6472
|
/**
|
|
6447
6473
|
* No description
|
package/dist/index.cjs
CHANGED
package/dist/index.js
CHANGED
package/package.json
CHANGED
package/spec/openapi.json
CHANGED
|
@@ -1764,6 +1764,10 @@
|
|
|
1764
1764
|
"apiToken": {
|
|
1765
1765
|
"type": "string",
|
|
1766
1766
|
"description": "Short-lived API token to fetch content related to the space in the context of the URL."
|
|
1767
|
+
},
|
|
1768
|
+
"organization": {
|
|
1769
|
+
"type": "string",
|
|
1770
|
+
"description": "ID of the organization."
|
|
1767
1771
|
}
|
|
1768
1772
|
},
|
|
1769
1773
|
"required": [
|
|
@@ -1772,7 +1776,8 @@
|
|
|
1772
1776
|
"space",
|
|
1773
1777
|
"pathname",
|
|
1774
1778
|
"basePath",
|
|
1775
|
-
"apiToken"
|
|
1779
|
+
"apiToken",
|
|
1780
|
+
"organization"
|
|
1776
1781
|
]
|
|
1777
1782
|
}
|
|
1778
1783
|
]
|
|
@@ -14912,6 +14917,10 @@
|
|
|
14912
14917
|
"SiteCustomizationSettings": {
|
|
14913
14918
|
"type": "object",
|
|
14914
14919
|
"properties": {
|
|
14920
|
+
"title": {
|
|
14921
|
+
"description": "Title to use for the published site. If not defined, it'll fallback to the default content title.",
|
|
14922
|
+
"$ref": "#/components/schemas/SiteTitle"
|
|
14923
|
+
},
|
|
14915
14924
|
"styling": {
|
|
14916
14925
|
"type": "object",
|
|
14917
14926
|
"properties": {
|
|
@@ -15150,6 +15159,10 @@
|
|
|
15150
15159
|
"SiteSpaceCustomizationOverrides": {
|
|
15151
15160
|
"type": "object",
|
|
15152
15161
|
"properties": {
|
|
15162
|
+
"title": {
|
|
15163
|
+
"description": "Title to use for the published site variant. If not defined, it'll fallback to the content title.",
|
|
15164
|
+
"$ref": "#/components/schemas/SiteTitle"
|
|
15165
|
+
},
|
|
15153
15166
|
"styling": {
|
|
15154
15167
|
"type": "object",
|
|
15155
15168
|
"properties": {
|
|
@@ -15624,12 +15637,27 @@
|
|
|
15624
15637
|
"default": {
|
|
15625
15638
|
"type": "boolean",
|
|
15626
15639
|
"description": "Whether this is the default space for the site"
|
|
15640
|
+
},
|
|
15641
|
+
"urls": {
|
|
15642
|
+
"type": "object",
|
|
15643
|
+
"description": "URLs associated with the object",
|
|
15644
|
+
"properties": {
|
|
15645
|
+
"published": {
|
|
15646
|
+
"type": "string",
|
|
15647
|
+
"description": "URL of the published version of the site-space. Only defined when site is not \"unpublished\"",
|
|
15648
|
+
"format": "uri"
|
|
15649
|
+
}
|
|
15650
|
+
},
|
|
15651
|
+
"required": [
|
|
15652
|
+
"location"
|
|
15653
|
+
]
|
|
15627
15654
|
}
|
|
15628
15655
|
},
|
|
15629
15656
|
"required": [
|
|
15630
15657
|
"id",
|
|
15631
15658
|
"space",
|
|
15632
|
-
"path"
|
|
15659
|
+
"path",
|
|
15660
|
+
"urls"
|
|
15633
15661
|
]
|
|
15634
15662
|
},
|
|
15635
15663
|
"SiteSpacePath": {
|
|
@@ -15912,6 +15940,40 @@
|
|
|
15912
15940
|
}
|
|
15913
15941
|
}
|
|
15914
15942
|
}
|
|
15943
|
+
},
|
|
15944
|
+
"PreconditionFailedError": {
|
|
15945
|
+
"description": "PreconditionFailed",
|
|
15946
|
+
"content": {
|
|
15947
|
+
"application/json": {
|
|
15948
|
+
"schema": {
|
|
15949
|
+
"type": "object",
|
|
15950
|
+
"required": [
|
|
15951
|
+
"error"
|
|
15952
|
+
],
|
|
15953
|
+
"properties": {
|
|
15954
|
+
"error": {
|
|
15955
|
+
"type": "object",
|
|
15956
|
+
"properties": {
|
|
15957
|
+
"code": {
|
|
15958
|
+
"type": "integer",
|
|
15959
|
+
"format": "int32",
|
|
15960
|
+
"enum": [
|
|
15961
|
+
412
|
|
15962
|
+
]
|
|
15963
|
+
},
|
|
15964
|
+
"message": {
|
|
15965
|
+
"type": "string"
|
|
15966
|
+
}
|
|
15967
|
+
},
|
|
15968
|
+
"required": [
|
|
15969
|
+
"code",
|
|
15970
|
+
"message"
|
|
15971
|
+
]
|
|
15972
|
+
}
|
|
15973
|
+
}
|
|
15974
|
+
}
|
|
15975
|
+
}
|
|
15976
|
+
}
|
|
15915
15977
|
}
|
|
15916
15978
|
}
|
|
15917
15979
|
},
|
|
@@ -16580,6 +16642,10 @@
|
|
|
16580
16642
|
"description": "Transfer would not result in any update",
|
|
16581
16643
|
"$ref": "#/components/responses/ConflictError"
|
|
16582
16644
|
},
|
|
16645
|
+
"412": {
|
|
16646
|
+
"description": "The space cannot be moved.",
|
|
16647
|
+
"$ref": "#/components/responses/PreconditionFailedError"
|
|
16648
|
+
},
|
|
16583
16649
|
"default": {
|
|
16584
16650
|
"$ref": "#/components/responses/UnexpectedError"
|
|
16585
16651
|
}
|
|
@@ -21225,6 +21291,10 @@
|
|
|
21225
21291
|
"description": "Transfer would not result in any update",
|
|
21226
21292
|
"$ref": "#/components/responses/ConflictError"
|
|
21227
21293
|
},
|
|
21294
|
+
"412": {
|
|
21295
|
+
"description": "The collection cannot be moved.",
|
|
21296
|
+
"$ref": "#/components/responses/PreconditionFailedError"
|
|
21297
|
+
},
|
|
21228
21298
|
"default": {
|
|
21229
21299
|
"$ref": "#/components/responses/UnexpectedError"
|
|
21230
21300
|
}
|
package/spec/openapi.yaml
CHANGED
|
@@ -1265,6 +1265,9 @@ components:
|
|
|
1265
1265
|
apiToken:
|
|
1266
1266
|
type: string
|
|
1267
1267
|
description: Short-lived API token to fetch content related to the space in the context of the URL.
|
|
1268
|
+
organization:
|
|
1269
|
+
type: string
|
|
1270
|
+
description: ID of the organization.
|
|
1268
1271
|
required:
|
|
1269
1272
|
- site
|
|
1270
1273
|
- siteSpace
|
|
@@ -1272,6 +1275,7 @@ components:
|
|
|
1272
1275
|
- pathname
|
|
1273
1276
|
- basePath
|
|
1274
1277
|
- apiToken
|
|
1278
|
+
- organization
|
|
1275
1279
|
SpacePointer:
|
|
1276
1280
|
type: object
|
|
1277
1281
|
properties:
|
|
@@ -9856,6 +9860,9 @@ components:
|
|
|
9856
9860
|
SiteCustomizationSettings:
|
|
9857
9861
|
type: object
|
|
9858
9862
|
properties:
|
|
9863
|
+
title:
|
|
9864
|
+
description: Title to use for the published site. If not defined, it'll fallback to the default content title.
|
|
9865
|
+
$ref: "#/components/schemas/SiteTitle"
|
|
9859
9866
|
styling:
|
|
9860
9867
|
type: object
|
|
9861
9868
|
properties:
|
|
@@ -10015,6 +10022,9 @@ components:
|
|
|
10015
10022
|
SiteSpaceCustomizationOverrides:
|
|
10016
10023
|
type: object
|
|
10017
10024
|
properties:
|
|
10025
|
+
title:
|
|
10026
|
+
description: Title to use for the published site variant. If not defined, it'll fallback to the content title.
|
|
10027
|
+
$ref: "#/components/schemas/SiteTitle"
|
|
10018
10028
|
styling:
|
|
10019
10029
|
type: object
|
|
10020
10030
|
properties:
|
|
@@ -10308,10 +10318,21 @@ components:
|
|
|
10308
10318
|
default:
|
|
10309
10319
|
type: boolean
|
|
10310
10320
|
description: Whether this is the default space for the site
|
|
10321
|
+
urls:
|
|
10322
|
+
type: object
|
|
10323
|
+
description: URLs associated with the object
|
|
10324
|
+
properties:
|
|
10325
|
+
published:
|
|
10326
|
+
type: string
|
|
10327
|
+
description: URL of the published version of the site-space. Only defined when site is not "unpublished"
|
|
10328
|
+
format: uri
|
|
10329
|
+
required:
|
|
10330
|
+
- location
|
|
10311
10331
|
required:
|
|
10312
10332
|
- id
|
|
10313
10333
|
- space
|
|
10314
10334
|
- path
|
|
10335
|
+
- urls
|
|
10315
10336
|
SiteSpacePath:
|
|
10316
10337
|
type: string
|
|
10317
10338
|
description: Path to the space on the site
|
|
@@ -10497,6 +10518,28 @@ components:
|
|
|
10497
10518
|
application/json:
|
|
10498
10519
|
schema:
|
|
10499
10520
|
$ref: "#/components/schemas/Error"
|
|
10521
|
+
PreconditionFailedError:
|
|
10522
|
+
description: PreconditionFailed
|
|
10523
|
+
content:
|
|
10524
|
+
application/json:
|
|
10525
|
+
schema:
|
|
10526
|
+
type: object
|
|
10527
|
+
required:
|
|
10528
|
+
- error
|
|
10529
|
+
properties:
|
|
10530
|
+
error:
|
|
10531
|
+
type: object
|
|
10532
|
+
properties:
|
|
10533
|
+
code:
|
|
10534
|
+
type: integer
|
|
10535
|
+
format: int32
|
|
10536
|
+
enum:
|
|
10537
|
+
- 412
|
|
10538
|
+
message:
|
|
10539
|
+
type: string
|
|
10540
|
+
required:
|
|
10541
|
+
- code
|
|
10542
|
+
- message
|
|
10500
10543
|
paths:
|
|
10501
10544
|
/:
|
|
10502
10545
|
get:
|
|
@@ -10891,6 +10934,9 @@ paths:
|
|
|
10891
10934
|
"409":
|
|
10892
10935
|
description: Transfer would not result in any update
|
|
10893
10936
|
$ref: "#/components/responses/ConflictError"
|
|
10937
|
+
"412":
|
|
10938
|
+
description: The space cannot be moved.
|
|
10939
|
+
$ref: "#/components/responses/PreconditionFailedError"
|
|
10894
10940
|
default:
|
|
10895
10941
|
$ref: "#/components/responses/UnexpectedError"
|
|
10896
10942
|
"/spaces/{spaceId}/search":
|
|
@@ -13431,6 +13477,9 @@ paths:
|
|
|
13431
13477
|
"409":
|
|
13432
13478
|
description: Transfer would not result in any update
|
|
13433
13479
|
$ref: "#/components/responses/ConflictError"
|
|
13480
|
+
"412":
|
|
13481
|
+
description: The collection cannot be moved.
|
|
13482
|
+
$ref: "#/components/responses/PreconditionFailedError"
|
|
13434
13483
|
default:
|
|
13435
13484
|
$ref: "#/components/responses/UnexpectedError"
|
|
13436
13485
|
"/collections/{collectionId}/permissions/aggregate":
|