@gitbook/api 0.143.2 → 0.145.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 CHANGED
@@ -561,12 +561,40 @@ export interface DocumentMarkStrikethrough {
561
561
  object: 'mark';
562
562
  type: 'strikethrough';
563
563
  }
564
+ export declare enum DocumentTextColor {
565
+ Default = "default",
566
+ Green = "green",
567
+ Blue = "blue",
568
+ Red = "red",
569
+ Orange = "orange",
570
+ Yellow = "yellow",
571
+ Purple = "purple",
572
+ Primary = "$primary",
573
+ Info = "$info",
574
+ Success = "$success",
575
+ Warning = "$warning",
576
+ Danger = "$danger"
577
+ }
578
+ export declare enum DocumentTextBackgroundColor {
579
+ Default = "default",
580
+ Green = "green",
581
+ Blue = "blue",
582
+ Red = "red",
583
+ Orange = "orange",
584
+ Yellow = "yellow",
585
+ Purple = "purple",
586
+ Primary = "$primary",
587
+ Info = "$info",
588
+ Success = "$success",
589
+ Warning = "$warning",
590
+ Danger = "$danger"
591
+ }
564
592
  export interface DocumentMarkColor {
565
593
  object: 'mark';
566
594
  type: 'color';
567
595
  data: {
568
- text: 'default' | 'green' | 'blue' | 'red' | 'orange' | 'yellow' | 'purple' | '$primary' | '$info' | '$success' | '$warning' | '$danger';
569
- background: 'default' | 'green' | 'blue' | 'red' | 'orange' | 'yellow' | 'purple' | '$primary' | '$info' | '$success' | '$warning' | '$danger';
596
+ text: DocumentTextColor;
597
+ background: DocumentTextBackgroundColor;
570
598
  };
571
599
  }
572
600
  export interface DocumentMarkSuperscript {
@@ -674,6 +702,7 @@ export interface DocumentInlineIcon {
674
702
  key?: string;
675
703
  data: {
676
704
  icon: string;
705
+ color?: DocumentTextColor;
677
706
  };
678
707
  isVoid: true;
679
708
  }
@@ -762,6 +791,13 @@ export interface DocumentBlockCode {
762
791
  overflow?: 'scroll' | 'wrap';
763
792
  lineNumbers?: boolean;
764
793
  fullWidth?: boolean;
794
+ expandable?: boolean;
795
+ /**
796
+ * Number of lines rendered in a code block when it is collapsed
797
+ * @min 1
798
+ * @default 10
799
+ */
800
+ collapsedLineCount?: number;
765
801
  };
766
802
  nodes: DocumentBlockCodeLine[];
767
803
  isVoid?: false;
@@ -1658,6 +1694,8 @@ export interface ChangeRequest {
1658
1694
  comments: number;
1659
1695
  /** If true, the change request is not up-to-date with latest changes in the main content. */
1660
1696
  outdated: boolean;
1697
+ /** ID of the conversations issues cluster associated with this change request. */
1698
+ conversationsIssuesCluster?: string;
1661
1699
  /** URLs associated with the object */
1662
1700
  urls: {
1663
1701
  /**
@@ -1690,33 +1728,6 @@ export type RevisionTypeComputed = RevisionBase & {
1690
1728
  type: 'computed';
1691
1729
  };
1692
1730
  export type Revision = RevisionTypeEdits | RevisionTypeMerge | RevisionTypeRollback | RevisionTypeUpdate | RevisionTypeComputed;
1693
- export declare enum ImportContentSource {
1694
- Website = "website",
1695
- Docx = "docx",
1696
- Markdown = "markdown",
1697
- Html = "html",
1698
- Zip = "zip",
1699
- Confluence = "confluence",
1700
- GithubWiki = "github-wiki",
1701
- Notion = "notion",
1702
- GoogleDocs = "google-docs"
1703
- }
1704
- export interface ImportContent {
1705
- /**
1706
- * URL of the content to import.
1707
- * @format uri
1708
- */
1709
- url: string;
1710
- source: ImportContentSource;
1711
- }
1712
- export interface ImportContentResult {
1713
- /** ID of the newly created revision. */
1714
- revision: string;
1715
- /** How many resources were imported */
1716
- importedResources: number;
1717
- /** How many resources were processed */
1718
- totalResources: number;
1719
- }
1720
1731
  /** Parameters for a space template */
1721
1732
  export interface SpaceTemplateParams {
1722
1733
  contentRefs?: Record<string, ContentRef>;
@@ -1897,6 +1908,8 @@ export interface Organization {
1897
1908
  trial: {
1898
1909
  /** - notapplicable, no trial can be started for this organization. - none, no trial has been started yet. - active, trial is active. - ended, the trial has ended and the user has choosen to stay on the free plan or has upgraded to a paid plan. - expired, the trial has ended but the user hasn't deciced yet what to do. */
1899
1910
  status: BillingTrialStatus;
1911
+ /** Number of trials the organization has consumed. */
1912
+ count: number;
1900
1913
  /** The trial's end date, if the organization has or had a trial. */
1901
1914
  endDate?: Timestamp;
1902
1915
  /** The decision taken by the user at the end of the trial */
@@ -2217,6 +2230,12 @@ export interface EmojiReaction {
2217
2230
  }[];
2218
2231
  }
2219
2232
  export type EmojiReactions = EmojiReaction[];
2233
+ /** Contributor towards content. */
2234
+ export interface UserContributor {
2235
+ updatedAt: Timestamp;
2236
+ count: number;
2237
+ user: User;
2238
+ }
2220
2239
  /** Details about the table cell this comment is attached to, if any. */
2221
2240
  export interface TableCellTarget {
2222
2241
  record: string;
@@ -2237,6 +2256,8 @@ export type Comment = {
2237
2256
  reactions: EmojiReactions;
2238
2257
  /** The number of replies to this comment. */
2239
2258
  replies: number;
2259
+ /** The users who replied to this comment. */
2260
+ repliers: UserContributor[];
2240
2261
  /** The content of the comment. */
2241
2262
  body: Document;
2242
2263
  /** Information about the target of the comment. */
@@ -2244,7 +2265,6 @@ export type Comment = {
2244
2265
  /** The node this comment is attached to. */
2245
2266
  node?: {
2246
2267
  id: string;
2247
- preview?: string;
2248
2268
  };
2249
2269
  /** Details about the table cell this comment is attached to, if any. */
2250
2270
  tableCell?: TableCellTarget;
@@ -2253,11 +2273,9 @@ export type Comment = {
2253
2273
  /** The review containing this comment, if this comment was made as part of a review. */
2254
2274
  review?: string;
2255
2275
  /** Information about the page, if this comment refers to a specific page. */
2256
- page?: RevisionPageBase & {
2257
- /** The fully qualified path to the page */
2258
- path: string;
2259
- /** True if the target of this comment no longer exists in the primary content */
2260
- outdated: boolean;
2276
+ page?: {
2277
+ /** The ID of the page */
2278
+ id: string;
2261
2279
  };
2262
2280
  /** The space containing this comment. */
2263
2281
  space: string;
@@ -2312,6 +2330,14 @@ export interface ChangeRequestReview {
2312
2330
  comment?: Comment;
2313
2331
  createdAt: Timestamp;
2314
2332
  updatedAt: Timestamp;
2333
+ /** URLs associated with the object */
2334
+ urls: {
2335
+ /**
2336
+ * URL of the review in the API
2337
+ * @format uri
2338
+ */
2339
+ location: string;
2340
+ };
2315
2341
  }
2316
2342
  export interface Team {
2317
2343
  /** Type of Object, always equals to "team" */
@@ -2391,13 +2417,9 @@ export interface PostCommentReplySchema {
2391
2417
  /** The content of the comment. */
2392
2418
  body: Document;
2393
2419
  }
2394
- /** Contributor towards content. */
2395
- export interface UserContributor {
2396
- updatedAt: Timestamp;
2397
- count: number;
2398
- user: User;
2420
+ export type ChangeRequestUserContributor = UserContributor & {
2399
2421
  actionType: 'edit' | 'comment';
2400
- }
2422
+ };
2401
2423
  export declare enum RevisionPageType {
2402
2424
  Document = "document",
2403
2425
  Group = "group",
@@ -4282,6 +4304,8 @@ export type CreateSpace = {
4282
4304
  template: ApplySpaceTemplate;
4283
4305
  } | {
4284
4306
  computedSource: ComputedContentSourceRevision;
4307
+ } | {
4308
+ empty: true;
4285
4309
  }));
4286
4310
  /** An installed integration with its current status */
4287
4311
  export interface InstalledIntegration {
@@ -4569,29 +4593,6 @@ export interface ConversationsIssuesCluster {
4569
4593
  app: string;
4570
4594
  };
4571
4595
  }
4572
- export interface ConversationIssue {
4573
- object: 'conversation-issue';
4574
- /** The ID of the conversation issue */
4575
- id: string;
4576
- /** The title of the conversation issue */
4577
- title: string;
4578
- /** The summary of the conversation issue */
4579
- summary: string;
4580
- createdAt: Timestamp;
4581
- ingestedAt: Timestamp;
4582
- /** The ID of the conversation the issue belongs to */
4583
- conversation: string;
4584
- /** The ID of the cluster the issue has been linked to */
4585
- cluster?: string;
4586
- /** URLs associated with the conversation issue */
4587
- urls: {
4588
- /**
4589
- * URL of the conversation issue in the API
4590
- * @format uri
4591
- */
4592
- location: string;
4593
- };
4594
- }
4595
4596
  /** Integration source */
4596
4597
  export type ConversationSource = string | 'email';
4597
4598
  export interface Conversation {
@@ -4648,6 +4649,29 @@ export interface ConversationInput {
4648
4649
  subject?: string;
4649
4650
  parts: ConversationPart[];
4650
4651
  }
4652
+ export interface ConversationIssue {
4653
+ object: 'conversation-issue';
4654
+ /** The ID of the conversation issue */
4655
+ id: string;
4656
+ /** The title of the conversation issue */
4657
+ title: string;
4658
+ /** The summary of the conversation issue */
4659
+ summary: string;
4660
+ createdAt: Timestamp;
4661
+ ingestedAt: Timestamp;
4662
+ /** The ID of the conversation the issue belongs to */
4663
+ conversation: string;
4664
+ /** The ID of the cluster the issue has been linked to */
4665
+ cluster?: string;
4666
+ /** URLs associated with the conversation issue */
4667
+ urls: {
4668
+ /**
4669
+ * URL of the conversation issue in the API
4670
+ * @format uri
4671
+ */
4672
+ location: string;
4673
+ };
4674
+ }
4651
4675
  /** State and settings of the agent */
4652
4676
  export interface AgentsSetupState {
4653
4677
  /** The email address of the agent. Emails can be forwarded to it to ingest conversations. */
@@ -4922,13 +4946,16 @@ export interface ContentImportRun {
4922
4946
  sourceURL?: string;
4923
4947
  }[];
4924
4948
  }
4925
- /** A response to a request to preview a paid operation or action. A user might preview an operation before executing it to see which billing steps would be required (if any). This schema defines the response of that preview request. */
4926
- export type BillingOperationPreviewResponse = {
4949
+ /** A response to a request to preview the publishing of a site. It indicates whether the operation can proceed immediately, requires checkout, if a trial is available or if a trial extension is available. */
4950
+ export type SitePublishOperationPreviewResponse = {
4927
4951
  /** User can go ahead with the operation without any additional steps. Their subscription will be updated to reflect the new changes. */
4928
4952
  type: 'go-ahead';
4929
4953
  } | {
4930
4954
  /** By going ahead with this operation, the user will be starting a trial in GitBook. */
4931
4955
  type: 'trial-available';
4956
+ } | {
4957
+ /** The organization is eligible for an additional trial when publishing the site. */
4958
+ type: 'extended-trial-available';
4932
4959
  } | {
4933
4960
  /** User must checkout to complete the operation. */
4934
4961
  type: 'checkout';
@@ -5394,6 +5421,18 @@ export interface SiteStructureItemMovePosition {
5394
5421
  * It is used to represent the structure of a site.
5395
5422
  */
5396
5423
  export type SiteStructureItem = SiteSpace | SiteSection | SiteSectionGroup;
5424
+ /** A response to a request to preview a paid operation or action. A user might preview an operation before executing it to see which billing steps would be required (if any). This schema defines the response of that preview request. */
5425
+ export type BillingOperationPreviewResponse = {
5426
+ /** User can go ahead with the operation without any additional steps. Their subscription will be updated to reflect the new changes. */
5427
+ type: 'go-ahead';
5428
+ } | {
5429
+ /** By going ahead with this operation, the user will be starting a trial in GitBook. */
5430
+ type: 'trial-available';
5431
+ } | {
5432
+ /** User must checkout to complete the operation. */
5433
+ type: 'checkout';
5434
+ invoice?: BillingInvoicePreview;
5435
+ };
5397
5436
  /** The reason or feature that triggered the site upgrade */
5398
5437
  export type SiteUpgradeReason = SiteFeatureKey | 'settings' | 'billing-page' | 'end-of-trial';
5399
5438
  export type SitePublishingAuth = (VisitorAuthCustomBackend | VisitorAuthIntegrationBackend) & {
@@ -5424,11 +5463,6 @@ export type SiteSearchScope = {
5424
5463
  mode: 'default';
5425
5464
  /** The ID of the site space that must always be included in the search results. The language of this site space will be used to match other site spaces with the same language, if applicable. */
5426
5465
  currentSiteSpace?: string;
5427
- /**
5428
- * Site spaces to include in search results in addition to default site spaces. This is deprecated and will be removed soon. Please use 'currentSiteSpace' instead.
5429
- * @deprecated
5430
- */
5431
- includedSiteSpaces?: string[];
5432
5466
  } | {
5433
5467
  /** Only search in the provided site spaces. */
5434
5468
  mode: 'specific';
@@ -5501,17 +5535,6 @@ export interface AIMessageInput {
5501
5535
  /** Context about the current user sending a message. */
5502
5536
  context?: AIMessageContext;
5503
5537
  }
5504
- /** Indicate that the AI should response with a JSON object corresponding to the provided schema. */
5505
- export interface AIOutputObject {
5506
- type: 'object';
5507
- /** The JSON schema to use for the object. */
5508
- schema: object;
5509
- }
5510
- /** Indicate that the AI should respond with a rich text document. */
5511
- export interface AIOutputDocument {
5512
- type: 'document';
5513
- }
5514
- export type AIOutputFormat = AIOutputObject | AIOutputDocument;
5515
5538
  export declare enum AIModel {
5516
5539
  Fast = "fast",
5517
5540
  ReasoningLow = "reasoning-low",
@@ -5691,16 +5714,18 @@ export interface AIToolCallGetPageDiff {
5691
5714
  spaceId: string;
5692
5715
  page: ChangedRevisionPage;
5693
5716
  }
5694
- export interface AIToolCallCreateAgentTask {
5695
- tool: 'createAgentTask';
5696
- /** The ID of the space the task belongs to. */
5717
+ export interface AIToolCallCreateChangeRequest {
5718
+ tool: 'createChangeRequest';
5719
+ /** The ID of the space the change request belongs to. */
5697
5720
  spaceId: string;
5698
5721
  action: 'create' | 'update';
5699
- task: {
5700
- /** The unique identifier of the task. */
5722
+ changeRequest: {
5723
+ /** The unique identifier of the change request. */
5701
5724
  id: string;
5702
- /** The title of the task. */
5703
- title: string;
5725
+ /** Incremental identifier of the change request. */
5726
+ number: number;
5727
+ /** A brief summary of the change request. */
5728
+ subject: string;
5704
5729
  };
5705
5730
  }
5706
5731
  export interface AIToolCallComment {
@@ -5752,7 +5777,7 @@ export interface AIToolCallOther {
5752
5777
  /** Summary of a generic tool call. */
5753
5778
  summary: AIToolCallOtherSummary;
5754
5779
  }
5755
- export type AIToolCall = AIToolCallGetPageContent | AIToolCallGetPages | AIToolCallSearch | AIToolCallEditPage | AIToolCallCreatePage | AIToolCallDeletePage | AIToolCallRenamePage | AIToolCallMovePage | AIToolCallListModifiedPages | AIToolCallGetPageDiff | AIToolCallCreateAgentTask | AIToolCallComment | AIToolCallReplyToComment | AIToolCallSubmitChangeRequestReview | AIToolCallMCP | AIToolCallOther;
5780
+ export type AIToolCall = AIToolCallGetPageContent | AIToolCallGetPages | AIToolCallSearch | AIToolCallEditPage | AIToolCallCreatePage | AIToolCallDeletePage | AIToolCallRenamePage | AIToolCallMovePage | AIToolCallListModifiedPages | AIToolCallGetPageDiff | AIToolCallCreateChangeRequest | AIToolCallComment | AIToolCallReplyToComment | AIToolCallSubmitChangeRequestReview | AIToolCallMCP | AIToolCallOther;
5756
5781
  /** Message emitted by the server to indicate that the AI has called a tool. */
5757
5782
  export interface AIStreamResponseToolCall {
5758
5783
  type: 'response_tool_call';
@@ -6493,11 +6518,6 @@ export interface CustomDomainInfo {
6493
6518
  ssl?: CloudflareHostnameTLSInfo;
6494
6519
  verificationErrors: string[];
6495
6520
  }
6496
- /** The GitBook Staff User info. */
6497
- export interface StaffUserInfo {
6498
- id: string;
6499
- searchKey: string;
6500
- }
6501
6521
  /** The User Firebase Auth Info. */
6502
6522
  export interface FirebaseUserInfo {
6503
6523
  uid: string;
@@ -6520,6 +6540,7 @@ export interface BlockContext {
6520
6540
  block: boolean;
6521
6541
  /** A short description giving context on the reason for the block. */
6522
6542
  reason?: BlockReason;
6543
+ blockPaidOrg?: boolean;
6523
6544
  }
6524
6545
  /** The GitBook User impersonation info. */
6525
6546
  export interface UserImpersonationInfo {
@@ -6564,7 +6585,6 @@ export interface UserSpacesPermissions {
6564
6585
  /** All the permissions of a user */
6565
6586
  export interface Index {
6566
6587
  updatedAt: Timestamp;
6567
- searchKey: string;
6568
6588
  organizations: Record<string, UserOrganizationsPermissions>;
6569
6589
  collections: Record<string, UserCollectionsPermissions>;
6570
6590
  spaces: Record<string, UserSpacesPermissions>;
@@ -7137,12 +7157,6 @@ export interface CommentInfoChannel {
7137
7157
  space: string;
7138
7158
  comment: string;
7139
7159
  }
7140
- export interface CommentReplyInfoChannel {
7141
- channel: 'space-comment-reply';
7142
- space: string;
7143
- comment: string;
7144
- commentReply: string;
7145
- }
7146
7160
  export interface CommentRepliesChannel {
7147
7161
  channel: 'space-comment-replies';
7148
7162
  space: string;
@@ -7290,7 +7304,7 @@ export interface ImportRunChannel {
7290
7304
  runId: string;
7291
7305
  }
7292
7306
  /** Channel to subscribe to for realtime updates. */
7293
- export type SubscriptionChannel = SpaceInfoChannel | SpaceContentChannel | SpaceGitInfoChannel | SpacePublishingAuthChannel | SpacePublishingCustomizationChannel | SpaceContentRefsChannel | SpaceIntegrationsChannel | UserAPITokensChannel | UserOrganizationsChannel | UserProfileChannel | ChangeRequestChannel | ChangeRequestsChannel | ChangeRequestReviewsChannel | ChangeRequestContentRefsChannel | CollectionChannel | CollectionPublishingCustomizationChannel | OrganizationInfoChannel | OrganizationInviteLinksChannel | OrganizationMembersChannel | OrganizationMemberChannel | OrganizationSAMLChannel | OrganizationTeamsChannel | OrganizationTeamChannel | OrganizationTeamMembersChannel | OrganizationTeamMemberChannel | OrganizationSpacesChannel | OrganizationCollectionsChannel | OrganizationIntegrationsChannel | OrganizationInstallationsChannel | OrganizationSitesChannel | OrganizationAIIndexationChannel | OrganizationOpenAPISpecsChannel | OrganizationTranslationsChannel | OrganizationTranslationsGlossaryChannel | OrganizationCustomFontsChannel | OrganizationAgentInstructionsChannel | OrganizationChangeRequestsChannel | SpaceCommentsChannel | ChangeRequestCommentsChannel | CommentInfoChannel | CommentReplyInfoChannel | CommentRepliesChannel | IntegrationChannel | IntegrationInstallationChannel | IntegrationSpaceInstallationChannel | IntegrationSpaceInstallationsChannel | IntegrationSiteInstallationChannel | IntegrationSiteInstallationsChannel | PublishedContentSiteChannel | SiteRedirectsChannel | SiteChannel | SiteCustomizationChannel | SiteIntegrationsChannel | SiteSpaceChannel | SiteSpaceCustomizationChannel | SiteStructureChannel | SiteAdaptiveSchemaChannel | SitePublishingAuthChannel | SiteShareLinksChannel | SiteShareLinkChannel | SiteMcpServersChannel | SiteMcpServerChannel | SiteSectionChannel | CustomHostnameChannel | GitSyncOperationChannel | OpenAPISpecChannel | SubdomainChannel | TranslationChannel | TranslationRunChannel | AgentTaskChannel | AgentTasksChannel | ImportRunChannel;
7307
+ export type SubscriptionChannel = SpaceInfoChannel | SpaceContentChannel | SpaceGitInfoChannel | SpacePublishingAuthChannel | SpacePublishingCustomizationChannel | SpaceContentRefsChannel | SpaceIntegrationsChannel | UserAPITokensChannel | UserOrganizationsChannel | UserProfileChannel | ChangeRequestChannel | ChangeRequestsChannel | ChangeRequestReviewsChannel | ChangeRequestContentRefsChannel | CollectionChannel | CollectionPublishingCustomizationChannel | OrganizationInfoChannel | OrganizationInviteLinksChannel | OrganizationMembersChannel | OrganizationMemberChannel | OrganizationSAMLChannel | OrganizationTeamsChannel | OrganizationTeamChannel | OrganizationTeamMembersChannel | OrganizationTeamMemberChannel | OrganizationSpacesChannel | OrganizationCollectionsChannel | OrganizationIntegrationsChannel | OrganizationInstallationsChannel | OrganizationSitesChannel | OrganizationAIIndexationChannel | OrganizationOpenAPISpecsChannel | OrganizationTranslationsChannel | OrganizationTranslationsGlossaryChannel | OrganizationCustomFontsChannel | OrganizationAgentInstructionsChannel | OrganizationChangeRequestsChannel | SpaceCommentsChannel | ChangeRequestCommentsChannel | CommentInfoChannel | CommentRepliesChannel | IntegrationChannel | IntegrationInstallationChannel | IntegrationSpaceInstallationChannel | IntegrationSpaceInstallationsChannel | IntegrationSiteInstallationChannel | IntegrationSiteInstallationsChannel | PublishedContentSiteChannel | SiteRedirectsChannel | SiteChannel | SiteCustomizationChannel | SiteIntegrationsChannel | SiteSpaceChannel | SiteSpaceCustomizationChannel | SiteStructureChannel | SiteAdaptiveSchemaChannel | SitePublishingAuthChannel | SiteShareLinksChannel | SiteShareLinkChannel | SiteMcpServersChannel | SiteMcpServerChannel | SiteSectionChannel | CustomHostnameChannel | GitSyncOperationChannel | OpenAPISpecChannel | SubdomainChannel | TranslationChannel | TranslationRunChannel | AgentTaskChannel | AgentTasksChannel | ImportRunChannel;
7294
7308
  export interface TranslationRunChannelData {
7295
7309
  channel: 'translation-run';
7296
7310
  data: {
@@ -7386,18 +7400,6 @@ export interface AIMessage {
7386
7400
  /** When the agent is responding to a comment. */
7387
7401
  task?: AIMessageTask;
7388
7402
  }
7389
- /** Request to reset the chat. */
7390
- export interface AgentRequestReset {
7391
- type: 'reset';
7392
- }
7393
- /** Request to post a message to the agent. */
7394
- export interface AgentRequestPostMessage {
7395
- type: 'post_message';
7396
- /** Input version of an AI message. */
7397
- message: AIMessageInput;
7398
- }
7399
- /** Payload to send to the agent. */
7400
- export type AgentRequest = AgentRequestReset | AgentRequestPostMessage;
7401
7403
  /** Payload emitted by the agent to reset the messages. */
7402
7404
  export interface AgentStreamMessages {
7403
7405
  type: 'messages';
@@ -7424,7 +7426,12 @@ export interface AgentStreamState {
7424
7426
  type: 'state';
7425
7427
  state: AgentState;
7426
7428
  }
7427
- export type AgentStream = AgentStreamMessages | AgentStreamMessageResponse | AgentStreamState;
7429
+ /** Payload emitted by the agent is responding to a RPC call. */
7430
+ export interface AgentStreamRPC {
7431
+ type: 'rpc';
7432
+ message: string | object;
7433
+ }
7434
+ export type AgentStream = AgentStreamMessages | AgentStreamMessageResponse | AgentStreamState | AgentStreamRPC;
7428
7435
  /** Context available when evaluating merge rules expressions. */
7429
7436
  export interface MergeRulesEvaluationContext {
7430
7437
  space: Space;
@@ -7444,7 +7451,6 @@ export type RequestUpgradeOrganizationBilling = UpgradeOrganizationBilling;
7444
7451
  export type RequestInviteUsersToOrganization = InviteUsersToOrganization;
7445
7452
  export type RequestImportGitRepository = ImportGitRepository;
7446
7453
  export type RequestExportToGitRepository = ExportToGitRepository;
7447
- export type RequestImportContent = ImportContent;
7448
7454
  export type RequestCreateSpace = CreateSpace;
7449
7455
  export type RequestRenderIntegrationUI = RenderIntegrationUI;
7450
7456
  export type RequestUpdateContentPublishingAuth = UpdateContentPublishingAuth;
@@ -7985,16 +7991,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
7985
7991
  */
7986
7992
  computed?: boolean;
7987
7993
  }, params?: RequestParams) => Promise<HttpResponse<Revision, any>>;
7988
- /**
7989
- * No description
7990
- *
7991
- * @tags space-content
7992
- * @name ImportContent
7993
- * @summary Import content in a space
7994
- * @request POST:/spaces/{spaceId}/content/import
7995
- * @secure
7996
- */
7997
- importContent: (spaceId: string, data: ImportContent, params?: RequestParams) => Promise<HttpResponse<ImportContentResult, any>>;
7998
7994
  /**
7999
7995
  * No description
8000
7996
  *
@@ -8182,16 +8178,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
8182
8178
  }, params?: RequestParams) => Promise<HttpResponse<List & {
8183
8179
  items: ContentLocation[];
8184
8180
  }, any>>;
8185
- /**
8186
- * No description
8187
- *
8188
- * @tags space-content
8189
- * @name ImportContentInPageById
8190
- * @summary Import content into a space page
8191
- * @request POST:/spaces/{spaceId}/content/page/{pageId}/import
8192
- * @secure
8193
- */
8194
- importContentInPageById: (spaceId: string, pageId: string, data: ImportContent, params?: RequestParams) => Promise<HttpResponse<ImportContentResult, any>>;
8195
8181
  /**
8196
8182
  * No description
8197
8183
  *
@@ -8334,6 +8320,10 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
8334
8320
  creator?: string;
8335
8321
  /** If defined, only change requests with contributions from this user will be returned. */
8336
8322
  contributor?: string;
8323
+ /** If defined, only change requests with a requested reviewer for this user will be returned. */
8324
+ requestedReviewer?: string;
8325
+ /** If defined, only change requests associated with this conversations issues cluster will be returned. */
8326
+ conversationsIssuesCluster?: string;
8337
8327
  }, params?: RequestParams) => Promise<HttpResponse<List & {
8338
8328
  items: ChangeRequest[];
8339
8329
  }, any>>;
@@ -8442,6 +8432,25 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
8442
8432
  /** Optionally, provide a comment along with the review. */
8443
8433
  comment?: Document;
8444
8434
  }, params?: RequestParams) => Promise<HttpResponse<ChangeRequestReview, any>>;
8435
+ /**
8436
+ * No description
8437
+ *
8438
+ * @tags change-requests-reviews
8439
+ * @name GetChangeRequestReviewById
8440
+ * @summary Get a change request review by its ID
8441
+ * @request GET:/spaces/{spaceId}/change-requests/{changeRequestId}/reviews/{reviewId}
8442
+ * @secure
8443
+ */
8444
+ getChangeRequestReviewById: (spaceId: string, changeRequestId: string, reviewId: string, query?: {
8445
+ /** Output format for the content. */
8446
+ format?: "document" | "markdown";
8447
+ }, params?: RequestParams) => Promise<HttpResponse<ChangeRequestReview, {
8448
+ error: {
8449
+ /** @format int32 */
8450
+ code: 404;
8451
+ message: string;
8452
+ };
8453
+ }>>;
8445
8454
  /**
8446
8455
  * No description
8447
8456
  *
@@ -8688,7 +8697,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
8688
8697
  * @secure
8689
8698
  */
8690
8699
  getContributorsByChangeRequestId: (spaceId: string, changeRequestId: string, params?: RequestParams) => Promise<HttpResponse<List & {
8691
- items: UserContributor[];
8700
+ items: ChangeRequestUserContributor[];
8692
8701
  }, {
8693
8702
  error: {
8694
8703
  /** @format int32 */
@@ -8717,16 +8726,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
8717
8726
  */
8718
8727
  computed?: boolean;
8719
8728
  }, params?: RequestParams) => Promise<HttpResponse<Revision, any>>;
8720
- /**
8721
- * No description
8722
- *
8723
- * @tags change-request-content
8724
- * @name ImportContentInChangeRequest
8725
- * @summary Import content in a change request
8726
- * @request POST:/spaces/{spaceId}/change-requests/{changeRequestId}/content/import
8727
- * @secure
8728
- */
8729
- importContentInChangeRequest: (spaceId: string, changeRequestId: string, data: ImportContent, params?: RequestParams) => Promise<HttpResponse<ImportContentResult, any>>;
8730
8729
  /**
8731
8730
  * No description
8732
8731
  *
@@ -8897,47 +8896,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
8897
8896
  }, params?: RequestParams) => Promise<HttpResponse<List & {
8898
8897
  items: ContentLocation[];
8899
8898
  }, any>>;
8900
- /**
8901
- * No description
8902
- *
8903
- * @tags change-request-content
8904
- * @name ImportContentInChangeRequestPageById
8905
- * @summary Import content into a change request page
8906
- * @request POST:/spaces/{spaceId}/change-requests/{changeRequestId}/content/page/{pageId}/import
8907
- * @secure
8908
- */
8909
- importContentInChangeRequestPageById: (spaceId: string, changeRequestId: string, pageId: string, data: ImportContent, params?: RequestParams) => Promise<HttpResponse<ImportContentResult, any>>;
8910
- /**
8911
- * No description
8912
- *
8913
- * @tags change-request-content
8914
- * @name GetPageInChangeRequestByPath
8915
- * @summary Get a change request page by its path
8916
- * @request GET:/spaces/{spaceId}/change-requests/{changeRequestId}/content/path/{pagePath}
8917
- * @secure
8918
- */
8919
- getPageInChangeRequestByPath: (spaceId: string, changeRequestId: string, pagePath: string, query?: {
8920
- /** Output format for the content. */
8921
- format?: "document" | "markdown";
8922
- /**
8923
- * Controls whether the document should be evaluated.
8924
- * - When set to `true`, the entire document will be evaluated.
8925
- * - When set to `deterministic-only`, only expressions that depend
8926
- * exclusively on deterministic inputs will be evaluated.
8927
- * @default false
8928
- */
8929
- evaluated?: boolean | "deterministic-only";
8930
- /**
8931
- * If `false` is passed, "git" mutable metadata will not returned. Passing `false` can optimize performances of the lookup.
8932
- * @default true
8933
- */
8934
- metadata?: boolean;
8935
- /**
8936
- * If `false` is passed, content will not be computed
8937
- * @default true
8938
- */
8939
- computed?: boolean;
8940
- }, params?: RequestParams) => Promise<HttpResponse<RevisionPageDocument | RevisionPageGroup, any>>;
8941
8899
  /**
8942
8900
  * No description
8943
8901
  *
@@ -9202,6 +9160,37 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
9202
9160
  */
9203
9161
  computed?: boolean;
9204
9162
  }, params?: RequestParams) => Promise<HttpResponse<RevisionPageDocument | RevisionPageGroup, any>>;
9163
+ /**
9164
+ * No description
9165
+ *
9166
+ * @tags change-request-content
9167
+ * @name GetPageInChangeRequestByPath
9168
+ * @summary Get a change request page by its path
9169
+ * @request GET:/spaces/{spaceId}/change-requests/{changeRequestId}/content/path/{pagePath}
9170
+ * @secure
9171
+ */
9172
+ getPageInChangeRequestByPath: (spaceId: string, changeRequestId: string, pagePath: string, query?: {
9173
+ /** Output format for the content. */
9174
+ format?: "document" | "markdown";
9175
+ /**
9176
+ * Controls whether the document should be evaluated.
9177
+ * - When set to `true`, the entire document will be evaluated.
9178
+ * - When set to `deterministic-only`, only expressions that depend
9179
+ * exclusively on deterministic inputs will be evaluated.
9180
+ * @default false
9181
+ */
9182
+ evaluated?: boolean | "deterministic-only";
9183
+ /**
9184
+ * If `false` is passed, "git" mutable metadata will not returned. Passing `false` can optimize performances of the lookup.
9185
+ * @default true
9186
+ */
9187
+ metadata?: boolean;
9188
+ /**
9189
+ * If `false` is passed, content will not be computed
9190
+ * @default true
9191
+ */
9192
+ computed?: boolean;
9193
+ }, params?: RequestParams) => Promise<HttpResponse<RevisionPageDocument | RevisionPageGroup, any>>;
9205
9194
  /**
9206
9195
  * No description
9207
9196
  *
@@ -10886,6 +10875,10 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
10886
10875
  creator?: string;
10887
10876
  /** If defined, only change requests with contributions from this user will be returned. */
10888
10877
  contributor?: string;
10878
+ /** If defined, only change requests with a requested reviewer for this user will be returned. */
10879
+ requestedReviewer?: string;
10880
+ /** If defined, only change requests associated with this conversations issues cluster will be returned. */
10881
+ conversationsIssuesCluster?: string;
10889
10882
  }, params?: RequestParams) => Promise<HttpResponse<List & {
10890
10883
  items: ChangeRequest[];
10891
10884
  }, any>>;
@@ -11432,7 +11425,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
11432
11425
  /**
11433
11426
  * No description
11434
11427
  *
11435
- * @tags agents
11428
+ * @tags conversations
11436
11429
  * @name ListConversationsIssuesClusters
11437
11430
  * @summary List conversations issues clusters
11438
11431
  * @request GET:/orgs/{organizationId}/conversations-clusters
@@ -11478,13 +11471,13 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
11478
11471
  /**
11479
11472
  * No description
11480
11473
  *
11481
- * @tags agents
11482
- * @name ListConversationsIssuesInCluster
11483
- * @summary List conversations issues in a cluster
11484
- * @request GET:/orgs/{organizationId}/conversations-clusters/{clusterId}/issues
11474
+ * @tags conversations
11475
+ * @name ListConversations
11476
+ * @summary List conversations
11477
+ * @request GET:/orgs/{organizationId}/conversations
11485
11478
  * @secure
11486
11479
  */
11487
- listConversationsIssuesInCluster: (organizationId: string, clusterId: string, query?: {
11480
+ listConversations: (organizationId: string, query?: {
11488
11481
  /** Identifier of the page results to fetch. */
11489
11482
  page?: string;
11490
11483
  /**
@@ -11493,11 +11486,61 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
11493
11486
  * @max 1000
11494
11487
  */
11495
11488
  limit?: number;
11489
+ /** Filter conversations by their source identifier */
11490
+ source?: string;
11491
+ }, params?: RequestParams) => Promise<HttpResponse<List & {
11492
+ items: Conversation[];
11493
+ }, any>>;
11494
+ /**
11495
+ * No description
11496
+ *
11497
+ * @tags conversations
11498
+ * @name IngestConversation
11499
+ * @summary Ingest conversations
11500
+ * @request POST:/orgs/{organizationId}/conversations
11501
+ * @secure
11502
+ */
11503
+ ingestConversation: (organizationId: string, data: ConversationInput | ConversationInput[], params?: RequestParams) => Promise<HttpResponse<void, any>>;
11504
+ /**
11505
+ * No description
11506
+ *
11507
+ * @tags conversations
11508
+ * @name ListConversationsIssues
11509
+ * @summary List conversation issues
11510
+ * @request GET:/orgs/{organizationId}/conversations-issues
11511
+ * @secure
11512
+ */
11513
+ listConversationsIssues: (organizationId: string, query?: {
11514
+ /** Identifier of the page results to fetch. */
11515
+ page?: string;
11516
+ /**
11517
+ * The number of results per page
11518
+ * @min 0
11519
+ * @max 1000
11520
+ */
11521
+ limit?: number;
11522
+ /** Filter conversation issues by cluster identifier. */
11523
+ cluster?: string;
11524
+ /** Filter conversation issues by conversation identifier. */
11525
+ conversation?: string;
11496
11526
  }, params?: RequestParams) => Promise<HttpResponse<List & {
11497
11527
  items: {
11498
11528
  issue: ConversationIssue;
11499
11529
  conversation: Conversation;
11500
11530
  }[];
11531
+ }, any>>;
11532
+ /**
11533
+ * No description
11534
+ *
11535
+ * @tags conversations
11536
+ * @name GetConversationIssueById
11537
+ * @summary Get a conversation issue by ID
11538
+ * @request GET:/orgs/{organizationId}/conversations-issues/{issueId}
11539
+ * @secure
11540
+ */
11541
+ getConversationIssueById: (organizationId: string, issueId: string, params?: RequestParams) => Promise<HttpResponse<{
11542
+ issue: ConversationIssue;
11543
+ conversation: Conversation;
11501
11544
  }, {
11502
11545
  error: {
11503
11546
  /** @format int32 */
@@ -11509,12 +11552,22 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
11509
11552
  * No description
11510
11553
  *
11511
11554
  * @tags conversations
11512
- * @name IngestConversation
11513
- * @summary Ingest conversations
11514
- * @request POST:/orgs/{organizationId}/conversations
11555
+ * @name GetConversationById
11556
+ * @summary Get a conversation by ID
11557
+ * @request GET:/orgs/{organizationId}/conversations/{conversationId}
11515
11558
  * @secure
11516
11559
  */
11517
- ingestConversation: (organizationId: string, data: ConversationInput | ConversationInput[], params?: RequestParams) => Promise<HttpResponse<void, any>>;
11560
+ getConversationById: (organizationId: string, conversationId: string, params?: RequestParams) => Promise<HttpResponse<{
11561
+ conversation: Conversation;
11562
+ parts: ConversationPart[];
11563
+ metadata: ConversationMetadata;
11564
+ }, {
11565
+ error: {
11566
+ /** @format int32 */
11567
+ code: 404;
11568
+ message: string;
11569
+ };
11570
+ }>>;
11518
11571
  /**
11519
11572
  * @description Get the state of the agent.
11520
11573
  *
@@ -12931,8 +12984,6 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
12931
12984
  previousResponseId?: string;
12932
12985
  /** The messages to send to the AI agent. */
12933
12986
  input: AIMessageInput[];
12934
- /** @deprecated */
12935
- output?: AIOutputFormat;
12936
12987
  model?: AIModel;
12937
12988
  /** Custom tools to provide to the AI agent. */
12938
12989
  tools?: AIToolDefinition[];