@gitbook/api 0.88.1 → 0.89.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
@@ -803,6 +803,25 @@ paths:
803
803
  $ref: "#/components/responses/NotFoundError"
804
804
  default:
805
805
  $ref: "#/components/responses/UnexpectedError"
806
+ "/spaces/{spaceId}/permissions/users/{userId}":
807
+ delete:
808
+ operationId: removeUserFromSpace
809
+ summary: Remove a user from a space
810
+ tags:
811
+ - spaces
812
+ security:
813
+ - user: []
814
+ parameters:
815
+ - $ref: "#/components/parameters/spaceId"
816
+ - $ref: "#/components/parameters/userId"
817
+ responses:
818
+ "205":
819
+ description: The user has been removed from the space
820
+ "404":
821
+ description: No user found with the given ID
822
+ $ref: "#/components/responses/NotFoundError"
823
+ default:
824
+ $ref: "#/components/responses/UnexpectedError"
806
825
  "/spaces/{spaceId}/content":
807
826
  get:
808
827
  operationId: getCurrentRevision
@@ -3270,6 +3289,44 @@ paths:
3270
3289
  application/json:
3271
3290
  schema:
3272
3291
  $ref: "#/components/schemas/InviteUsersAndTeams"
3292
+ "/collections/{collectionId}/permissions/teams/{teamId}":
3293
+ delete:
3294
+ operationId: removeTeamFromCollection
3295
+ summary: Remove a team from a collection
3296
+ tags:
3297
+ - collections
3298
+ security:
3299
+ - user: []
3300
+ parameters:
3301
+ - $ref: "#/components/parameters/collectionId"
3302
+ - $ref: "#/components/parameters/teamId"
3303
+ responses:
3304
+ "205":
3305
+ description: The team has been removed from the collection
3306
+ "404":
3307
+ description: No team found with the given ID
3308
+ $ref: "#/components/responses/NotFoundError"
3309
+ default:
3310
+ $ref: "#/components/responses/UnexpectedError"
3311
+ "/collections/{collectionId}/permissions/users/{userId}":
3312
+ delete:
3313
+ operationId: removeUserFromCollection
3314
+ summary: Remove a user from a collection
3315
+ tags:
3316
+ - collections
3317
+ security:
3318
+ - user: []
3319
+ parameters:
3320
+ - $ref: "#/components/parameters/collectionId"
3321
+ - $ref: "#/components/parameters/userId"
3322
+ responses:
3323
+ "205":
3324
+ description: The user has been removed from the collection
3325
+ "404":
3326
+ description: No user found with the given ID
3327
+ $ref: "#/components/responses/NotFoundError"
3328
+ default:
3329
+ $ref: "#/components/responses/UnexpectedError"
3273
3330
  "/collections/{collectionId}/permissions/aggregate":
3274
3331
  get:
3275
3332
  operationId: listPermissionsAggregateInCollection
@@ -4993,6 +5050,105 @@ paths:
4993
5050
  application/json:
4994
5051
  schema:
4995
5052
  $ref: "#/components/schemas/UpgradeOrganizationBilling"
