@thinkai/tai-api-contract 2.82.0 → 2.84.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.
@@ -1171,7 +1171,7 @@ export interface paths {
1171
1171
  };
1172
1172
  /**
1173
1173
  * Insights recommendations — AI adoption gap by team
1174
- * @description Headcount vs AI-active contributors and per-team readiness/output. `readinessPct` is the mean latest overallScore of repos with matching `teamId` (workspace mean fallback). `outputPerEngPerWeek` is team merged PRs / headcount / weeks in window. `upliftPct` estimates additional PR volume if non-adopters matched leader-team output (teams with >50% adoption).
1174
+ * @description Headcount vs AI-active contributors and per-team output. Each team includes a `members` roster with `hasTrackedAiUsage` per org-chart person. `outputPerEngPerWeek` is team merged PRs / headcount / weeks in window. `upliftPct` estimates additional PR volume if non-adopters matched leader-team output (teams with >50% adoption).
1175
1175
  */
1176
1176
  get: operations["getInsightsRecommendationsAdoptionGap"];
1177
1177
  put?: never;
@@ -2122,6 +2122,28 @@ export interface paths {
2122
2122
  patch: operations["patchReadinessRepo"];
2123
2123
  trace?: never;
2124
2124
  };
2125
+ "/workspaces/{workspaceId}/readiness/repos/{repoId}/issues/export": {
2126
+ parameters: {
2127
+ query?: never;
2128
+ header?: never;
2129
+ path?: never;
2130
+ cookie?: never;
2131
+ };
2132
+ /**
2133
+ * Export repository readiness issues as Markdown
2134
+ * @description Download outstanding readiness issues for one repository as a Markdown (`.md`) attachment for local IDE workflows. Reuses the same scorecard as `GET .../readiness/repos/{repoId}` (issues plus optional remediation from `criteriaDetails`).
2135
+ * The Markdown is grouped **by readiness dimension** (catalog order). Each dimension section lists matching issues sorted by severity. Default filter is outstanding issues (`open` + `pr-pending`). Optional query params narrow the set. When `includeCriteria` is true (default), each issue includes a Remediation section from the matching criterion when available.
2136
+ * The response sets `Content-Disposition: attachment` with filename `readiness-issues-{providerSlug}-{date}.md`.
2137
+ */
2138
+ get: operations["exportReadinessRepoIssuesMarkdown"];
2139
+ put?: never;
2140
+ post?: never;
2141
+ delete?: never;
2142
+ options?: never;
2143
+ head?: never;
2144
+ patch?: never;
2145
+ trace?: never;
2146
+ };
2125
2147
  "/workspaces/{workspaceId}/readiness/repos/{repoId}/runs": {
2126
2148
  parameters: {
2127
2149
  query?: never;
@@ -7209,6 +7231,8 @@ export interface components {
7209
7231
  mergedPrs: number;
7210
7232
  costPerPrUsd: number;
7211
7233
  changePct: number;
7234
+ /** @description Weekly cost per merged PR aligned to the selected week buckets (same order as filters.weekBuckets). Null when the team had no merged PRs in that week. */
7235
+ trendUsdPerPr?: (number | null)[];
7212
7236
  };
7213
7237
  InsightsRecommendationsCostPerPr: {
7214
7238
  orgAvgCostUsd: number;
@@ -7218,13 +7242,21 @@ export interface components {
7218
7242
  InsightsRecommendationsCostPerPrResponse: components["schemas"]["InsightsRecommendationsCostPerPr"] & {
7219
7243
  _meta: components["schemas"]["InsightsResponseMeta"];
7220
7244
  };
7245
+ InsightsAdoptionMember: {
7246
+ /** @description Org-chart person id (typically work email). */
7247
+ personId: string;
7248
+ /** @description Display name from the org chart. */
7249
+ name: string;
7250
+ /** @description True when this person had synced AI daily usage or spend attributed to this team in the selected window (same team-scoped set as activeAi). */
7251
+ hasTrackedAiUsage: boolean;
7252
+ };
7221
7253
  InsightsAdoptionTeam: {
7222
7254
  id: string;
7223
7255
  name: string;
7224
7256
  activeAi: number;
7225
7257
  totalMembers: number;
7226
- readinessPct: number;
7227
7258
  outputPerEngPerWeek: number;
7259
+ members: components["schemas"]["InsightsAdoptionMember"][];
7228
7260
  };
7229
7261
  InsightsRecommendationsAdoptionGap: {
7230
7262
  totalContributors: number;
@@ -8246,6 +8278,7 @@ export type InsightsRecommendationsReviewPipelineResponse = components['schemas'
8246
8278
  export type InsightsCostPerPrTeam = components['schemas']['InsightsCostPerPrTeam'];
8247
8279
  export type InsightsRecommendationsCostPerPr = components['schemas']['InsightsRecommendationsCostPerPr'];
8248
8280
  export type InsightsRecommendationsCostPerPrResponse = components['schemas']['InsightsRecommendationsCostPerPrResponse'];
8281
+ export type InsightsAdoptionMember = components['schemas']['InsightsAdoptionMember'];
8249
8282
  export type InsightsAdoptionTeam = components['schemas']['InsightsAdoptionTeam'];
8250
8283
  export type InsightsRecommendationsAdoptionGap = components['schemas']['InsightsRecommendationsAdoptionGap'];
8251
8284
  export type InsightsRecommendationsAdoptionGapResponse = components['schemas']['InsightsRecommendationsAdoptionGapResponse'];
@@ -13882,6 +13915,56 @@ export interface operations {
13882
13915
  };
13883
13916
  };
13884
13917
  };
13918
+ exportReadinessRepoIssuesMarkdown: {
13919
+ parameters: {
13920
+ query?: {
13921
+ /** @description When omitted, export outstanding issues (`open` and `pr-pending`). When set, export only issues with this fix status. */
13922
+ fixStatus?: "open" | "pr-pending" | "fixed";
13923
+ dimensionId?: components["schemas"]["ReadinessDimensionId"];
13924
+ severity?: "critical" | "high" | "medium" | "low";
13925
+ /** @description Include remediation from criteriaDetails (default true). */
13926
+ includeCriteria?: boolean;
13927
+ };
13928
+ header?: never;
13929
+ path: {
13930
+ workspaceId: components["parameters"]["WorkspaceId"];
13931
+ repoId: components["parameters"]["RepoId"];
13932
+ };
13933
+ cookie?: never;
13934
+ };
13935
+ requestBody?: never;
13936
+ responses: {
13937
+ /** @description Markdown file of readiness issues */
13938
+ 200: {
13939
+ headers: {
13940
+ [name: string]: unknown;
13941
+ };
13942
+ content: {
13943
+ "text/markdown": string;
13944
+ };
13945
+ };
13946
+ /** @description Malformed `repoId` or invalid query parameters */
13947
+ 400: {
13948
+ headers: {
13949
+ [name: string]: unknown;
13950
+ };
13951
+ content: {
13952
+ "application/json": components["schemas"]["ErrorMessageDto"];
13953
+ };
13954
+ };
13955
+ 401: components["responses"]["Unauthorized"];
13956
+ 403: components["responses"]["Forbidden"];
13957
+ /** @description Workspace or repository not found */
13958
+ 404: {
13959
+ headers: {
13960
+ [name: string]: unknown;
13961
+ };
13962
+ content: {
13963
+ "application/json": components["schemas"]["ErrorMessageDto"];
13964
+ };
13965
+ };
13966
+ };
13967
+ };
13885
13968
  listReadinessRepoRuns: {
13886
13969
  parameters: {
13887
13970
  query?: {