@gitbook/api 0.41.0 → 0.43.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/spec/openapi.yaml CHANGED
@@ -4152,8 +4152,12 @@ components:
4152
4152
  description: Unique identifier for the organization
4153
4153
  title:
4154
4154
  $ref: "#/components/schemas/OrganizationTitle"
4155
+ createdAt:
4156
+ $ref: "#/components/schemas/Timestamp"
4155
4157
  emailDomains:
4156
4158
  $ref: "#/components/schemas/OrganizationEmailDomains"
4159
+ hostname:
4160
+ $ref: "#/paths/~1orgs~1%7BorganizationId%7D/patch/requestBody/content/application~1json/schema/properties/hostname"
4157
4161
  type:
4158
4162
  $ref: "#/components/schemas/OrganizationType"
4159
4163
  useCase:
@@ -4195,6 +4199,7 @@ components:
4195
4199
  - object
4196
4200
  - id
4197
4201
  - title
4202
+ - createdAt
4198
4203
  - type
4199
4204
  - emailDomains
4200
4205
  - urls
@@ -4468,8 +4473,6 @@ components:
4468
4473
  $ref: "#/components/schemas/OrganizationUsageCollections"
4469
4474
  sites:
4470
4475
  $ref: "#/components/schemas/OrganizationUsageSites"
4471
- seats:
4472
- $ref: "#/components/schemas/OrganizationUsageSeats"
4473
4476
  teams:
4474
4477
  $ref: "#/components/schemas/OrganizationUsageTeams"
4475
4478
  members:
@@ -4480,7 +4483,6 @@ components:
4480
4483
  - spaces
4481
4484
  - collections
4482
4485
  - sites
4483
- - seats
4484
4486
  - teams
4485
4487
  - members
4486
4488
  - teamMembers
@@ -4538,6 +4540,9 @@ components:
4538
4540
  total:
4539
4541
  description: Count of all members
4540
4542
  type: number
4543
+ seats:
4544
+ description: Count of all paid seats
4545
+ type: number
4541
4546
  admin:
4542
4547
  description: Count of all admins
4543
4548
  type: number
@@ -4561,6 +4566,7 @@ components:
4561
4566
  type: number
4562
4567
  required:
4563
4568
  - total
4569
+ - seats
4564
4570
  - admin
4565
4571
  - create
4566
4572
  - edit
@@ -4594,19 +4600,6 @@ components:
4594
4600
  - total
4595
4601
  - owner
4596
4602
  - member
4597
- OrganizationUsageSeats:
4598
- type: object
4599
- description: Seats usage metrics of an organization
4600
- properties:
4601
- total:
4602
- description: The total amount of seats in the organization.
4603
- type: number
4604
- available:
4605
- description: How many seats are still available.
4606
- type: number
4607
- required:
4608
- - total
4609
- - available
4610
4603
  Capture:
4611
4604
  type: object
4612
4605
  properties:
@@ -5898,6 +5891,7 @@ components:
5898
5891
  - space:git:sync
5899
5892
  - space:visitor:auth
5900
5893
  - site:script:inject
5894
+ - site:script:cookies
5901
5895
  - site:visitor:auth
5902
5896
  IntegrationSearchQuery:
5903
5897
  name: search
@@ -6475,6 +6469,21 @@ components:
6475
6469
  required:
6476
6470
  - script
6477
6471
  - cookies
6472
+ SiteIntegrationScript:
6473
+ type: object
6474
+ properties:
6475
+ script:
6476
+ description: Script URL to load.
6477
+ $ref: "#/components/schemas/URL"
6478
+ contentSecurityPolicy:
6479
+ description: Content Security Policy to secure the loading of this script.
6480
+ type: string
6481
+ cookies:
6482
+ type: boolean
6483
+ description: If true, the script will potentially load use cookies and visitors should be aware.
6484
+ required:
6485
+ - script
6486
+ - cookies
6478
6487
  UpsertEntity:
6479
6488
  type: object
6480
6489
  description: Entity to create or update in an integration's installation.
@@ -8549,9 +8558,6 @@ components:
8549
8558
  - $ref: "#/components/schemas/OrganizationIntegrationsChannel"
8550
8559
  - $ref: "#/components/schemas/OrganizationInstallationsChannel"
8551
8560
  - $ref: "#/components/schemas/OrganizationSitesChannel"
8552
- - $ref: "#/components/schemas/OrganizationSeatsChannel"
8553
- - $ref: "#/components/schemas/OrganizationUsageSeatsChannel"
8554
- - $ref: "#/components/schemas/OrganizationSeatChannel"
8555
8561
  - type: object
8556
8562
  properties:
