@gitbook/api 0.174.0 → 0.176.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
@@ -537,6 +537,23 @@ paths:
537
537
  "404":
538
538
  description: User not found
539
539
  $ref: "#/components/responses/NotFoundError"
540
+ /user/notifications/token:
541
+ post:
542
+ operationId: createUserNotificationsToken
543
+ summary: Create a JWT to access the in-app notifications service
544
+ description: |
545
+ Generates a JWT for the authenticated user. This token is used by the frontend notifications client to access user endpoints.
546
+ tags:
547
+ - users
548
+ security:
549
+ - user-internal: []
550
+ responses:
551
+ "200":
552
+ description: The notifications service User JWT
553
+ content:
554
+ application/json:
555
+ schema:
556
+ $ref: "#/components/schemas/APITemporaryToken"
540
557
  "/users/{userId}":
541
558
  get:
542
559
  operationId: getUserById
@@ -1627,6 +1644,8 @@ paths:
1627
1644
  $ref: "#/components/schemas/ChangeRequestSubject"
1628
1645
  description:
1629
1646
  $ref: "#/components/schemas/JSONDocument"
1647
+ links:
1648
+ $ref: "#/components/schemas/ChangeRequestLinks"
1630
1649
  status:
1631
1650
  type: string
1632
1651
  enum:
@@ -7483,62 +7502,6 @@ paths:
7483
7502
  description: Site section group did not exist
7484
7503
  "205":
7485
7504
  description: Site section group has been deleted
7486
- "/orgs/{organizationId}/sites/{siteId}/section-groups/{siteSectionGroupId}/sections":
7487
- post:
7488
- operationId: addSectionToGroup
7489
- deprecated: true
7490
- summary: Add a section to a section group
7491
- tags:
7492
- - site-section-groups
7493
- security:
7494
- - user: []
7495
- parameters:
7496
- - $ref: "#/components/parameters/organizationId"
7497
- - $ref: "#/components/parameters/siteId"
7498
- - $ref: "#/components/parameters/siteSectionGroupId"
7499
- requestBody:
7500
- required: true
7501
- content:
7502
- application/json:
7503
- schema:
7504
- type: object
7505
- properties:
7506
- sectionId:
7507
- type: string
7508
- description: ID of the section to add to the section group
7509
- required:
7510
- - sectionId
7511
- responses:
7512
- "201":
7513
- description: Section added to the section group
7514
- headers:
7515
- Location:
7516
- description: API URL for the newly created site-section-group relationship
7517
- schema:
7518
- type: string
7519
- content:
7520
- application/json:
7521
- schema:
7522
- $ref: "#/components/schemas/SiteSectionGroup"
7523
- "/orgs/{organizationId}/sites/{siteId}/section-groups/{siteSectionGroupId}/sections/{siteSectionId}":
7524
- delete:
7525
- operationId: removeSectionFromGroup
7526
- deprecated: true
7527
- summary: Remove a section from a section group
7528
- tags:
7529
- - site-section-groups
7530
- security:
7531
- - user: []
7532
- parameters:
7533
- - $ref: "#/components/parameters/organizationId"
7534
- - $ref: "#/components/parameters/siteId"
7535
- - $ref: "#/components/parameters/siteSectionGroupId"
7536
- - $ref: "#/components/parameters/siteSectionId"
7537
- responses:
7538
- "204":
7539
- description: Section was not part of the group
7540
- "205":
7541
- description: Section has been removed from the section group
7542
7505
  "/orgs/{organizationId}/sites/{siteId}/sections":
7543
7506
  post:
7544
7507
  operationId: addSectionToSite
@@ -8548,9 +8511,11 @@ paths:
8548
8511
  $ref: "#/components/schemas/SiteQuestionAnswerResolution"
8549
8512
  - name: topic
8550
8513
  in: query
8551
- description: Filter questions by associated site topic ID.
8514
+ description: Filter questions by associated site topic IDs.
8552
8515
  schema:
8553
- type: string
8516
+ type: array
8517
+ items:
8518
+ type: string
8554
8519
  - $ref: "#/components/parameters/listOrder"
8555
8520
  - name: sort
8556
8521
  in: query
@@ -8561,6 +8526,7 @@ paths:
8561
8526
  - askedAt
