@thinkai/tai-api-contract 2.32.1-pr.731.2 → 2.33.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.
@@ -1550,30 +1550,6 @@ export interface paths {
1550
1550
  patch?: never;
1551
1551
  trace?: never;
1552
1552
  };
1553
- "/workspaces/{workspaceId}/repo-eligibility": {
1554
- parameters: {
1555
- query?: never;
1556
- header?: never;
1557
- path?: never;
1558
- cookie?: never;
1559
- };
1560
- /**
1561
- * Get repo-sync eligibility gate (defaults + per-workspace overrides)
1562
- * @description Returns the effective repo-sync eligibility gate (archived / fork / size / count) for the workspace: the global `defaults`, any per-workspace `overrides`, the merged `effective` values, and whether the caller can edit without platform-admin (`canEditUnrestricted`). Member-level read access.
1563
- */
1564
- get: operations["getWorkspaceRepoEligibility"];
1565
- /**
1566
- * Set per-workspace repo-sync eligibility overrides
1567
- * @description Set (or clear, with an empty `overrides`) the per-workspace repo-sync eligibility overrides. **Platform admins** may set any value (raise caps, `0` = unlimited, include archived/forks). **Workspace admins** may only make the gate *more restrictive* than the platform defaults (lower caps, exclude archived/forks) — exceeding a platform limit returns `403` (`repo_eligibility_bound_exceeded`). Requires workspace admin or platform admin.
1568
- */
1569
- put: operations["putWorkspaceRepoEligibility"];
1570
- post?: never;
1571
- delete?: never;
1572
- options?: never;
1573
- head?: never;
1574
- patch?: never;
1575
- trace?: never;
1576
- };
1577
1553
  "/workspaces/{workspaceId}/readiness/cursor-key-usage": {
1578
1554
  parameters: {
1579
1555
  query?: never;
@@ -1754,6 +1730,24 @@ export interface paths {
1754
1730
  patch?: never;
1755
1731
  trace?: never;
1756
1732
  };
1733
+ "/me/consent": {
1734
+ parameters: {
1735
+ query?: never;
1736
+ header?: never;
1737
+ path?: never;
1738
+ cookie?: never;
1739
+ };
1740
+ /** Get cookie/storage consent for current user */
1741
+ get: operations["getMyConsent"];
1742
+ /** Upsert cookie/storage consent */
1743
+ put: operations["putMyConsent"];
1744
+ post?: never;
1745
+ delete?: never;
1746
+ options?: never;
1747
+ head?: never;
1748
+ patch?: never;
1749
+ trace?: never;
1750
+ };
1757
1751
  "/workspaces/{workspaceId}/org-chart/import": {
1758
1752
  parameters: {
1759
1753
  query?: never;
@@ -2783,56 +2777,6 @@ export interface components {
2783
2777
  * @description Last push or metadata update from GitHub when available.
2784
2778
  */
2785
2779
  updatedAt?: string | null;
2786
- /** @description True when the repository is archived (read-only on GitHub). */
2787
- archived?: boolean | null;
2788
- /** @description True when the repository is a fork of another repository. */
2789
- fork?: boolean | null;
2790
- /** @description True when the repository is disabled on GitHub. */
2791
- disabled?: boolean | null;
2792
- /** @description Repository size in KB as reported by GitHub. */
2793
- size?: number | null;
2794
- /** @description True when the GitHub App installation lacks push access to this repo (read-only). Read-only repos are rejected during sync because readiness fixes require write access. */
2795
- readOnly?: boolean | null;
2796
- /** @description Set when this repo was skipped during sync due to an eligibility check. The frontend should display this as an inline explanation (e.g. "This repo is archived"). */
2797
- ineligibleReason?: string | null;
2798
- /**
2799
- * @description Language-based eligibility for Agentic-Foundation readiness analysis (issue #44). `ineligible` repos (no supported stack) render read-only/orange in the AF list with no analyze/score/fix actions. Mixed monorepos with a supported secondary stack are `eligible`. Distinct from `ineligibleReason`, which reflects the structural sync gate.
2800
- * @enum {string|null}
2801
- */
2802
- eligibilityStatus?: "eligible" | "ineligible" | null;
2803
- /** @description Human-readable explanation when `eligibilityStatus` is `ineligible` (e.g. "This repository's primary language (Python) is not supported in v1"). */
2804
- eligibilityReason?: string | null;
2805
- /** @description Dominant supported stack (by GitHub language bytes), one of backend_jvm | ios_app | web_spa | backend_go | backend_python. Null for ineligible repos. */
2806
- primaryStack?: string | null;
2807
- /** @description Second supported stack for a multi-stack repo, or null. */
2808
- secondaryStack?: string | null;
2809
- /** @description All supported stacks detected for the repo (ordered, primary first). Empty/null when no supported stack is present. Drives multi-stack scanning and the orange mixed-monorepo box in the AF UI. */
2810
- supportedStacks?: string[] | null;
2811
- };
2812
- /** @description Resolved repo-sync eligibility gate (defaults or effective). All fields present. */
2813
- RepoEligibilityConfigDto: {
2814
- /** @description Skip archived repos during GitHub repo sync. */
2815
- excludeArchived: boolean;
2816
- /** @description Skip forked repos. Forks are included by default. */
2817
- excludeForks: boolean;
2818
- /** @description Max repo size in KB (GitHub-reported). 0 = no limit. */
2819
- maxRepoSizeKb: number;
2820
- /** @description Max repos materialized per workspace per sync. 0 = no limit. */
2821
- maxReposPerWorkspace: number;
2822
- };
2823
- /** @description Per-workspace overrides for the repo-sync eligibility gate. Any field present wins over the global default; omit a field to inherit the default. An empty object clears all overrides. */
2824
- RepoEligibilityOverridesDto: {
2825
- excludeArchived?: boolean | null;
2826
- excludeForks?: boolean | null;
2827
- maxRepoSizeKb?: number | null;
2828
- maxReposPerWorkspace?: number | null;
2829
- };
2830
- WorkspaceRepoEligibilityDto: {
2831
- defaults: components["schemas"]["RepoEligibilityConfigDto"];
2832
- overrides: components["schemas"]["RepoEligibilityOverridesDto"];
2833
- effective: components["schemas"]["RepoEligibilityConfigDto"];
2834
- /** @description True when the caller is a platform admin (may set any value, incl. raising caps). */
2835
- canEditUnrestricted: boolean;
2836
2780
  };
2837
2781
  GithubMissingPermissionDto: {
2838
2782
  /** @description GitHub App permission key (e.g. contents, pull_requests). */
@@ -3231,7 +3175,7 @@ export interface components {
3231
3175
  scorePercent?: number;
3232
3176
  /** @description Per-criterion status counts from the latest successful scan */
3233
3177
  criteriaSummary?: components["schemas"]["ReadinessCriteriaSummaryDto"] | null;
3234
- /** @description Individual rubric criterion outcomes from the latest successful scan. Always present on the single-repo detail endpoint; empty array when no scan has completed yet for this dimension. */
3178
+ /** @description Individual rubric criterion outcomes from the latest successful scan. Always present on the single-repo detail endpoint. When the repo has a succeeded scan but a dimension was not evaluated (e.g. Section I on older runs), the API returns full rubric placeholders with status `blocked`. Empty array only when the repo has no succeeded scan yet. */
3235
3179
  criteriaDetails: components["schemas"]["CriterionDetailDto"][];
3236
3180
  issues: components["schemas"]["ReadinessIssueDto"][];
3237
3181
  };
@@ -3325,19 +3269,6 @@ export interface components {
3325
3269
  * @enum {string|null}
3326
3270
  */
3327
3271
  archivedReason?: "github_removed" | "installation_disconnected" | "installation_replaced" | "superseded" | null;
3328
- /**
3329
- * @description Language-based eligibility for Agentic-Foundation analysis (#44). `ineligible` repos (no v1-supported stack) render read-only/orange in the AF list with no analyze/score/fix actions; the server also rejects analyze requests for them. Null until the first sync/scan computes it.
3330
- * @enum {string|null}
3331
- */
3332
- eligibilityStatus?: "eligible" | "ineligible" | null;
3333
- /** @description Human-readable explanation when `eligibilityStatus` is `ineligible`. */
3334
- eligibilityReason?: string | null;
3335
- /** @description Dominant supported stack — backend_jvm | ios_app | web_spa | backend_go | backend_python. Null when ineligible/uncomputed. */
3336
- primaryStack?: string | null;
3337
- /** @description Second supported stack for a multi-stack repo, or null. */
3338
- secondaryStack?: string | null;
3339
- /** @description All supported stacks detected (ordered, primary first). Empty/null when none. */
3340
- supportedStacks?: string[] | null;
3341
3272
  };
3342
3273
  /** @description Single-repo detail response. Identical to RepoReadinessScoreDto except dimensions use DimensionScoreDetailDto (criteriaDetails required per dimension). */
3343
3274
  RepoReadinessScoreDetailDto: {
@@ -3664,6 +3595,34 @@ export interface components {
3664
3595
  /** @description Temporary backward-compatibility alias (e.g. "Invalid timezone"). */
3665
3596
  legacyError?: string | null;
3666
3597
  };
3598
+ ConsentCategoriesDto: {
3599
+ /** @description Functional storage (preferences, onboarding, UI state). */
3600
+ functional: boolean;
3601
+ /** @description Analytics and product telemetry in the browser. */
3602
+ analytics: boolean;
3603
+ /** @description Advertising and remarketing tags. */
3604
+ marketing: boolean;
3605
+ };
3606
+ PutConsentBodyDto: {
3607
+ /** @description Cookie policy version the user consented to. */
3608
+ policyVersion: string;
3609
+ categories: components["schemas"]["ConsentCategoriesDto"];
3610
+ };
3611
+ ConsentRecordDto: {
3612
+ policyVersion: string;
3613
+ categories: components["schemas"]["ConsentCategoriesDto"];
3614
+ /**
3615
+ * Format: date-time
3616
+ * @description When consent was last recorded (UTC).
3617
+ */
3618
+ recordedAt: string;
3619
+ };
3620
+ ConsentValidationErrorDto: {
3621
+ /** @enum {string} */
3622
+ error: "ValidationError";
3623
+ issues: components["schemas"]["ValidationIssueDto"][];
3624
+ legacyError?: string | null;
3625
+ };
3667
3626
  OrgChartImportBodyDto: {
3668
3627
  /** @description Path in `org-charts` bucket after Supabase upload */
3669
3628
  storagePath: string;
@@ -3799,7 +3758,7 @@ export interface components {
3799
3758
  * @description Type of workspace lifecycle event.
3800
3759
  * @enum {string}
3801
3760
  */
3802
- ActivityLogEventTypeDto: "repo.added" | "repo.removed" | "repo.readded" | "integration.github.added" | "integration.github.updated" | "integration.github.removed" | "integration.github.permissions_changed" | "integration.github.repo_added" | "integration.github.repo_removed" | "fix.requested" | "fix.generating" | "fix.pr_created" | "fix.merged" | "fix.failed" | "readiness.scan_started" | "readiness.scan_completed" | "readiness.scan_failed" | "readiness.scan_partial" | "integrations.agent_execution.provider_changed" | "integrations.repo_eligibility.overrides_changed" | "integrations.cursor.platform_key_enabled" | "integrations.cursor.platform_key_disabled" | "member.invited" | "member.role_changed" | "member.removed" | "repo.sync_skipped" | "integrations.cursor.execution_key.added" | "integrations.cursor.execution_key.updated" | "integrations.cursor.execution_key.removed" | "integrations.cursor.execution_key.check_failed" | "integrations.cursor.admin_key.added" | "integrations.cursor.admin_key.updated" | "integrations.cursor.admin_key.removed" | "integrations.claude.execution_key.added" | "integrations.claude.execution_key.updated" | "integrations.claude.execution_key.removed" | "integrations.claude.execution_key.check_failed" | "integrations.claude.admin_key.added" | "integrations.claude.admin_key.updated" | "integrations.claude.admin_key.removed" | "readiness.scan_precheck_failed";
3761
+ ActivityLogEventTypeDto: "repo.added" | "repo.removed" | "repo.readded" | "integration.github.added" | "integration.github.updated" | "integration.github.removed" | "integration.github.permissions_changed" | "integration.github.repo_added" | "integration.github.repo_removed" | "fix.requested" | "fix.generating" | "fix.pr_created" | "fix.merged" | "fix.failed" | "readiness.scan_started" | "readiness.scan_completed" | "readiness.scan_failed" | "readiness.scan_partial" | "config.cursor.added" | "config.cursor.updated" | "config.cursor.removed" | "config.cursor.platform_key_enabled" | "config.cursor.platform_key_disabled" | "config.claude.added" | "config.claude.updated" | "config.claude.removed" | "config.agent_execution.provider_changed" | "member.invited" | "member.role_changed" | "member.removed";
3803
3762
  ActivityLogActorDto: {
3804
3763
  /** Format: uuid */
3805
3764
  userId: string;
@@ -4170,9 +4129,6 @@ export type CreateWorkspaceBodyDto = components['schemas']['CreateWorkspaceBodyD
4170
4129
  export type CompanyProfileDto = components['schemas']['CompanyProfileDto'];
4171
4130
  export type GithubAccountDto = components['schemas']['GithubAccountDto'];
4172
4131
  export type GithubInstalledRepoDto = components['schemas']['GithubInstalledRepoDto'];
4173
- export type RepoEligibilityConfigDto = components['schemas']['RepoEligibilityConfigDto'];
4174
- export type RepoEligibilityOverridesDto = components['schemas']['RepoEligibilityOverridesDto'];
4175
- export type WorkspaceRepoEligibilityDto = components['schemas']['WorkspaceRepoEligibilityDto'];
4176
4132
  export type GithubMissingPermissionDto = components['schemas']['GithubMissingPermissionDto'];
4177
4133
  export type GithubInstallationSummaryDto = components['schemas']['GithubInstallationSummaryDto'];
4178
4134
  export type GithubPendingApprovalDto = components['schemas']['GithubPendingApprovalDto'];
@@ -4263,6 +4219,10 @@ export type NotificationPreferencesDto = components['schemas']['NotificationPref
4263
4219
  export type PreferencesDto = components['schemas']['PreferencesDto'];
4264
4220
  export type ValidationIssueDto = components['schemas']['ValidationIssueDto'];
4265
4221
  export type PreferencesValidationErrorDto = components['schemas']['PreferencesValidationErrorDto'];
4222
+ export type ConsentCategoriesDto = components['schemas']['ConsentCategoriesDto'];
4223
+ export type PutConsentBodyDto = components['schemas']['PutConsentBodyDto'];
4224
+ export type ConsentRecordDto = components['schemas']['ConsentRecordDto'];
4225
+ export type ConsentValidationErrorDto = components['schemas']['ConsentValidationErrorDto'];
4266
4226
  export type OrgChartImportBodyDto = components['schemas']['OrgChartImportBodyDto'];
4267
4227
  export type YourAiJourneyPrSignalsWeekDto = components['schemas']['YourAiJourneyPrSignalsWeekDto'];
4268
4228
  export type YourAiJourneyPrSignalsDto = components['schemas']['YourAiJourneyPrSignalsDto'];
@@ -7358,10 +7318,6 @@ export interface operations {
7358
7318
  offset?: components["parameters"]["PaginationOffset"];
7359
7319
  /** @description Sort direction. */
7360
7320
  order?: components["parameters"]["PaginationOrder"];
7361
- /** @description Server-side sort column (the activity "5 W's"). Combined with `order` (asc/desc). Defaults to `when` (occurredAt). `occurredAt`/`id` is always the tiebreaker. */
7362
- sort?: "when" | "who" | "what" | "why" | "where";
7363
- /** @description Coarse product-area grouping filter (#156). `integration` = GitHub + AI-tool key events; `agentic_foundation` = repos, readiness scans, fixes; `workspace_team` = members + HRIS. Omit (or pass `all`) for every area. */
7364
- productArea?: "integration" | "agentic_foundation" | "workspace_team" | "all";
7365
7321
  /** @description Filter to a specific event type. */
7366
7322
  eventType?: components["schemas"]["ActivityLogEventTypeDto"];
7367
7323
  /** @description Filter to events performed by a specific user (UUID). */
@@ -8305,80 +8261,6 @@ export interface operations {
8305
8261
  403: components["responses"]["Forbidden"];
8306
8262
  };
8307
8263
  };
8308
- getWorkspaceRepoEligibility: {
8309
- parameters: {
8310
- query?: never;
8311
- header?: never;
8312
- path: {
8313
- workspaceId: components["parameters"]["WorkspaceId"];
8314
- };
8315
- cookie?: never;
8316
- };
8317
- requestBody?: never;
8318
- responses: {
8319
- /** @description Effective repo-eligibility configuration */
8320
- 200: {
8321
- headers: {
8322
- [name: string]: unknown;
8323
- };
8324
- content: {
8325
- "application/json": components["schemas"]["WorkspaceRepoEligibilityDto"];
8326
- };
8327
- };
8328
- 401: components["responses"]["Unauthorized"];
8329
- 403: components["responses"]["Forbidden"];
8330
- };
8331
- };
8332
- putWorkspaceRepoEligibility: {
8333
- parameters: {
8334
- query?: never;
8335
- header?: never;
8336
- path: {
8337
- workspaceId: components["parameters"]["WorkspaceId"];
8338
- };
8339
- cookie?: never;
8340
- };
8341
- requestBody: {
8342
- content: {
8343
- "application/json": {
8344
- overrides: components["schemas"]["RepoEligibilityOverridesDto"];
8345
- };
8346
- };
8347
- };
8348
- responses: {
8349
- /** @description Overrides saved */
8350
- 200: {
8351
- headers: {
8352
- [name: string]: unknown;
8353
- };
8354
- content: {
8355
- "application/json": {
8356
- overrides: components["schemas"]["RepoEligibilityOverridesDto"];
8357
- effective: components["schemas"]["RepoEligibilityConfigDto"];
8358
- };
8359
- };
8360
- };
8361
- /** @description Invalid request body */
8362
- 400: {
8363
- headers: {
8364
- [name: string]: unknown;
8365
- };
8366
- content: {
8367
- "application/json": components["schemas"]["ErrorMessageDto"];
8368
- };
8369
- };
8370
- 401: components["responses"]["Unauthorized"];
8371
- /** @description Forbidden, or a workspace-admin value exceeds a platform limit (`repo_eligibility_bound_exceeded`) */
8372
- 403: {
8373
- headers: {
8374
- [name: string]: unknown;
8375
- };
8376
- content: {
8377
- "application/json": components["schemas"]["ErrorMessageDto"];
8378
- };
8379
- };
8380
- };
8381
- };
8382
8264
  getCursorKeyUsage: {
8383
8265
  parameters: {
8384
8266
  query?: never;
@@ -8768,6 +8650,70 @@ export interface operations {
8768
8650
  401: components["responses"]["Unauthorized"];
8769
8651
  };
8770
8652
  };
8653
+ getMyConsent: {
8654
+ parameters: {
8655
+ query?: never;
8656
+ header?: never;
8657
+ path?: never;
8658
+ cookie?: never;
8659
+ };
8660
+ requestBody?: never;
8661
+ responses: {
8662
+ /** @description Consent record */
8663
+ 200: {
8664
+ headers: {
8665
+ [name: string]: unknown;
8666
+ };
8667
+ content: {
8668
+ "application/json": components["schemas"]["ConsentRecordDto"];
8669
+ };
8670
+ };
8671
+ 401: components["responses"]["Unauthorized"];
8672
+ /** @description No consent record stored yet */
8673
+ 404: {
8674
+ headers: {
8675
+ [name: string]: unknown;
8676
+ };
8677
+ content: {
8678
+ "application/json": components["schemas"]["ErrorMessageDto"];
8679
+ };
8680
+ };
8681
+ };
8682
+ };
8683
+ putMyConsent: {
8684
+ parameters: {
8685
+ query?: never;
8686
+ header?: never;
8687
+ path?: never;
8688
+ cookie?: never;
8689
+ };
8690
+ requestBody: {
8691
+ content: {
8692
+ "application/json": components["schemas"]["PutConsentBodyDto"];
8693
+ };
8694
+ };
8695
+ responses: {
8696
+ /** @description Saved consent record */
8697
+ 200: {
8698
+ headers: {
8699
+ [name: string]: unknown;
8700
+ };
8701
+ content: {
8702
+ "application/json": components["schemas"]["ConsentRecordDto"];
8703
+ };
8704
+ };
8705
+ /** @description Validation failed */
8706
+ 400: {
8707
+ headers: {
8708
+ [name: string]: unknown;
8709
+ };
8710
+ content: {
8711
+ "application/json": components["schemas"]["ConsentValidationErrorDto"];
8712
+ };
8713
+ };
8714
+ 401: components["responses"]["Unauthorized"];
8715
+ };
8716
+ };
8771
8717
  postOrgChartImport: {
8772
8718
  parameters: {
8773
8719
  query?: never;