5053
+ "/orgs/{organizationId}/billing/migrate":
5054
+ post:
5055
+ operationId: migrateOrganizationPlan
5056
+ summary: Migrate an organization's legacy billing plan to new pricing
5057
+ tags:
5058
+ - organizations
5059
+ security:
5060
+ - user-internal: []
5061
+ parameters:
5062
+ - $ref: "#/components/parameters/organizationId"
5063
+ - name: interval
5064
+ in: query
5065
+ required: true
5066
+ description: The desired billing interval
5067
+ schema:
5068
+ $ref: "#/components/schemas/BillingInterval"
5069
+ - name: product
5070
+ in: query
5071
+ required: true
5072
+ description: The new product to upgrade to
5073
+ schema:
5074
+ type: string
5075
+ enum:
5076
+ - free_2024
5077
+ - plus_2024
5078
+ - pro_2024
5079
+ responses:
5080
+ "205":
5081
+ description: Organization migrated to new pricing
5082
+ default:
5083
+ $ref: "#/components/responses/UnexpectedError"
5084
+ get:
5085
+ operationId: previewMigrateOrganizationPlan
5086
+ summary: Preview a migration of an organization to new pricing.
5087
+ tags:
5088
+ - organizations
5089
+ security:
5090
+ - user-internal: []
5091
+ parameters:
5092
+ - $ref: "#/components/parameters/organizationId"
5093
+ - name: interval
5094
+ in: query
5095
+ required: true
5096
+ description: The desired billing interval
5097
+ schema:
5098
+ $ref: "#/components/schemas/BillingInterval"
5099
+ - name: product
5100
+ in: query
5101
+ required: true
5102
+ description: The new product to upgrade to
5103
+ schema:
5104
+ type: string
5105
+ enum:
5106
+ - free_2024
5107
+ - plus_2024
5108
+ - pro_2024
5109
+ responses:
5110
+ "200":
5111
+ description: OK
5112
+ content:
5113
+ application/json:
5114
+ schema:
5115
+ type: object
5116
+ properties:
5117
+ invoice:
5118
+ $ref: "#/components/schemas/BillingInvoicePreview"
5119
+ default:
5120
+ $ref: "#/components/responses/UnexpectedError"
5121
+ "/orgs/{organizationId}/billing/migrate/sites":
5122
+ get:
5123
+ operationId: listSitesToMigrate
5124
+ summary: Lists all legacy sites of an org and computes their new type and contributing features
5125
+ tags:
5126
+ - organizations
5127
+ - sites
5128
+ security:
5129
+ - user-internal: []
5130
+ parameters:
5131
+ - $ref: "#/components/parameters/organizationId"
5132
+ - $ref: "#/components/parameters/listPage"
5133
+ - $ref: "#/components/parameters/listLimit"
5134
+ responses:
5135
+ "200":
5136
+ description: OK
5137
+ content:
5138
+ application/json:
5139
+ schema:
5140
+ allOf:
5141
+ - $ref: "#/components/schemas/List"
5142
+ - type: object
5143
+ required:
5144
+ - items
5145
+ properties:
5146
+ items:
5147
+ type: array
5148
+ items:
5149
+ $ref: "#/components/schemas/SiteToMigrate"
5150
+ default:
5151
+ $ref: "#/components/responses/UnexpectedError"
4996
5152
  "/orgs/{organizationId}/billing/portal":
4997
5153
  get:
4998
5154
  operationId: getOrganizationBillingPortal
@@ -7248,6 +7404,100 @@ paths:
7248
7404
  $ref: "#/components/schemas/SiteSpace"
7249
7405
  default:
7250
7406
  $ref: "#/components/responses/UnexpectedError"