8562
8527
  - stats.answered
8563
8528
  - stats.feedback
8529
+ - stats.answers
8564
8530
  - $ref: "#/components/parameters/listPage"
8565
8531
  - $ref: "#/components/parameters/listLimit"
8566
8532
  responses:
@@ -8591,6 +8557,30 @@ paths:
8591
8557
  - $ref: "#/components/parameters/organizationId"
8592
8558
  - $ref: "#/components/parameters/siteId"
8593
8559
  - $ref: "#/components/parameters/siteQuestionId"
8560
+ - name: from
8561
+ in: query
8562
+ description: Filter stats to answers created at or after this timestamp.
8563
+ schema:
8564
+ $ref: "#/components/schemas/Timestamp"
8565
+ - name: to
8566
+ in: query
8567
+ description: Filter stats to answers created at or before this timestamp.
8568
+ schema:
8569
+ $ref: "#/components/schemas/Timestamp"
8570
+ - name: relevance
8571
+ in: query
8572
+ description: Filter stats by question relevance.
8573
+ schema:
8574
+ type: array
8575
+ items:
8576
+ $ref: "#/components/schemas/SiteQuestionAnswerRelevance"
8577
+ - name: answered
8578
+ in: query
8579
+ description: Filter stats by answer resolution.
8580
+ schema:
8581
+ type: array
8582
+ items:
8583
+ $ref: "#/components/schemas/SiteQuestionAnswerResolution"
8594
8584
  responses:
8595
8585
  "200":
8596
8586
  description: OK
@@ -8612,6 +8602,30 @@ paths:
8612
8602
  - $ref: "#/components/parameters/siteQuestionId"
8613
8603
  - $ref: "#/components/parameters/listPage"
8614
8604
  - $ref: "#/components/parameters/listLimit"
8605
+ - name: from
8606
+ in: query
8607
+ description: Filter sources to answers created at or after this timestamp.
8608
+ schema:
8609
+ $ref: "#/components/schemas/Timestamp"
8610
+ - name: to
8611
+ in: query
8612
+ description: Filter sources to answers created at or before this timestamp.
8613
+ schema:
8614
+ $ref: "#/components/schemas/Timestamp"
8615
+ - name: relevance
8616
+ in: query
8617
+ description: Filter answer sources by question relevance.
8618
+ schema:
8619
+ type: array
8620
+ items:
8621
+ $ref: "#/components/schemas/SiteQuestionAnswerRelevance"
8622
+ - name: answered
8623
+ in: query
8624
+ description: Filter answer sources by answer resolution.
8625
+ schema:
8626
+ type: array
8627
+ items:
8628
+ $ref: "#/components/schemas/SiteQuestionAnswerResolution"
8615
8629
  responses:
8616
8630
  "200":
8617
8631
  description: OK
@@ -8693,6 +8707,16 @@ paths:
8693
8707
  description: Filter answers to a specific site question ID.
8694
8708
  schema:
8695
8709
  type: string
8710
+ - name: from
8711
+ in: query
8712
+ description: Filter answers created at or after this timestamp.
8713
+ schema:
8714
+ $ref: "#/components/schemas/Timestamp"
8715
+ - name: to
8716
+ in: query
8717
+ description: Filter answers created at or before this timestamp.
8718
+ schema:
8719
+ $ref: "#/components/schemas/Timestamp"
8696
8720
  - name: language
8697
8721
  in: query
8698
8722
  description: Filter answers by ISO language code.
@@ -8702,7 +8726,9 @@ paths:
8702
8726
  in: query
8703
8727
  description: Filter answers by answered resolution.
8704
8728
  schema:
8705
- $ref: "#/components/schemas/SiteQuestionAnswerResolution"
8729
+ type: array
8730
+ items:
8731
+ $ref: "#/components/schemas/SiteQuestionAnswerResolution"
8706
8732
  - name: helpfulness
8707
8733
  in: query
8708
8734
  description: Filter answers by answered helpfulness.
@@ -8712,7 +8738,9 @@ paths:
8712
8738
  in: query
8713
8739
  description: Filter answers by question relevance.
8714
8740
  schema:
8715
- $ref: "#/components/schemas/SiteQuestionAnswerRelevance"
8741
+ type: array
8742
+ items:
8743
+ $ref: "#/components/schemas/SiteQuestionAnswerRelevance"
8716
8744
  - name: question.type