8557
8563
  channel:
@@ -9072,48 +9078,6 @@ components:
9072
9078
  required:
9073
9079
  - channel
9074
9080
  - organization
9075
- OrganizationSeatChannel:
9076
- type: object
9077
- description: Subscription channel for changes in a member seat in an organization.
9078
- properties:
9079
- channel:
9080
- type: string
9081
- enum:
9082
- - organization-seat
9083
- organization:
9084
- type: string
9085
- member:
9086
- type: string
9087
- required:
9088
- - channel
9089
- - organization
9090
- - member
9091
- OrganizationSeatsChannel:
9092
- type: object
9093
- description: Subscription channel for changes in seats in an organization.
9094
- properties:
9095
- channel:
9096
- type: string
9097
- enum:
9098
- - organization-seats
9099
- organization:
9100
- type: string
9101
- required:
9102
- - channel
9103
- - organization
9104
- OrganizationUsageSeatsChannel:
9105
- type: object
9106
- description: Subscription channel for changes in seats usage in an organization.
9107
- properties:
9108
- channel:
9109
- type: string
9110
- enum:
9111
- - organization-usage-seats
9112
- organization:
9113
- type: string
9114
- required:
9115
- - channel
9116
- - organization
9117
9081
  IntegrationChannel:
9118
9082
  type: object
9119
9083
  properties:
@@ -10338,6 +10302,27 @@ components:
10338
10302
  description: Path to the space on the site
10339
10303
  minLength: 1
10340
10304
  maxLength: 100
10305
+ SiteSpaceMovePosition:
10306
+ type: object
10307
+ description: Position at which to move the site space to.
10308
+ properties:
10309
+ before:
10310
+ $ref: "#/components/schemas/SiteSpacePointer"
10311
+ after:
10312
+ $ref: "#/components/schemas/SiteSpacePointer"
10313
+ SiteSpacePointer:
10314
+ type: object
10315
+ properties:
10316
+ type:
10317
+ type: string
10318
+ enum:
10319
+ - site-space
10320
+ siteSpace:
10321
+ type: string
10322
+ description: Unique identifier for the site space
10323
+ required:
10324
+ - type
10325
+ - siteSpace
10341
10326
  SiteSubscriptionStatus:
10342
10327
  type: string
10343
10328
  enum:
@@ -11367,6 +11352,37 @@ paths:
11367
11352
  $ref: "#/components/schemas/RevisionFile"
11368
11353
  default:
11369
11354
  $ref: "#/components/responses/UnexpectedError"
11355
+ "/spaces/{spaceId}/content/files/{fileId}/backlinks":
11356
+ get:
11357
+ operationId: listSpaceFileBacklinks
11358
+ summary: Get backlink locations for a file existing in a space.
11359
+ tags:
11360
+ - spaces
11361
+ security:
11362
+ - user: []
11363
+ parameters:
11364
+ - $ref: "#/components/parameters/spaceId"
11365
+ - $ref: "#/components/parameters/fileId"
11366
+ - $ref: "#/components/parameters/listPage"
11367
+ - $ref: "#/components/parameters/listLimit"
11368
+ responses:
11369
+ "200":
11370
+ description: OK
11371
+ content:
11372
+ application/json:
11373
+ schema:
11374
+ allOf:
11375
+ - $ref: "#/components/schemas/List"
11376
+ - type: object
11377
+ required:
11378
+ - items
11379
+ properties:
11380
+ items:
11381
+ type: array
11382
+ items:
11383
+ $ref: "#/components/schemas/ContentLocation"
11384
+ default:
11385
+ $ref: "#/components/responses/UnexpectedError"
11370
11386
  "/spaces/{spaceId}/content/page/{pageId}":
11371
11387
  get:
11372
11388
  operationId: getPageById
@@ -12254,6 +12270,38 @@ paths:
12254
12270
  $ref: "#/components/schemas/RevisionFile"
12255
12271
  default:
12256
12272
  $ref: "#/components/responses/UnexpectedError"
12273
+ "/spaces/{spaceId}/change-requests/{changeRequestId}/content/files/{fileId}/backlinks":
12274
+ get:
12275
+ operationId: listChangeRequestFileBacklinks
12276
+ summary: Get backlink locations for a file existing in a change request.
12277
+ tags:
12278
+ - spaces
12279
+ security:
12280
+ - user: []
12281
+ parameters:
12282
+ - $ref: "#/components/parameters/spaceId"
12283
+ - $ref: "#/components/parameters/changeRequestId"
12284
+ - $ref: "#/components/parameters/fileId"
12285
+ - $ref: "#/components/parameters/listPage"
12286
+ - $ref: "#/components/parameters/listLimit"
12287
+ responses:
12288
+ "200":
12289
+ description: OK
12290
+ content:
12291
+ application/json:
12292
+ schema:
12293
+ allOf:
12294
+ - $ref: "#/components/schemas/List"
12295
+ - type: object
12296
+ required:
12297
+ - items
12298
+ properties:
12299
+ items:
12300
+ type: array
12301
+ items:
12302
+ $ref: "#/components/schemas/ContentLocation"
12303
+ default:
12304
+ $ref: "#/components/responses/UnexpectedError"
12257
12305
  "/spaces/{spaceId}/change-requests/{changeRequestId}/content/page/{pageId}":
12258
12306
  get:
12259
12307
  operationId: getPageInChangeRequestById
@@ -14524,6 +14572,11 @@ paths:
14524
14572
  $ref: "#/components/schemas/OrganizationTitle"
14525
14573
  emailDomains:
14526
14574
  $ref: "#/components/schemas/OrganizationEmailDomains"
14575
+ hostname:
14576
+ type: string
14577
+ description: Default hostname for the organization's public content, e.g. <org-hostname>.gitbook.io
14578
+ minLength: 3
14579
+ maxLength: 32
14527
14580
  defaultRole:
14528
14581
  $ref: "#/components/schemas/MemberRoleOrGuest"
14529
14582
  defaultContent:
@@ -15258,54 +15311,6 @@ paths:
15258
15311
  properties: {}
15259
15312
  default:
15260
15313
  $ref: "#/components/responses/UnexpectedError"
15261
- "/orgs/{organizationId}/transfer":
15262
- post:
15263
- operationId: transferOrganization
15264
- summary: Transfer one organization (source) into another organization (target).
15265
- tags:
15266
- - organizations
15267
- security:
15268
- - user: []
15269
- parameters:
15270
- - $ref: "#/components/parameters/organizationId"
15271
- requestBody:
15272
- required: true
15273
- content:
15274
- application/json:
15275
- schema:
15276
- type: object
15277
- required:
15278
- - source
15279
- properties:
15280
- source:
15281
- type: string
15282
- description: The unique id of the organization to transfer into the current one.
15283
- defaultOrgRole:
15284
- description: Determine the default role members of the source org will have when they are transferred into the target org. Defaults to null, which means no access.
15285
- oneOf:
15286
- - $ref: "#/components/schemas/MemberRoleOrGuest"
15287
- - type: string
15288
- description: Use SAML's default role for transferred members.
15289
- enum:
15290
- - saml
15291
- responses:
15292
- "200":
15293
- description: OK
15294
- content:
15295
- application/json:
15296
- schema:
15297
- type: object
15298
- required:
15299
- - collection
15300
- properties:
15301
- collection:
15302
- type: string
15303
- description: The unique id of the collection created in the target organization containing the content of the source organization.
15304
- newSourceHostname:
15305
- type: string
15306
- description: The new hostname if the source organization needed to change hostname.
15307
- default:
15308
- $ref: "#/components/responses/UnexpectedError"
15309
15314
  "/orgs/{organizationId}/search":
15310
15315
  get:
15311
15316
  operationId: searchOrganizationContent
@@ -15991,31 +15996,6 @@ paths:
15991
15996
  - teamMembers
15992
15997
  default:
15993
15998
  $ref: "#/components/responses/UnexpectedError"
15994
- "/orgs/{organizationId}/usage/seats":
15995
- get:
15996
- operationId: getSeatsUsageForOrganizationById
15997
- summary: Get seats usage metrics for an organization
15998
- tags:
15999
- - organizations
16000
- - usage
16001
- security:
16002
- - user-internal: []
16003
- parameters:
16004
- - $ref: "#/components/parameters/organizationId"
16005
- responses:
16006
- "200":
16007
- description: OK
16008
- content:
16009
- application/json:
16010
- schema:
16011
- type: object
16012
- properties:
16013
- seats:
16014
- $ref: "#/components/schemas/OrganizationUsageSeats"
16015
- required:
16016
- - seats
16017
- default:
16018
- $ref: "#/components/responses/UnexpectedError"
16019
15999
  "/orgs/{organizationId}/schemas":
16020
16000
  get:
16021
16001
  operationId: listEntitySchemas
@@ -17330,6 +17310,30 @@ paths:
17330
17310
  $ref: "#/components/responses/BadRequestError"
17331
17311
  default:
17332
17312
  $ref: "#/components/responses/UnexpectedError"
17313
+ "/orgs/{organizationId}/sites/{siteId}/integration-scripts":
17314
+ get:
17315
+ operationId: listSiteIntegrationScripts
17316
+ summary: List the scripts to embed in published content for a site.
17317
+ tags:
17318
+ - sites
17319
+ security:
17320
+ - user: []
17321
+ parameters:
17322
+ - $ref: "#/components/parameters/organizationId"
17323
+ - $ref: "#/components/parameters/siteId"
17324
+ responses:
17325
+ "200":
17326
+ description: OK
17327
+ content:
17328
+ application/json:
17329
+ schema:
17330
+ type: array
17331
+ items:
17332
+ $ref: "#/components/schemas/SiteIntegrationScript"
17333
+ "400":
17334
+ $ref: "#/components/responses/BadRequestError"
17335
+ default:
17336
+ $ref: "#/components/responses/UnexpectedError"
17333
17337
  "/orgs/{organizationId}/sites/{siteId}/spaces":
17334
17338
  post:
17335
17339
  operationId: addSpaceToSite
@@ -17495,6 +17499,42 @@ paths:
17495
17499
  $ref: "#/components/responses/BadRequestError"
17496
17500
  default:
17497
17501
  $ref: "#/components/responses/UnexpectedError"
17502
+ "/orgs/{organizationId}/sites/{siteId}/spaces/{siteSpaceId}/move":
17503
+ post:
17504
+ operationId: moveSiteSpace
17505
+ summary: Move a site space to a new position in the site.
17506
+ tags:
17507
+ - sites
17508
+ security:
17509
+ - user: []
17510
+ parameters:
17511
+ - $ref: "#/components/parameters/organizationId"
17512
+ - $ref: "#/components/parameters/siteId"
17513
+ - $ref: "#/components/parameters/siteSpaceId"
17514
+ requestBody:
17515
+ content:
17516
+ application/json:
17517
+ schema:
17518
+ type: object
17519
+ properties:
17520
+ position:
17521
+ description: The position where to move the site space. When not provided the site space is moved at the end of the site.
17522
+ $ref: "#/components/schemas/SiteSpaceMovePosition"
17523
+ responses:
17524
+ "200":
17525
+ description: Site space moved
17526
+ content:
17527
+ application/json:
17528
+ schema:
17529
+ $ref: "#/components/schemas/SiteSpace"
17530
+ "400":
17531
+ description: Invalid move site space position provided
17532
+ $ref: "#/components/responses/BadRequestError"
17533
+ "404":
17534
+ description: No matching Site space found
17535
+ $ref: "#/components/responses/NotFoundError"
17536
+ default:
17537
+ $ref: "#/components/responses/UnexpectedError"
17498
17538
  "/orgs/{organizationId}/sites/{siteId}/permissions/aggregate":
17499
17539
  get:
17500
17540
  operationId: listPermissionsAggregateInSite
@@ -17546,209 +17586,6 @@ paths:
17546
17586
  - origin
17547
17587
  default:
17548
17588
  $ref: "#/components/responses/UnexpectedError"
17549
- "/orgs/{organizationId}/seats":
17550
- get:
17551
- operationId: listSeatsInOrganizationById
17552
- summary: List all seats in an organization
17553
- tags:
17554
- - seats
17555
- security:
17556
- - user-internal: []
17557
- parameters:
17558
- - $ref: "#/components/parameters/organizationId"
17559
- responses:
17560
- "200":
17561
- description: OK
17562
- content:
17563
- application/json:
17564
- schema:
17565
- allOf:
17566
- - $ref: "#/components/schemas/List"
17567
- - type: object
17568
- required:
17569
- - items
17570
- properties:
17571
- items:
17572
- type: array
17573
- items:
17574
- $ref: "#/components/schemas/Seat"
17575
- default:
17576
- $ref: "#/components/responses/UnexpectedError"
17577
- post:
17578
- operationId: addSeatsToOrganizationById
17579
- summary: Add more seats to an organization
17580
- tags:
17581
- - seats
17582
- security:
17583
- - user-internal: []
17584
- parameters:
17585
- - $ref: "#/components/parameters/organizationId"
17586
- requestBody:
17587
- required: true
17588
- content:
17589
- application/json:
17590
- schema:
17591
- type: object
17592
- properties:
17593
- amount:
17594
- description: How many seats to add
17595
- type: number
17596
- required:
17597
- - amount
17598
- responses:
17599
- "201":
17600
- description: Seats added
17601
- default:
17602
- $ref: "#/components/responses/UnexpectedError"
17603
- delete:
17604
- operationId: removeSeatsFromOrganizationById
17605
- summary: Remove unassigned seats from an organization
17606
- tags:
17607
- - seats
17608
- security:
17609
- - user-internal: []
17610
- parameters:
17611
- - $ref: "#/components/parameters/organizationId"
17612
- requestBody:
17613
- content:
17614
- application/json:
17615
- schema:
17616
- type: object
17617
- properties:
17618
- amount:
17619
- description: How many seats to remove. Omit to remove all unassigned seats.
17620
- type: number
17621
- responses:
17622
- "205":
17623
- description: Seats removed
17624
- default:
17625
- $ref: "#/components/responses/UnexpectedError"
17626
- "/orgs/{organizationId}/seats/members":
17627
- put:
17628
- operationId: assignSeatsToMembersInOrganizationById
17629
- summary: Assign seats for one or more members within an organization
17630
- tags:
17631
- - seats
17632
- security:
17633
- - user-internal: []
17634
- parameters:
17635
- - $ref: "#/components/parameters/organizationId"
17636
- requestBody:
17637
- required: true
17638
- content:
17639
- application/json:
17640
- schema:
17641
- type: array
17642
- description: A list of members
17643
- minItems: 1
17644
- items:
17645
- type: object
17646
- properties:
17647
- member:
17648
- description: The unique ID of the organization member
17649
- type: string
17650
- required:
17651
- - member
17652
- responses:
17653
- "200":
17654
- description: Seats assigned
17655
- "409":
17656
- description: Not enough seats available
17657
- $ref: "#/components/responses/ConflictError"
17658
- default:
17659
- $ref: "#/components/responses/UnexpectedError"
17660
- delete:
17661
- operationId: revokeSeatsFromMembersInOrganizationById
17662
- summary: Revoke seats for one or more members within an organization
17663
- tags:
17664
- - seats
17665
- security:
17666
- - user-internal: []
17667
- parameters:
17668
- - $ref: "#/components/parameters/organizationId"
17669
- requestBody:
17670
- required: true
17671
- content:
17672
- application/json:
17673
- schema:
17674
- type: array
17675
- description: A list of members
17676
- minItems: 1
17677
- items:
17678
- type: object
17679
- properties:
17680
- member:
17681
- description: The unique ID of the organization member
17682
- type: string
17683
- required:
17684
- - member
17685
- responses:
17686
- "205":
17687
- description: Seats revoked
17688
- "409":
17689
- description: Not enough seats available
17690
- $ref: "#/components/responses/ConflictError"
17691
- default:
17692
- $ref: "#/components/responses/UnexpectedError"
17693
- "/orgs/{organizationId}/seats/members/{userId}":
17694
- get:
17695
- operationId: getSeatForMemberInOrganizationById
17696
- summary: Get the seat of a member of the organization
17697
- tags:
17698
- - seats
17699
- security:
17700
- - user-internal: []
17701
- parameters:
17702
- - $ref: "#/components/parameters/organizationId"
17703
- - $ref: "#/components/parameters/userId"
17704
- responses:
17705
- "200":
17706
- description: OK
17707
- content:
17708
- application/json:
17709
- schema:
17710
- $ref: "#/components/schemas/Seat"
17711
- "409":
17712
- description: Member has no seat assigned
17713
- $ref: "#/components/responses/ConflictError"
17714
- default:
17715
- $ref: "#/components/responses/UnexpectedError"
17716
- put:
17717
- operationId: assignSeatToMemberInOrganizationById
17718
- summary: Assign an available seat to a member of the organization
17719
- tags:
17720
- - seats
17721
- security:
17722
- - user-internal: []
17723
- parameters:
17724
- - $ref: "#/components/parameters/organizationId"
17725
- - $ref: "#/components/parameters/userId"
17726
- responses:
17727
- "200":
17728
- description: Seat assigned
17729
- "409":
17730
- description: Not enough seats available
17731
- $ref: "#/components/responses/ConflictError"
17732
- default:
17733
- $ref: "#/components/responses/UnexpectedError"
17734
- delete:
17735
- operationId: revokeSeatFromMemberInOrganizationById
17736
- summary: Revoke a seat from a member of the organization
17737
- tags:
17738
- - seats
17739
- security:
17740
- - user-internal: []
17741
- parameters:
17742
- - $ref: "#/components/parameters/organizationId"
17743
- - $ref: "#/components/parameters/userId"
17744
- responses:
17745
- "205":
17746
- description: Seat revoked
17747
- "409":
17748
- description: Member has no seat assigned
17749
- $ref: "#/components/responses/ConflictError"
17750
- default:
17751
- $ref: "#/components/responses/UnexpectedError"
17752
17589
  "/custom-hostnames/{hostname}":
17753
17590
  get:
17754
17591
  operationId: getCustomHostname