7407
+ "/orgs/{organizationId}/sites/{siteId}/section-groups":
7408
+ post:
7409
+ operationId: addSectionGroupToSite
7410
+ summary: Add a section group to a site in an organization
7411
+ tags:
7412
+ - sites
7413
+ security:
7414
+ - user: []
7415
+ parameters:
7416
+ - $ref: "#/components/parameters/organizationId"
7417
+ - $ref: "#/components/parameters/siteId"
7418
+ requestBody:
7419
+ required: true
7420
+ content:
7421
+ application/json:
7422
+ schema:
7423
+ type: object
7424
+ properties:
7425
+ title:
7426
+ $ref: "#/components/schemas/SiteSectionGroupTitle"
7427
+ sections:
7428
+ type: array
7429
+ items:
7430
+ type: string
7431
+ description: IDs of the sections to be added to the section group
7432
+ required:
7433
+ - title
7434
+ responses:
7435
+ "201":
7436
+ description: Section group added to the site
7437
+ headers:
7438
+ Location:
7439
+ description: API URL for the newly created site-section-group relationship
7440
+ schema:
7441
+ type: string
7442
+ content:
7443
+ application/json:
7444
+ schema:
7445
+ $ref: "#/components/schemas/SiteSectionGroup"
7446
+ default:
7447
+ $ref: "#/components/responses/UnexpectedError"
7448
+ "/orgs/{organizationId}/sites/{siteId}/section-groups/{siteSectionGroupId}":
7449
+ patch:
7450
+ operationId: updateSiteSectionGroupById
7451
+ summary: Update a section group on a site in an organization
7452
+ tags:
7453
+ - sites
7454
+ security:
7455
+ - user: []
7456
+ parameters:
7457
+ - $ref: "#/components/parameters/organizationId"
7458
+ - $ref: "#/components/parameters/siteId"
7459
+ - $ref: "#/components/parameters/siteSectionGroupId"
7460
+ requestBody:
7461
+ required: true
7462
+ content:
7463
+ application/json:
7464
+ schema:
7465
+ type: object
7466
+ properties:
7467
+ title:
7468
+ $ref: "#/components/schemas/SiteSectionGroupTitle"
7469
+ icon:
7470
+ oneOf:
7471
+ - $ref: "#/components/schemas/Icon"
7472
+ - type: string
7473
+ nullable: true
7474
+ enum:
7475
+ - null
7476
+ responses:
7477
+ "200":
7478
+ description: OK
7479
+ content:
7480
+ application/json:
7481
+ schema:
7482
+ $ref: "#/components/schemas/SiteSectionGroup"
7483
+ default:
7484
+ $ref: "#/components/responses/UnexpectedError"
7485
+ delete:
7486
+ operationId: deleteSiteSectionGroupById
7487
+ summary: Delete a section group on a site in an organization
7488
+ tags:
7489
+ - sites
7490
+ security:
7491
+ - user: []
7492
+ parameters:
7493
+ - $ref: "#/components/parameters/organizationId"
7494
+ - $ref: "#/components/parameters/siteId"
7495
+ - $ref: "#/components/parameters/siteSectionGroupId"
7496
+ responses:
7497
+ "205":
7498
+ description: Site section group has been deleted
7499
+ default:
7500
+ $ref: "#/components/responses/UnexpectedError"
7251
7501
  "/orgs/{organizationId}/sites/{siteId}/sections":
7252
7502
  post:
7253
7503
  operationId: addSectionToSite
@@ -8593,6 +8843,17 @@ paths:
8593
8843
  - $ref: "#/components/parameters/listPage"
8594
8844
  - $ref: "#/components/parameters/listLimit"
8595
8845
  - $ref: "#/components/parameters/xGitBookPartnerKey"
8846
+ - name: status
8847
+ in: query
8848
+ description: Filter sites by their ads review status
8849
+ required: false
8850
+ schema:
8851
+ type: string
8852
+ default: in-review
8853
+ enum:
8854
+ - in-review
8855
+ - live
8856
+ - rejected
8596
8857
  responses:
8597
8858
  "200":
8598
8859
  description: OK
@@ -8608,21 +8869,54 @@ paths:
8608
8869
  items:
8609
8870
  type: array
8610
8871
  items:
8611
- type: object
8612
- required:
8613
- - id
8614
- - url
8615
- - email
8616
- - topic
8617
- properties:
8618
- id:
8619
- type: string
8620
- url:
8621
- type: string
8622
- email:
8623
- type: string
8624
- topic:
8625
- $ref: "#/components/schemas/SiteAdsTopic"
8872
+ allOf:
8873
+ - type: object
8874
+ required:
8875
+ - id
8876
+ - url
8877
+ - email
8878
+ - topic
8879
+ properties:
8880
+ id:
8881
+ type: string
8882
+ url:
8883
+ type: string
8884
+ email:
8885
+ type: string
8886
+ topic:
8887
+ $ref: "#/components/schemas/SiteAdsTopic"
8888
+ - oneOf:
8889
+ - type: object
8890
+ required:
8891
+ - status
8892
+ properties:
8893
+ status:
8894
+ type: string
8895
+ enum:
8896
+ - in-review
8897
+ - type: object
8898
+ required:
8899
+ - status
8900
+ - zoneId
8901
+ properties:
8902
+ status:
8903
+ type: string
8904
+ enum:
8905
+ - live
8906
+ zoneId:
8907
+ type: string
8908
+ description: The ad network zone ID
8909
+ - type: object
8910
+ required:
8911
+ - status
8912
+ properties:
8913
+ status:
8914
+ type: string
8915
+ enum:
8916
+ - rejected
8917
+ reason:
8918
+ type: string
8919
+ description: Reason for the rejection
8626
8920
  default:
8627
8921
  $ref: "#/components/responses/UnexpectedError"
8628
8922
  "/ads/sites/{siteId}":
@@ -9122,6 +9416,13 @@ components:
9122
9416
  schema:
9123
9417
  type: boolean
9124
9418
  default: false
9419
+ siteSectionGroupId:
9420
+ name: siteSectionGroupId
9421
+ in: path
9422
+ required: true
9423
+ description: The unique id of the site group
9424
+ schema:
9425
+ type: string
9125
9426
  siteSectionId:
9126
9427
  name: siteSectionId
9127
9428
  in: path
@@ -12721,6 +13022,7 @@ components:
12721
13022
  properties:
12722
13023
  url:
12723
13024
  type: string
13025
+ format: uri
12724
13026
  description: URL of the content to import.
12725
13027
  source:
12726
13028
  $ref: "#/components/schemas/ImportContentSource"
@@ -17227,6 +17529,9 @@ components:
17227
17529
  condition:
17228
17530
  description: Conditional expression used to evaluate whether the site section should be shown to the site's visitor.
17229
17531
  $ref: "#/components/schemas/Condition"
17532
+ sectionGroup:
17533
+ type: string
17534
+ description: ID of the section group the section belongs to in the site
17230
17535
  siteSpaces:
17231
17536
  type: array
17232
17537
  items:
@@ -17738,6 +18043,47 @@ components:
17738
18043
  - interval_changed
17739
18044
  required:
17740
18045
  - result
18046
+ SiteToMigrateFeature:
18047
+ type: string
18048
+ description: These are all the features we check to determine the new pricing site type.
18049
+ enum:
18050
+ - sections
18051
+ - visitor-auth
18052
+ - redirects
18053
+ - custom-hostname
18054
+ - AI-search
18055
+ - PDF-export
18056
+ - page-ratings
18057
+ - custom-logo
18058
+ - custom-theme-preset
18059
+ - custom-fonts
18060
+ - custom-icons
18061
+ - custom-footer-logo
18062
+ - custom-footer-copyright
18063
+ - custom-footer-links
18064
+ - unlisted
18065
+ - share-links
18066
+ SiteToMigrate:
18067
+ type: object
18068
+ properties:
18069
+ object:
18070
+ type: string
18071
+ enum:
18072
+ - site-to-migrate
18073
+ site:
18074
+ $ref: "#/components/schemas/Site"
18075
+ newType:
18076
+ description: The new type of the site
18077
+ $ref: "#/components/schemas/SiteType"
18078
+ features:
18079
+ type: array
18080
+ items:
18081
+ $ref: "#/components/schemas/SiteToMigrateFeature"
18082
+ required:
18083
+ - object
18084
+ - site
18085
+ - newType
18086
+ - features
17741
18087
  BillingPortal:
17742
18088
  type: object
17743
18089
  properties:
@@ -18628,6 +18974,36 @@ components:
18628
18974
  type: string
18629
18975
  format: uri
18630
18976
  description: A fallback URL that will be used if authentication fails.