8717
8745
  in: query
8718
8746
  description: Filter answers by question type.
@@ -9097,7 +9125,7 @@ paths:
9097
9125
  default:
9098
9126
  description: The theme mode default value. Set to null to reset the override.
9099
9127
  oneOf:
9100
- - $ref: "#/components/schemas/CustomizationThemeMode"
9128
+ - $ref: "#/components/schemas/CustomizationDefaultThemeMode"
9101
9129
  - type: "null"
9102
9130
  toggeable:
9103
9131
  description: Should the reader be able to switch between dark and light mode. Set to null to reset the override.
@@ -10110,6 +10138,11 @@ paths:
10110
10138
  $ref: "#/components/schemas/URL"
10111
10139
  headers:
10112
10140
  $ref: "#/components/schemas/SiteMcpServerHeaders"
10141
+ condition:
10142
+ description: Conditional expression used to evaluate whether the MCP server should be available to the site's visitor (should evaluate to a boolean). If set to null, the condition will be removed.
10143
+ oneOf:
10144
+ - $ref: "#/components/schemas/Expression"
10145
+ - type: "null"
10113
10146
  required:
10114
10147
  - name
10115
10148
  - url
@@ -10166,6 +10199,11 @@ paths:
10166
10199
  maxLength: 2048
10167
10200
  headers:
10168
10201
  $ref: "#/components/schemas/SiteMcpServerHeaders"
10202
+ condition:
10203
+ description: Conditional expression used to evaluate whether the MCP server should be available to the site's visitor (should evaluate to a boolean). If not set, the condition will remain unchanged. If set to null, the condition will be removed.
10204
+ oneOf:
10205
+ - $ref: "#/components/schemas/Expression"
10206
+ - type: "null"
10169
10207
  responses:
10170
10208
  "200":
10171
10209
  description: OK
@@ -11268,6 +11306,14 @@ components:
11268
11306
  - id
11269
11307
  - displayName
11270
11308
  - urls
11309
+ APITemporaryToken:
11310
+ type: object
11311
+ properties:
11312
+ token:
11313
+ type: string
11314
+ description: Temporary access token to authenticate with the API
11315
+ required:
11316
+ - token
11271
11317
  List:
11272
11318
  type: object
11273
11319
  properties:
@@ -13083,6 +13129,9 @@ components:
13083
13129
  stickyHeader:
13084
13130
  type: boolean
13085
13131
  description: Should we keep the table header sticky while the page scrolls
13132
+ stickyFirstColumn:
13133
+ type: boolean
13134
+ description: Should we keep the first visible table column sticky while horizontally scrolling
13086
13135
  useNewSizing:
13087
13136
  type: boolean
13088
13137
  description: |
@@ -15642,6 +15691,25 @@ components:
15642
15691
  description: Subject of the change request
15643
15692
  minLength: 0
15644
15693
  maxLength: 100
15694
+ ChangeRequestLinkTitle:
15695
+ type: string
15696
+ description: Optional title to display for the link.
15697
+ maxLength: 128
15698
+ ChangeRequestLink:
15699
+ type: object
15700
+ properties:
15701
+ ref:
15702
+ $ref: "#/components/schemas/ContentRefURL"
15703
+ title:
15704
+ $ref: "#/components/schemas/ChangeRequestLinkTitle"
15705
+ required:
15706
+ - ref
15707
+ ChangeRequestLinks:
15708
+ type: array
15709
+ description: External links associated with the change request.
15710
+ items:
15711
+ $ref: "#/components/schemas/ChangeRequestLink"
15712
+ maxItems: 10
15645
15713
  ChangeRequest:
15646
15714
  type: object
15647
15715
  properties:
@@ -15705,6 +15773,8 @@ components:
15705
15773
  outdated:
15706
15774
  type: boolean
15707
15775
  description: If true, the change request is not up-to-date with latest changes in the main content.
15776
+ links:
15777
+ $ref: "#/components/schemas/ChangeRequestLinks"
15708
15778
  urls:
15709
15779
  type: object
15710
15780
  description: URLs associated with the object
@@ -19109,6 +19179,8 @@ components:
19109
19179
  - sites-ads
19110
19180
  - sites-ai-search
19111
19181
  - sites-ai-assistant
19182
+ - sites-connections
19183
+ - sites-channels
19112
19184
  - sites-embed
19113
19185
  - sites-api-playground
19114
19186
  - sites-basic-customization
@@ -20125,14 +20197,6 @@ components:
20125
20197
  $ref: "#/components/schemas/IntegrationInstallationSpaceSelection"
20126
20198
  site_selection:
20127
20199
  $ref: "#/components/schemas/IntegrationInstallationSiteSelection"
20128
- APITemporaryToken:
20129
- type: object
20130
- properties:
20131
- token:
20132
- type: string
20133
- description: Temporary access token to authenticate with the API
20134
- required:
20135
- - token
20136
20200
  UpdateIntegrationSpaceInstallation:
20137
20201
  type: object
20138
20202
  properties:
@@ -22511,11 +22575,12 @@ components:
22511
22575
  - enabled
22512
22576
  - message
22513
22577
  - style
22514
- CustomizationThemeMode:
22578
+ CustomizationDefaultThemeMode:
22515
22579
  type: string
22516
22580
  enum:
22517
22581
  - light
22518
22582
  - dark
22583
+ - system
22519
22584
  CustomizationAIMode:
22520
22585
  type: string
22521
22586
  enum:
@@ -22730,7 +22795,7 @@ components:
22730
22795
  type: object
22731
22796
  properties:
22732
22797
  default:
22733
- $ref: "#/components/schemas/CustomizationThemeMode"
22798
+ $ref: "#/components/schemas/CustomizationDefaultThemeMode"
22734
22799
  toggeable:
22735
22800
  description: Should the reader be able to switch between dark and light mode
22736
22801
  type: boolean
@@ -23020,6 +23085,7 @@ components:
23020
23085
  description: The reason or feature that triggered the site upgrade
23021
23086
  oneOf:
23022
23087
  - $ref: "#/components/schemas/SiteFeatureKey"
23088
+ - $ref: "#/components/schemas/BillingMeter"
23023
23089
  - type: string
23024
23090
  enum:
23025
23091
  - settings
@@ -23642,6 +23708,19 @@ components:
23642
23708
  - changeRequests
23643
23709
  - search
23644
23710
  - searchBoost
23711
+ YoutubeChannelId:
23712
+ type: string
23713
+ description: A YouTube channel ID starting with "UC".
23714
+ pattern: ^UC[A-Za-z0-9_-]{22}$
23715
+ YoutubeChannelName:
23716
+ type: string
23717
+ description: A YouTube channel handle starting with "@".
23718
+ pattern: ^@[A-Za-z0-9._-]{3,100}$
23719
+ YoutubeChannelPattern:
23720
+ description: A YouTube channel identifier, either a channel ID or a channel handle.
23721
+ oneOf:
23722
+ - $ref: "#/components/schemas/YoutubeChannelId"
23723
+ - $ref: "#/components/schemas/YoutubeChannelName"
23645
23724
  ContextConnectorSetup:
23646
23725
  oneOf:
23647
23726
  - type: object
@@ -23695,8 +23774,7 @@ components:
23695
23774
  type: object
23696
23775
  properties:
23697
23776
  channelId:
23698
- type: string
23699
- pattern: ^UC[A-Za-z0-9_-]{22}$
23777
+ $ref: "#/components/schemas/YoutubeChannelPattern"
23700
23778
  required:
23701
23779
  - channelId
23702
23780
  required:
@@ -24030,6 +24108,8 @@ components:
24030
24108
  enum:
24031
24109
  - builtin:slack
24032
24110
  - builtin:discord
24111
+ - builtin:github
24112
+ - builtin:linear
24033
24113
  SiteQuestionAnswer:
24034
24114
  type: object
24035
24115
  properties:
@@ -24685,6 +24765,12 @@ components:
24685
24765
  - $ref: "#/components/schemas/AIToolCallSubmitChangeRequestReview"
24686
24766
  - $ref: "#/components/schemas/AIToolCallMCP"
24687
24767
  - $ref: "#/components/schemas/AIToolCallOther"
24768
+ AIMessageStepPhase:
24769
+ type: string
24770
+ description: The phase of a step in a message from the AI agent.
24771
+ enum:
24772
+ - commentary
24773
+ - final_answer
24688
24774
  Timerange:
24689
24775
  type: object
24690
24776
  properties:
@@ -24744,6 +24830,8 @@ components:
24744
24830
  type: array
24745
24831
  items:
24746
24832
  $ref: "#/components/schemas/AIToolCall"
24833
+ phase:
24834
+ $ref: "#/components/schemas/AIMessageStepPhase"
24747
24835
  timing:
24748
24836
  type: object
24749
24837
  description: The timing of the step.
@@ -24754,8 +24842,6 @@ components:
24754
24842
  type: array
24755
24843
  items:
24756
24844
  $ref: "#/components/schemas/AIAttachment"
24757
- required:
24758
- - content
24759
24845
  AIMessageTask:
24760
24846
  oneOf:
24761
24847
  - type: object
@@ -24971,6 +25057,37 @@ components:
24971
25057
  required:
24972
25058
  - type
24973
25059
  - organization
25060
+ UserSitePermissionSiteOrigin:
25061
+ type: object
25062
+ description: Direct site permission origin.
25063
+ properties:
25064
+ type:
25065
+ type: string
25066
+ enum:
25067
+ - site
25068
+ site:
25069
+ type: string
25070
+ description: Unique identifier for the site
25071
+ reason:
25072
+ type: string
25073
+ description: Why the permission was enforced at the site level.
25074
+ enum:
25075
+ - member
25076
+ - team
25077
+ - default
25078
+ team:
25079
+ type: string
25080
+ description: Unique identifier for the team when the permission comes from a team override.
25081
+ required:
25082
+ - type
25083
+ - site
25084
+ - reason
25085
+ UserSitePermissionOrigin:
25086
+ description: The origin that enforced the effective permission level for a user in a site.
25087
+ oneOf:
25088
+ - $ref: "#/components/schemas/SpacePointer"
25089
+ - $ref: "#/components/schemas/OrganizationPointer"
25090
+ - $ref: "#/components/schemas/UserSitePermissionSiteOrigin"
24974
25091
  UserSitePermission:
24975
25092
  type: object
24976
25093
  description: Permission of a user in a site.
@@ -24980,10 +25097,7 @@ components:
24980
25097
  user:
24981
25098
  $ref: "#/components/schemas/User"
24982
25099
  origin:
24983
- description: The content or organization that enforced this permission level.
24984
- oneOf:
24985
- - $ref: "#/components/schemas/SpacePointer"
24986
- - $ref: "#/components/schemas/OrganizationPointer"
25100
+ $ref: "#/components/schemas/UserSitePermissionOrigin"
24987
25101
  required:
24988
25102
  - permission
24989
25103
  - user
@@ -25031,9 +25145,7 @@ components:
25031
25145
  description: Input version of an AI message.
25032
25146
  properties:
25033
25147
  role:
25034
- type: string
25035
- enum:
25036
- - user
25148
+ $ref: "#/components/schemas/AIMessageRole"
25037
25149
  content:
25038
25150
  oneOf:
25039
25151
  - type: string
@@ -25136,6 +25248,29 @@ components:
25136
25248
  required:
25137
25249
  - type
25138
25250
  - messageId
25251
+ AIStreamResponseStepStart:
25252
+ type: object
25253
+ description: |
25254
+ Message emitted by the server to indicate the start of a step in the AI response.
25255
+ properties:
25256
+ type:
25257
+ type: string
25258
+ enum:
25259
+ - response_step_start
25260
+ messageId:
25261
+ type: string
25262
+ description: |
25263
+ The ID of the message that this event is composing.
25264
+ stepIndex:
25265
+ type: integer
25266
+ description: |
25267
+ The index of the step of the message that this event is composing.
25268
+ phase:
25269
+ $ref: "#/components/schemas/AIMessageStepPhase"
25270
+ required:
25271
+ - type
25272
+ - messageId
25273
+ - stepIndex
25139
25274
  AIStreamResponseFinish:
25140
25275
  type: object
25141
25276
  description: |
@@ -25326,6 +25461,7 @@ components:
25326
25461
  AIStreamResponse:
25327
25462
  oneOf:
25328
25463
  - $ref: "#/components/schemas/AIStreamResponseStart"
25464
+ - $ref: "#/components/schemas/AIStreamResponseStepStart"
25329
25465
  - $ref: "#/components/schemas/AIStreamResponseFinish"
25330
25466
  - $ref: "#/components/schemas/AIStreamResponseDocument"
25331
25467
  - $ref: "#/components/schemas/AIStreamResponseObject"
@@ -27253,6 +27389,9 @@ components:
27253
27389
  $ref: "#/components/schemas/URL"
27254
27390
  headers:
27255
27391
  $ref: "#/components/schemas/SiteMcpServerHeaders"
27392
+ condition:
27393
+ description: Conditional expression used to evaluate whether the MCP server should be available to the site's visitor.
27394
+ $ref: "#/components/schemas/Expression"
27256
27395
  urls:
27257
27396
  type: object
27258
27397
  description: URLs associated with the object
@@ -27270,6 +27409,14 @@ components:
27270
27409
  - url
27271
27410
  - headers
27272
27411
  - urls
27412
+ GenericChannelPattern:
27413
+ type: string
27414
+ description: A generic channel name or pattern. For example, "general" or "support-*".
27415
+ pattern: ^[a-zA-Z0-9_\*-]+$
27416
+ GitHubRepositoryPattern:
27417
+ type: string
27418
+ description: A GitHub repository name or pattern in the format "owner/repository". For example, "my-org/my-repo" or "my-org/*" to allow all repositories under "my-org".
27419
+ pattern: ^[a-zA-Z0-9._*-]+\/[a-zA-Z0-9._*-]+$
27273
27420
  SiteChannelSetup:
27274
27421
  oneOf:
27275
27422
  - type: object
@@ -27286,8 +27433,43 @@ components:
27286
27433
  description: List of allowed Slack channel names or patterns. If empty, all channels are allowed.
27287
27434
  type: array
27288
27435
  items:
27289
- type: string
27290
- pattern: ^[a-zA-Z0-9_\*-]+$
27436
+ $ref: "#/components/schemas/GenericChannelPattern"
27437
+ required:
27438
+ - type
27439
+ - setupSettings
27440
+ - type: object
27441
+ properties:
27442
+ type:
27443
+ type: string
27444
+ enum:
27445
+ - builtin:linear
27446
+ setupSettings:
27447
+ type: object
27448
+ additionalProperties: false
27449
+ properties:
27450
+ allowedTeams:
27451
+ description: List of allowed Linear team keys or patterns. If empty, all teams are allowed.
27452
+ type: array
27453
+ items:
27454
+ $ref: "#/components/schemas/GenericChannelPattern"
27455
+ required:
27456
+ - type
27457
+ - setupSettings
27458
+ - type: object
27459
+ properties:
27460
+ type:
27461
+ type: string
27462
+ enum:
27463
+ - builtin:github
27464
+ setupSettings:
27465
+ type: object
27466
+ additionalProperties: false
27467
+ properties:
27468
+ allowedRepositories:
27469
+ description: List of allowed GitHub repository names or patterns. If empty, all repositories are allowed.
27470
+ type: array
27471
+ items:
27472
+ $ref: "#/components/schemas/GitHubRepositoryPattern"
27291
27473
  required:
27292
27474
  - type
27293
27475
  - setupSettings
@@ -27305,8 +27487,7 @@ components:
27305
27487
  description: List of allowed Discord channel names or patterns. If empty, all channels are allowed.
27306
27488
  type: array
27307
27489
  items:
27308
- type: string
27309
- pattern: ^[a-zA-Z0-9_\*-]+$
27490
+ $ref: "#/components/schemas/GenericChannelPattern"
27310
27491
  required:
27311
27492
  - type
27312
27493
  - setupSettings
@@ -29647,6 +29828,11 @@ components:
29647
29828
  - $ref: "#/components/schemas/APIChannelMutationData"
29648
29829
  discriminator:
29649
29830
  propertyName: channel
29831
+ CustomizationThemeMode:
29832
+ type: string
29833
+ enum:
29834
+ - light
29835
+ - dark
29650
29836
  SiteAdaptiveDeterministicJSONSchemaClaimsProperties:
29651
29837
  oneOf:
29652
29838
  - $ref: "#/components/schemas/SiteAdaptiveDeterministicJSONSchemaPrimitives"