@thinkai/tai-api-contract 2.219.0 → 2.221.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.
@@ -796,6 +796,108 @@ export interface paths {
796
796
  patch: operations["patchMyOrgChartMember"];
797
797
  trace?: never;
798
798
  };
799
+ "/workspaces/{workspaceId}/pm-mappings/suggestions": {
800
+ parameters: {
801
+ query?: never;
802
+ header?: never;
803
+ path?: never;
804
+ cookie?: never;
805
+ };
806
+ /**
807
+ * Suggest org-team ↔ PM entity mappings
808
+ * @description Returns name/key-matched suggestions between org-chart teams and connected PM entities (Jira projects, Linear teams, GitHub Issues repositories, Azure Boards teams). Soft-fails per provider when a source is missing or unreachable. ADR 004 / workspace #629.
809
+ */
810
+ get: operations["listPmMappingSuggestions"];
811
+ put?: never;
812
+ post?: never;
813
+ delete?: never;
814
+ options?: never;
815
+ head?: never;
816
+ patch?: never;
817
+ trace?: never;
818
+ };
819
+ "/workspaces/{workspaceId}/org-chart/teams/{teamId}/pm-mappings": {
820
+ parameters: {
821
+ query?: never;
822
+ header?: never;
823
+ path?: never;
824
+ cookie?: never;
825
+ };
826
+ /** List PM mappings for an org-chart team */
827
+ get: operations["listOrgTeamPmMappings"];
828
+ /**
829
+ * Confirm PM mappings for an org-chart team
830
+ * @description Replaces confirmed PM entity mappings for this org team. Prior confirmed rows for the team are marked inactive. Requires editor or admin workspace role.
831
+ */
832
+ put: operations["putOrgTeamPmMappings"];
833
+ post?: never;
834
+ delete?: never;
835
+ options?: never;
836
+ head?: never;
837
+ patch?: never;
838
+ trace?: never;
839
+ };
840
+ "/workspaces/{workspaceId}/pm-link-gaps": {
841
+ parameters: {
842
+ query?: never;
843
+ header?: never;
844
+ path?: never;
845
+ cookie?: never;
846
+ };
847
+ /**
848
+ * List ticket↔PR links missing a PM tool link
849
+ * @description Returns ticket↔PR associations known only via derived issue keys (`link_source=derived`), not an authoritative PM tool remote link. Used for admin gap surfacing (ADR 004).
850
+ */
851
+ get: operations["listPmLinkGaps"];
852
+ put?: never;
853
+ post?: never;
854
+ delete?: never;
855
+ options?: never;
856
+ head?: never;
857
+ patch?: never;
858
+ trace?: never;
859
+ };
860
+ "/workspaces/{workspaceId}/business-projects": {
861
+ parameters: {
862
+ query?: never;
863
+ header?: never;
864
+ path?: never;
865
+ cookie?: never;
866
+ };
867
+ /** List business projects */
868
+ get: operations["listBusinessProjects"];
869
+ put?: never;
870
+ /**
871
+ * Create or upsert a business project
872
+ * @description Upserts by workspace + slug. Requires editor or admin workspace role.
873
+ */
874
+ post: operations["postBusinessProject"];
875
+ delete?: never;
876
+ options?: never;
877
+ head?: never;
878
+ patch?: never;
879
+ trace?: never;
880
+ };
881
+ "/workspaces/{workspaceId}/insights/pm-roi": {
882
+ parameters: {
883
+ query?: never;
884
+ header?: never;
885
+ path?: never;
886
+ cookie?: never;
887
+ };
888
+ /**
889
+ * PM-attributed ROI
890
+ * @description Ticket/project-attributed AI ROI from confirmed PM mappings and ticket↔PR links (ADR 004). `available` is false when there are no confirmed mappings or no tool-linked PRs; breakdowns by org team and business project are included when mapped.
891
+ */
892
+ get: operations["getInsightsPmRoi"];
893
+ put?: never;
894
+ post?: never;
895
+ delete?: never;
896
+ options?: never;
897
+ head?: never;
898
+ patch?: never;
899
+ trace?: never;
900
+ };
799
901
  "/workspaces/{workspaceId}/config": {
800
902
  parameters: {
801
903
  query?: never;
@@ -4728,6 +4830,26 @@ export interface paths {
4728
4830
  patch?: never;
4729
4831
  trace?: never;
4730
4832
  };
4833
+ "/workspaces/{workspaceId}/code-chat/tools/ask": {
4834
+ parameters: {
4835
+ query?: never;
4836
+ header?: never;
4837
+ path?: never;
4838
+ cookie?: never;
4839
+ };
4840
+ get?: never;
4841
+ put?: never;
4842
+ /**
4843
+ * MCP/agent tool — grounded Ask answer with citations
4844
+ * @description Read-only. Runs the same Ask pipeline as Conversations for the repos in `repoIds` (every ready repo when `repoIds` is omitted). Does not edit files or open pull requests. The answer is `result.content` with `result.citations`. Other graph tools, when given more than one repo, return the same rows as a single repo plus `repoId` and `repoName`.
4845
+ */
4846
+ post: operations["codeChatAskTool"];
4847
+ delete?: never;
4848
+ options?: never;
4849
+ head?: never;
4850
+ patch?: never;
4851
+ trace?: never;
4852
+ };
4731
4853
  "/notifications/email/unsubscribe": {
4732
4854
  parameters: {
4733
4855
  query?: never;
@@ -6565,6 +6687,129 @@ export interface components {
6565
6687
  SonarQubeRepoMappingsValidateResponseDto: {
6566
6688
  results: components["schemas"]["SonarQubeRepoMappingValidateRowDto"][];
6567
6689
  };
6690
+ /**
6691
+ * @description Project-management connector used for team mapping and ticket↔PR links.
6692
+ * @enum {string}
6693
+ */
6694
+ PmProvider: "jira" | "linear" | "github_issues" | "azure_boards";
6695
+ PmTeamMappingDto: {
6696
+ /** Format: uuid */
6697
+ id: string;
6698
+ /** Format: uuid */
6699
+ workspaceId: string;
6700
+ orgTeamId: string;
6701
+ provider: components["schemas"]["PmProvider"];
6702
+ /** @description e.g. `project` (Jira), `team` (Linear). */
6703
+ pmEntityType: string;
6704
+ pmEntityId: string;
6705
+ pmEntityKey?: string | null;
6706
+ pmEntityName?: string | null;
6707
+ /** @enum {string} */
6708
+ status: "suggested" | "confirmed" | "inactive";
6709
+ /** Format: date-time */
6710
+ suggestedAt: string;
6711
+ /** Format: date-time */
6712
+ confirmedAt?: string | null;
6713
+ /** Format: date-time */
6714
+ updatedAt: string;
6715
+ };
6716
+ PmTeamMappingsListDto: {
6717
+ mappings: components["schemas"]["PmTeamMappingDto"][];
6718
+ };
6719
+ PmTeamMappingsPutDto: {
6720
+ mappings: {
6721
+ provider: components["schemas"]["PmProvider"];
6722
+ pmEntityType: string;
6723
+ pmEntityId: string;
6724
+ pmEntityKey?: string | null;
6725
+ pmEntityName?: string | null;
6726
+ }[];
6727
+ };
6728
+ PmMappingSuggestionDto: {
6729
+ orgTeamId: string;
6730
+ orgTeamName: string;
6731
+ provider: components["schemas"]["PmProvider"];
6732
+ pmEntityType: string;
6733
+ pmEntityId: string;
6734
+ pmEntityKey?: string | null;
6735
+ pmEntityName?: string | null;
6736
+ /**
6737
+ * @description Match quality between org team name and PM entity name/key.
6738
+ * @enum {string}
6739
+ */
6740
+ confidence: "exact" | "normalized";
6741
+ };
6742
+ PmLinkGapDto: {
6743
+ pmProvider: components["schemas"]["PmProvider"];
6744
+ ticketKey: string;
6745
+ ticketId?: string | null;
6746
+ /** @enum {string} */
6747
+ scmProvider: "github" | "gitlab" | "bitbucket";
6748
+ scmOwner?: string | null;
6749
+ scmRepo: string;
6750
+ prNumber: number;
6751
+ prUrl?: string | null;
6752
+ /** @enum {string} */
6753
+ linkSource: "derived";
6754
+ orgTeamId?: string | null;
6755
+ /** Format: date-time */
6756
+ updatedAt: string;
6757
+ };
6758
+ PmLinkGapsDto: {
6759
+ gaps: components["schemas"]["PmLinkGapDto"][];
6760
+ };
6761
+ BusinessProjectDto: {
6762
+ /**
6763
+ * Format: uuid
6764
+ * @description Present on responses; optional on create (server assigns).
6765
+ */
6766
+ id?: string;
6767
+ /** Format: uuid */
6768
+ workspaceId?: string;
6769
+ name: string;
6770
+ slug: string;
6771
+ pmProvider?: components["schemas"]["PmProvider"] | null;
6772
+ pmEntityType?: string | null;
6773
+ pmEntityId?: string | null;
6774
+ pmEntityKey?: string | null;
6775
+ orgTeamId?: string | null;
6776
+ /** @enum {string} */
6777
+ source?: "mirrored" | "override" | "manual";
6778
+ /** @enum {string} */
6779
+ status?: "active" | "archived";
6780
+ /** Format: date-time */
6781
+ createdAt?: string;
6782
+ /** Format: date-time */
6783
+ updatedAt?: string;
6784
+ };
6785
+ BusinessProjectsListDto: {
6786
+ projects: components["schemas"]["BusinessProjectDto"][];
6787
+ };
6788
+ /** @description PM-attributed ROI from confirmed mappings and ticket↔PR links (ADR 004). Empty breakdowns and `available: false` when no tool-linked PRs / mappings. */
6789
+ PmRoiDto: {
6790
+ /** Format: uuid */
6791
+ workspaceId: string;
6792
+ /** @description True when at least one confirmed mapping and one tool-linked PR exist. */
6793
+ available: boolean;
6794
+ metrics: {
6795
+ mappedTeamCount: number;
6796
+ toolLinkedPrCount: number;
6797
+ gapCount: number;
6798
+ attributedSpendUsd: number | null;
6799
+ };
6800
+ byOrgTeam: {
6801
+ orgTeamId: string;
6802
+ toolLinkedPrCount: number;
6803
+ attributedSpendUsd: number | null;
6804
+ }[];
6805
+ byBusinessProject: {
6806
+ /** Format: uuid */
6807
+ businessProjectId: string;
6808
+ name?: string | null;
6809
+ toolLinkedPrCount: number;
6810
+ attributedSpendUsd: number | null;
6811
+ }[];
6812
+ };
6568
6813
  /** @description PagerDuty incident monitoring source for `PUT /workspaces/{workspaceId}/sources` and `POST /workspaces/{workspaceId}/sources/test`. Requires a REST API v2 token (an "API Access Key" from PagerDuty → **Integrations → API Access Keys**). */
6569
6814
  PagerDutySourceDto: {
6570
6815
  /** @enum {string} */
@@ -6928,6 +7173,46 @@ export interface components {
6928
7173
  /** @description Linear workspace URL when known from the last successful verify. */
6929
7174
  workspaceUrl?: string;
6930
7175
  };
7176
+ /** @description GitHub Issues PM source for `PUT /workspaces/{workspaceId}/sources` and `POST /workspaces/{workspaceId}/sources/test`. Uses a GitHub PAT (or fine-grained token) with issues read access. Optional `repos` limits ingestion to listed `owner/repo` slugs (comma-separated string or array). */
7177
+ GitHubIssuesSourceDto: {
7178
+ /** @enum {string} */
7179
+ type: "github_issues";
7180
+ /** @description GitHub PAT / token (write-only on PUT). */
7181
+ token: string;
7182
+ /** @description Optional repo filter (`owner/repo` CSV string or array). */
7183
+ repos?: string | string[];
7184
+ };
7185
+ /** @description Redacted GitHub Issues source returned by `GET /workspaces/{workspaceId}/config`. Raw token is never returned. */
7186
+ GitHubIssuesSourceConfigDto: {
7187
+ /** @enum {string} */
7188
+ type: "github_issues";
7189
+ /** @description Whether a GitHub token is stored for this workspace. */
7190
+ hasToken: boolean;
7191
+ /** @description Configured repo filter when set. */
7192
+ repos?: string | string[];
7193
+ };
7194
+ /** @description Azure Boards PM source for `PUT /workspaces/{workspaceId}/sources` and `POST /workspaces/{workspaceId}/sources/test`. Requires organization URL, project name, and a personal access token (PAT). */
7195
+ AzureBoardsSourceDto: {
7196
+ /** @enum {string} */
7197
+ type: "azure_boards";
7198
+ /** @description Azure DevOps organization URL (e.g. `https://dev.azure.com/acme`). */
7199
+ orgUrl: string;
7200
+ /** @description Azure DevOps project name. */
7201
+ project: string;
7202
+ /** @description Azure DevOps personal access token (write-only on PUT). */
7203
+ pat: string;
7204
+ };
7205
+ /** @description Redacted Azure Boards source returned by `GET /workspaces/{workspaceId}/config`. Raw PAT is never returned. */
7206
+ AzureBoardsSourceConfigDto: {
7207
+ /** @enum {string} */
7208
+ type: "azure_boards";
7209
+ /** @description Whether a PAT is stored for this workspace. */
7210
+ hasToken: boolean;
7211
+ /** @description Configured Azure DevOps organization URL. */
7212
+ orgUrl: string;
7213
+ /** @description Configured Azure DevOps project name. */
7214
+ project: string;
7215
+ };
6931
7216
  /**
6932
7217
  * @description The agent execution account used for Agentic Foundation runs (readiness scanner + fix queue). Exactly one is active per workspace.
6933
7218
  * - `thinkai_platform_cursor`: ThinkAI platform Cursor key (Cursor Agent CLI) — opt-in, never default.
@@ -7043,7 +7328,7 @@ export interface components {
7043
7328
  topics?: components["schemas"]["CodeWikiGuidanceTopicDto"][];
7044
7329
  };
7045
7330
  WorkspaceConfigDto: {
7046
- sources: (components["schemas"]["CursorSourceConfigDto"] | components["schemas"]["ClaudeSourceConfigDto"] | components["schemas"]["CodeIntelligenceSourceConfigDto"] | components["schemas"]["NewRelicSourceConfigDto"] | components["schemas"]["DatadogSourceConfigDto"] | components["schemas"]["PrometheusSourceConfigDto"] | components["schemas"]["GrafanaSourceConfigDto"] | components["schemas"]["SonarQubeSourceConfigDto"] | components["schemas"]["PagerDutySourceConfigDto"] | components["schemas"]["SurveyMonkeySourceConfigDto"] | components["schemas"]["IncidentIoSourceConfigDto"] | components["schemas"]["SentrySourceConfigDto"] | components["schemas"]["JiraSourceConfigDto"] | components["schemas"]["LinearSourceConfigDto"] | components["schemas"]["TenantSourceEntryDto"])[];
7331
+ sources: (components["schemas"]["CursorSourceConfigDto"] | components["schemas"]["ClaudeSourceConfigDto"] | components["schemas"]["CodeIntelligenceSourceConfigDto"] | components["schemas"]["NewRelicSourceConfigDto"] | components["schemas"]["DatadogSourceConfigDto"] | components["schemas"]["PrometheusSourceConfigDto"] | components["schemas"]["GrafanaSourceConfigDto"] | components["schemas"]["SonarQubeSourceConfigDto"] | components["schemas"]["PagerDutySourceConfigDto"] | components["schemas"]["SurveyMonkeySourceConfigDto"] | components["schemas"]["IncidentIoSourceConfigDto"] | components["schemas"]["SentrySourceConfigDto"] | components["schemas"]["JiraSourceConfigDto"] | components["schemas"]["LinearSourceConfigDto"] | components["schemas"]["GitHubIssuesSourceConfigDto"] | components["schemas"]["AzureBoardsSourceConfigDto"] | components["schemas"]["TenantSourceEntryDto"])[];
7047
7332
  orgChart?: components["schemas"]["ScoringOrgChartDto"] | null;
7048
7333
  /** @enum {string|null} */
7049
7334
  region?: "us" | "eu" | "me" | null;
@@ -12661,6 +12946,15 @@ export interface components {
12661
12946
  intent?: "inventory_apis" | "inventory_modules";
12662
12947
  /** @description Previously uploaded attachment ids to bind to this user turn */
12663
12948
  attachmentIds?: string[];
12949
+ /** @description Slug of the wiki page the user has open. Prepended to Ask wiki context when the question is relevant to it or refers to it deictically ("explain this page"). */
12950
+ focusWikiSlug?: string;
12951
+ /**
12952
+ * Format: uuid
12953
+ * @description Repository of `focusWikiSlug` (slugs such as `overview` repeat across repos).
12954
+ */
12955
+ focusWikiRepoId?: string;
12956
+ /** @description When true the server replies with `text/event-stream` (`stage`, `token`, `done`, `error` events). The `done` event carries the same JSON as the non-streaming 200 body. */
12957
+ stream?: boolean;
12664
12958
  };
12665
12959
  CodeChatUploadAttachmentBodyDto: {
12666
12960
  filename: string;
@@ -13375,6 +13669,26 @@ export interface components {
13375
13669
  maxTokensApprox?: number;
13376
13670
  repoIds?: string[];
13377
13671
  };
13672
+ CodeChatAskToolBodyDto: {
13673
+ question: string;
13674
+ repoIds?: string[];
13675
+ };
13676
+ CodeChatAskToolResponseDto: {
13677
+ /** @enum {string} */
13678
+ tool: "ask";
13679
+ note?: string;
13680
+ scanned?: {
13681
+ [key: string]: unknown;
13682
+ }[];
13683
+ result: {
13684
+ content: string;
13685
+ mode: string;
13686
+ intent?: string;
13687
+ citations: {
13688
+ [key: string]: unknown;
13689
+ }[];
13690
+ };
13691
+ };
13378
13692
  CodeChatContextPackDto: {
13379
13693
  /** Format: uuid */
13380
13694
  repoId?: string;
@@ -14264,6 +14578,16 @@ export type SonarQubeRepoMappingsPutDto = components['schemas']['SonarQubeRepoMa
14264
14578
  export type SonarQubeRepoMappingsListDto = components['schemas']['SonarQubeRepoMappingsListDto'];
14265
14579
  export type SonarQubeRepoMappingValidateRowDto = components['schemas']['SonarQubeRepoMappingValidateRowDto'];
14266
14580
  export type SonarQubeRepoMappingsValidateResponseDto = components['schemas']['SonarQubeRepoMappingsValidateResponseDto'];
14581
+ export type PmProvider = components['schemas']['PmProvider'];
14582
+ export type PmTeamMappingDto = components['schemas']['PmTeamMappingDto'];
14583
+ export type PmTeamMappingsListDto = components['schemas']['PmTeamMappingsListDto'];
14584
+ export type PmTeamMappingsPutDto = components['schemas']['PmTeamMappingsPutDto'];
14585
+ export type PmMappingSuggestionDto = components['schemas']['PmMappingSuggestionDto'];
14586
+ export type PmLinkGapDto = components['schemas']['PmLinkGapDto'];
14587
+ export type PmLinkGapsDto = components['schemas']['PmLinkGapsDto'];
14588
+ export type BusinessProjectDto = components['schemas']['BusinessProjectDto'];
14589
+ export type BusinessProjectsListDto = components['schemas']['BusinessProjectsListDto'];
14590
+ export type PmRoiDto = components['schemas']['PmRoiDto'];
14267
14591
  export type PagerDutySourceDto = components['schemas']['PagerDutySourceDto'];
14268
14592
  export type PagerDutySourceConfigDto = components['schemas']['PagerDutySourceConfigDto'];
14269
14593
  export type SurveyMonkeySourceDto = components['schemas']['SurveyMonkeySourceDto'];
@@ -14287,6 +14611,10 @@ export type JiraSourceDto = components['schemas']['JiraSourceDto'];
14287
14611
  export type JiraSourceConfigDto = components['schemas']['JiraSourceConfigDto'];
14288
14612
  export type LinearSourceDto = components['schemas']['LinearSourceDto'];
14289
14613
  export type LinearSourceConfigDto = components['schemas']['LinearSourceConfigDto'];
14614
+ export type GitHubIssuesSourceDto = components['schemas']['GitHubIssuesSourceDto'];
14615
+ export type GitHubIssuesSourceConfigDto = components['schemas']['GitHubIssuesSourceConfigDto'];
14616
+ export type AzureBoardsSourceDto = components['schemas']['AzureBoardsSourceDto'];
14617
+ export type AzureBoardsSourceConfigDto = components['schemas']['AzureBoardsSourceConfigDto'];
14290
14618
  export type AgentExecutionProviderDto = components['schemas']['AgentExecutionProviderDto'];
14291
14619
  export type PutAgentExecutionProvidersDto = components['schemas']['PutAgentExecutionProvidersDto'];
14292
14620
  export type AgentExecutionSkipReasonDto = components['schemas']['AgentExecutionSkipReasonDto'];
@@ -14850,6 +15178,8 @@ export type CodeChatVisualizeResultDto = components['schemas']['CodeChatVisualiz
14850
15178
  export type CodeChatCrossEdgesBodyDto = components['schemas']['CodeChatCrossEdgesBodyDto'];
14851
15179
  export type CodeChatCrossEdgesResultDto = components['schemas']['CodeChatCrossEdgesResultDto'];
14852
15180
  export type CodeChatContextPackBodyDto = components['schemas']['CodeChatContextPackBodyDto'];
15181
+ export type CodeChatAskToolBodyDto = components['schemas']['CodeChatAskToolBodyDto'];
15182
+ export type CodeChatAskToolResponseDto = components['schemas']['CodeChatAskToolResponseDto'];
14853
15183
  export type CodeChatContextPackDto = components['schemas']['CodeChatContextPackDto'];
14854
15184
  export type CodeInsightsMetricProvenance = components['schemas']['CodeInsightsMetricProvenance'];
14855
15185
  export type CodeInsightsMaintainabilityBand = components['schemas']['CodeInsightsMaintainabilityBand'];
@@ -17471,6 +17801,215 @@ export interface operations {
17471
17801
  };
17472
17802
  };
17473
17803
  };
17804
+ listPmMappingSuggestions: {
17805
+ parameters: {
17806
+ query?: never;
17807
+ header?: never;
17808
+ path: {
17809
+ workspaceId: components["parameters"]["WorkspaceId"];
17810
+ };
17811
+ cookie?: never;
17812
+ };
17813
+ requestBody?: never;
17814
+ responses: {
17815
+ /** @description Mapping suggestions */
17816
+ 200: {
17817
+ headers: {
17818
+ [name: string]: unknown;
17819
+ };
17820
+ content: {
17821
+ "application/json": {
17822
+ suggestions: components["schemas"]["PmMappingSuggestionDto"][];
17823
+ };
17824
+ };
17825
+ };
17826
+ 401: components["responses"]["Unauthorized"];
17827
+ 403: components["responses"]["Forbidden"];
17828
+ };
17829
+ };
17830
+ listOrgTeamPmMappings: {
17831
+ parameters: {
17832
+ query?: never;
17833
+ header?: never;
17834
+ path: {
17835
+ workspaceId: components["parameters"]["WorkspaceId"];
17836
+ /** @description Org-chart team node id. */
17837
+ teamId: string;
17838
+ };
17839
+ cookie?: never;
17840
+ };
17841
+ requestBody?: never;
17842
+ responses: {
17843
+ /** @description Mappings for the team */
17844
+ 200: {
17845
+ headers: {
17846
+ [name: string]: unknown;
17847
+ };
17848
+ content: {
17849
+ "application/json": components["schemas"]["PmTeamMappingsListDto"];
17850
+ };
17851
+ };
17852
+ 401: components["responses"]["Unauthorized"];
17853
+ 403: components["responses"]["Forbidden"];
17854
+ };
17855
+ };
17856
+ putOrgTeamPmMappings: {
17857
+ parameters: {
17858
+ query?: never;
17859
+ header?: never;
17860
+ path: {
17861
+ workspaceId: components["parameters"]["WorkspaceId"];
17862
+ /** @description Org-chart team node id. */
17863
+ teamId: string;
17864
+ };
17865
+ cookie?: never;
17866
+ };
17867
+ requestBody: {
17868
+ content: {
17869
+ "application/json": components["schemas"]["PmTeamMappingsPutDto"];
17870
+ };
17871
+ };
17872
+ responses: {
17873
+ /** @description Updated mappings for the team */
17874
+ 200: {
17875
+ headers: {
17876
+ [name: string]: unknown;
17877
+ };
17878
+ content: {
17879
+ "application/json": components["schemas"]["PmTeamMappingsListDto"];
17880
+ };
17881
+ };
17882
+ /** @description Invalid request body */
17883
+ 400: {
17884
+ headers: {
17885
+ [name: string]: unknown;
17886
+ };
17887
+ content: {
17888
+ "application/json": components["schemas"]["ErrorMessageDto"];
17889
+ };
17890
+ };
17891
+ 401: components["responses"]["Unauthorized"];
17892
+ 403: components["responses"]["Forbidden"];
17893
+ /** @description PM entity is already confirmed for a different org team (`code: pm_entity_already_mapped`). */
17894
+ 409: {
17895
+ headers: {
17896
+ [name: string]: unknown;
17897
+ };
17898
+ content: {
17899
+ "application/json": components["schemas"]["ErrorMessageDto"];
17900
+ };
17901
+ };
17902
+ };
17903
+ };
17904
+ listPmLinkGaps: {
17905
+ parameters: {
17906
+ query?: never;
17907
+ header?: never;
17908
+ path: {
17909
+ workspaceId: components["parameters"]["WorkspaceId"];
17910
+ };
17911
+ cookie?: never;
17912
+ };
17913
+ requestBody?: never;
17914
+ responses: {
17915
+ /** @description Derived-only ticket↔PR gaps */
17916
+ 200: {
17917
+ headers: {
17918
+ [name: string]: unknown;
17919
+ };
17920
+ content: {
17921
+ "application/json": components["schemas"]["PmLinkGapsDto"];
17922
+ };
17923
+ };
17924
+ 401: components["responses"]["Unauthorized"];
17925
+ 403: components["responses"]["Forbidden"];
17926
+ };
17927
+ };
17928
+ listBusinessProjects: {
17929
+ parameters: {
17930
+ query?: never;
17931
+ header?: never;
17932
+ path: {
17933
+ workspaceId: components["parameters"]["WorkspaceId"];
17934
+ };
17935
+ cookie?: never;
17936
+ };
17937
+ requestBody?: never;
17938
+ responses: {
17939
+ /** @description Business projects for the workspace */
17940
+ 200: {
17941
+ headers: {
17942
+ [name: string]: unknown;
17943
+ };
17944
+ content: {
17945
+ "application/json": components["schemas"]["BusinessProjectsListDto"];
17946
+ };
17947
+ };
17948
+ 401: components["responses"]["Unauthorized"];
17949
+ 403: components["responses"]["Forbidden"];
17950
+ };
17951
+ };
17952
+ postBusinessProject: {
17953
+ parameters: {
17954
+ query?: never;
17955
+ header?: never;
17956
+ path: {
17957
+ workspaceId: components["parameters"]["WorkspaceId"];
17958
+ };
17959
+ cookie?: never;
17960
+ };
17961
+ requestBody: {
17962
+ content: {
17963
+ "application/json": components["schemas"]["BusinessProjectDto"];
17964
+ };
17965
+ };
17966
+ responses: {
17967
+ /** @description Upserted business project */
17968
+ 200: {
17969
+ headers: {
17970
+ [name: string]: unknown;
17971
+ };
17972
+ content: {
17973
+ "application/json": components["schemas"]["BusinessProjectDto"];
17974
+ };
17975
+ };
17976
+ /** @description Invalid request body */
17977
+ 400: {
17978
+ headers: {
17979
+ [name: string]: unknown;
17980
+ };
17981
+ content: {
17982
+ "application/json": components["schemas"]["ErrorMessageDto"];
17983
+ };
17984
+ };
17985
+ 401: components["responses"]["Unauthorized"];
17986
+ 403: components["responses"]["Forbidden"];
17987
+ };
17988
+ };
17989
+ getInsightsPmRoi: {
17990
+ parameters: {
17991
+ query?: never;
17992
+ header?: never;
17993
+ path: {
17994
+ workspaceId: components["parameters"]["WorkspaceId"];
17995
+ };
17996
+ cookie?: never;
17997
+ };
17998
+ requestBody?: never;
17999
+ responses: {
18000
+ /** @description PM ROI payload (empty metrics when unavailable) */
18001
+ 200: {
18002
+ headers: {
18003
+ [name: string]: unknown;
18004
+ };
18005
+ content: {
18006
+ "application/json": components["schemas"]["PmRoiDto"];
18007
+ };
18008
+ };
18009
+ 401: components["responses"]["Unauthorized"];
18010
+ 403: components["responses"]["Forbidden"];
18011
+ };
18012
+ };
17474
18013
  getWorkspaceConfig: {
17475
18014
  parameters: {
17476
18015
  query?: never;
@@ -18380,7 +18919,7 @@ export interface operations {
18380
18919
  requestBody: {
18381
18920
  content: {
18382
18921
  "application/json": {
18383
- sources: (components["schemas"]["CursorSourcePatchDto"] | components["schemas"]["CursorSourceDto"] | components["schemas"]["ClaudeSourcePatchDto"] | components["schemas"]["ClaudeSourceDto"] | components["schemas"]["CodeIntelligenceSourcePatchDto"] | components["schemas"]["NewRelicSourceDto"] | components["schemas"]["DatadogSourceDto"] | components["schemas"]["PrometheusSourceDto"] | components["schemas"]["GrafanaSourceDto"] | components["schemas"]["SonarQubeSourceDto"] | components["schemas"]["PagerDutySourceDto"] | components["schemas"]["SurveyMonkeySourceDto"] | components["schemas"]["IncidentIoSourceDto"] | components["schemas"]["SentrySourceDto"] | components["schemas"]["JiraSourceDto"] | components["schemas"]["LinearSourceDto"] | components["schemas"]["TenantSourceEntryDto"])[];
18922
+ sources: (components["schemas"]["CursorSourcePatchDto"] | components["schemas"]["CursorSourceDto"] | components["schemas"]["ClaudeSourcePatchDto"] | components["schemas"]["ClaudeSourceDto"] | components["schemas"]["CodeIntelligenceSourcePatchDto"] | components["schemas"]["NewRelicSourceDto"] | components["schemas"]["DatadogSourceDto"] | components["schemas"]["PrometheusSourceDto"] | components["schemas"]["GrafanaSourceDto"] | components["schemas"]["SonarQubeSourceDto"] | components["schemas"]["PagerDutySourceDto"] | components["schemas"]["SurveyMonkeySourceDto"] | components["schemas"]["IncidentIoSourceDto"] | components["schemas"]["SentrySourceDto"] | components["schemas"]["JiraSourceDto"] | components["schemas"]["LinearSourceDto"] | components["schemas"]["GitHubIssuesSourceDto"] | components["schemas"]["AzureBoardsSourceDto"] | components["schemas"]["TenantSourceEntryDto"])[];
18384
18923
  };
18385
18924
  };
18386
18925
  };
@@ -18434,7 +18973,7 @@ export interface operations {
18434
18973
  };
18435
18974
  requestBody: {
18436
18975
  content: {
18437
- "application/json": components["schemas"]["CursorSourcePatchDto"] | components["schemas"]["CursorSourceDto"] | components["schemas"]["ClaudeSourcePatchDto"] | components["schemas"]["ClaudeSourceDto"] | components["schemas"]["CodeIntelligenceSourcePatchDto"] | components["schemas"]["NewRelicSourceDto"] | components["schemas"]["DatadogSourceDto"] | components["schemas"]["PrometheusSourceDto"] | components["schemas"]["GrafanaSourceDto"] | components["schemas"]["SonarQubeSourceDto"] | components["schemas"]["PagerDutySourceDto"] | components["schemas"]["SurveyMonkeySourceDto"] | components["schemas"]["IncidentIoSourceDto"] | components["schemas"]["SentrySourceDto"] | components["schemas"]["JiraSourceDto"] | components["schemas"]["LinearSourceDto"] | components["schemas"]["TenantSourceEntryDto"];
18976
+ "application/json": components["schemas"]["CursorSourcePatchDto"] | components["schemas"]["CursorSourceDto"] | components["schemas"]["ClaudeSourcePatchDto"] | components["schemas"]["ClaudeSourceDto"] | components["schemas"]["CodeIntelligenceSourcePatchDto"] | components["schemas"]["NewRelicSourceDto"] | components["schemas"]["DatadogSourceDto"] | components["schemas"]["PrometheusSourceDto"] | components["schemas"]["GrafanaSourceDto"] | components["schemas"]["SonarQubeSourceDto"] | components["schemas"]["PagerDutySourceDto"] | components["schemas"]["SurveyMonkeySourceDto"] | components["schemas"]["IncidentIoSourceDto"] | components["schemas"]["SentrySourceDto"] | components["schemas"]["JiraSourceDto"] | components["schemas"]["LinearSourceDto"] | components["schemas"]["GitHubIssuesSourceDto"] | components["schemas"]["AzureBoardsSourceDto"] | components["schemas"]["TenantSourceEntryDto"];
18438
18977
  };
18439
18978
  };
18440
18979
  responses: {
@@ -26618,13 +27157,14 @@ export interface operations {
26618
27157
  };
26619
27158
  };
26620
27159
  responses: {
26621
- /** @description Assistant message */
27160
+ /** @description Assistant message. With `stream: true` the body is `text/event-stream`: `event: stage` (`{ stage, detail? }`), `event: token` (`{ text }`), `event: done` (CodeChatMessageReplyDto), or `event: error` (`{ error, code }`). */
26622
27161
  200: {
26623
27162
  headers: {
26624
27163
  [name: string]: unknown;
26625
27164
  };
26626
27165
  content: {
26627
27166
  "application/json": components["schemas"]["CodeChatMessageReplyDto"];
27167
+ "text/event-stream": string;
26628
27168
  };
26629
27169
  };
26630
27170
  401: components["responses"]["Unauthorized"];
@@ -27702,6 +28242,47 @@ export interface operations {
27702
28242
  };
27703
28243
  };
27704
28244
  };
28245
+ codeChatAskTool: {
28246
+ parameters: {
28247
+ query?: never;
28248
+ header?: never;
28249
+ path: {
28250
+ workspaceId: components["parameters"]["WorkspaceId"];
28251
+ };
28252
+ cookie?: never;
28253
+ };
28254
+ requestBody: {
28255
+ content: {
28256
+ "application/json": components["schemas"]["CodeChatAskToolBodyDto"];
28257
+ };
28258
+ };
28259
+ responses: {
28260
+ /** @description Grounded answer */
28261
+ 200: {
28262
+ headers: {
28263
+ [name: string]: unknown;
28264
+ };
28265
+ content: {
28266
+ "application/json": components["schemas"]["CodeChatAskToolResponseDto"];
28267
+ };
28268
+ };
28269
+ /** @description Missing or oversized question */
28270
+ 400: {
28271
+ headers: {
28272
+ [name: string]: unknown;
28273
+ };
28274
+ content?: never;
28275
+ };
28276
+ 401: components["responses"]["Unauthorized"];
28277
+ /** @description Corpus not ready */
28278
+ 409: {
28279
+ headers: {
28280
+ [name: string]: unknown;
28281
+ };
28282
+ content?: never;
28283
+ };
28284
+ };
28285
+ };
27705
28286
  getNotificationEmailUnsubscribe: {
27706
28287
  parameters: {
27707
28288
  query: {