18977
+ SiteSectionGroupTitle:
18978
+ type: string
18979
+ description: Title of the site section group
18980
+ minLength: 1
18981
+ maxLength: 100
18982
+ SiteSectionGroup:
18983
+ type: object
18984
+ properties:
18985
+ object:
18986
+ type: string
18987
+ description: The object type, which is always "site-section-group"
18988
+ enum:
18989
+ - site-section-group
18990
+ id:
18991
+ type: string
18992
+ description: Unique identifier of the site section group
18993
+ title:
18994
+ $ref: "#/components/schemas/SiteSectionGroupTitle"
18995
+ sections:
18996
+ type: array
18997
+ description: List of site section ids that are members of the group
18998
+ items:
18999
+ $ref: "#/components/schemas/SiteSection"
19000
+ icon:
19001
+ $ref: "#/components/schemas/Icon"
19002
+ required:
19003
+ - object
19004
+ - id
19005
+ - title
19006
+ - sections
18631
19007
  SiteSearchScope:
18632
19008
  oneOf:
18633
19009
  - type: object
@@ -19002,6 +19378,30 @@ components:
19002
19378
  required:
19003
19379
  - type
19004
19380
  - feedback
19381
+ SiteInsightsEventPagePostFeedbackComment:
19382
+ allOf:
19383
+ - $ref: "#/components/schemas/SiteInsightsEventBase"
19384
+ - type: object
19385
+ properties:
19386
+ type:
19387
+ type: string
19388
+ enum:
19389
+ - page_post_feedback_comment
19390
+ feedback:
19391
+ type: object
19392
+ properties:
19393
+ rating:
19394
+ $ref: "#/components/schemas/PageFeedbackRating"
19395
+ comment:
19396
+ type: string
19397
+ minLength: 1
19398
+ maxLength: 512
19399
+ required:
19400
+ - rating
19401
+ - comment
19402
+ required:
19403
+ - type
19404
+ - feedback
19005
19405
  SiteInsightsEventAskQuestion:
19006
19406
  allOf:
19007
19407
  - $ref: "#/components/schemas/SiteInsightsEventBase"
@@ -19074,6 +19474,71 @@ components:
19074
19474
  required:
19075
19475
  - type
19076
19476
  - operation
19477
+ SiteInsightsTrademarkPlacement:
19478
+ type: string
19479
+ enum:
19480
+ - sidebar
19481
+ - ad
19482
+ - footer
19483
+ SiteInsightsEventTrademarkClick:
19484
+ allOf:
19485
+ - $ref: "#/components/schemas/SiteInsightsEventBase"
19486
+ - type: object
19487
+ properties:
19488
+ type:
19489
+ type: string
19490
+ enum:
19491
+ - trademark_click
19492
+ placement:
19493
+ $ref: "#/components/schemas/SiteInsightsTrademarkPlacement"
19494
+ required:
19495
+ - type
19496
+ - placement
19497
+ SiteInsightsAdPlacement:
19498
+ type: string
19499
+ enum:
19500
+ - aside
19501
+ SiteInsightsAd:
19502
+ type: object
19503
+ properties:
19504
+ domain:
19505
+ type: string
19506
+ zoneId:
19507
+ type: string
19508
+ placement:
19509
+ $ref: "#/components/schemas/SiteInsightsAdPlacement"
19510
+ required:
19511
+ - domain
19512
+ - zoneId
19513
+ - placement
19514
+ SiteInsightsEventAdClick:
19515
+ allOf:
19516
+ - $ref: "#/components/schemas/SiteInsightsEventBase"
19517
+ - type: object
19518
+ properties:
19519
+ type:
19520
+ type: string
19521
+ enum:
19522
+ - ad_click
19523
+ ad:
19524
+ $ref: "#/components/schemas/SiteInsightsAd"
19525
+ required:
19526
+ - type
19527
+ - ad
19528
+ SiteInsightsEventAdDisplay:
19529
+ allOf:
19530
+ - $ref: "#/components/schemas/SiteInsightsEventBase"
19531
+ - type: object
19532
+ properties:
19533
+ type:
19534
+ type: string
19535
+ enum:
19536
+ - ad_display
19537
+ ad:
19538
+ $ref: "#/components/schemas/SiteInsightsAd"
19539
+ required:
19540
+ - type
19541
+ - ad
19077
19542
  SiteInsightsEvent:
19078
19543
  oneOf:
19079
19544
  - $ref: "#/components/schemas/SiteInsightsEventPageView"
@@ -19081,10 +19546,14 @@ components:
19081
19546
  - $ref: "#/components/schemas/SiteInsightsEventSearchTypeQuery"
19082
19547
  - $ref: "#/components/schemas/SiteInsightsEventSearchOpenResult"
19083
19548
  - $ref: "#/components/schemas/SiteInsightsEventPagePostFeedback"
19549
+ - $ref: "#/components/schemas/SiteInsightsEventPagePostFeedbackComment"
19084
19550
  - $ref: "#/components/schemas/SiteInsightsEventAskQuestion"
19085
19551
  - $ref: "#/components/schemas/SiteInsightsEventLinkClick"
19086
19552
  - $ref: "#/components/schemas/SiteInsightsEventAPIClientOpen"
19087
19553
  - $ref: "#/components/schemas/SiteInsightsEventAPIClientRequest"
19554
+ - $ref: "#/components/schemas/SiteInsightsEventTrademarkClick"
19555
+ - $ref: "#/components/schemas/SiteInsightsEventAdClick"
19556
+ - $ref: "#/components/schemas/SiteInsightsEventAdDisplay"
19088
19557
  SiteInsightsEventType:
19089
19558
  type: string
19090
19559
  enum:
@@ -19093,10 +19562,14 @@ components:
19093
19562
  - search_type_query
19094
19563
  - search_open_result
19095
19564
  - page_post_feedback
19565
+ - page_post_feedback_comment
19096
19566
  - ask_question
19097
19567
  - link_click
19098
19568
  - api_client_open
19099
19569
  - api_client_request
19570
+ - ad_click
19571
+ - ad_display
19572
+ - trademark_click
19100
19573
  SiteInsightsVisitorBrowser:
19101
19574
  type: string
19102
19575
  enum:
@@ -19593,6 +20066,45 @@ components:
19593
20066
  type: array
19594
20067
  items:
19595
20068
  type: string
20069
+ - type: object
20070
+ required:
20071
+ - column
20072
+ - values
20073
+ properties:
20074
+ column:
20075
+ type: string
20076
+ enum:
20077
+ - eventAdDomain
20078
+ values:
20079
+ type: array
20080
+ items:
20081
+ type: string
20082
+ - type: object
20083
+ required:
20084
+ - column
20085
+ - values
20086
+ properties:
20087
+ column:
20088
+ type: string
20089
+ enum:
20090
+ - eventAdPlacement
20091
+ values:
20092
+ type: array
20093
+ items:
20094
+ $ref: "#/components/schemas/SiteInsightsAdPlacement"
20095
+ - type: object
20096
+ required:
20097
+ - column
20098
+ - values
20099
+ properties:
20100
+ column:
20101
+ type: string
20102
+ enum:
20103
+ - eventTrademarkPlacement
20104
+ values:
20105
+ type: array
20106
+ items:
20107
+ $ref: "#/components/schemas/SiteInsightsTrademarkPlacement"
19596
20108
  SiteInsightsQueryOperator:
19597
20109
  type: string
19598
20110
  enum:
@@ -19879,6 +20391,30 @@ components:
19879
20391
  - visitorClaim
19880
20392
  claim:
19881
20393
  type: string
20394
+ - type: object
20395
+ required:
20396
+ - column
20397
+ properties:
20398
+ column:
20399
+ type: string
20400
+ enum:
20401
+ - eventAdDomain
20402
+ - type: object
20403
+ required:
20404
+ - column
20405
+ properties:
20406
+ column:
20407
+ type: string
20408
+ enum:
20409
+ - eventAdPlacement
20410
+ - type: object
20411
+ required:
20412
+ - column
20413
+ properties:
20414
+ column:
20415
+ type: string
20416
+ enum:
20417
+ - eventTrademarkPlacement
19882
20418
  SiteInsightsQueryRange:
19883
20419
  type: string
19884
20420
  enum: