@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.
@@ -1549,30 +1549,6 @@ export interface paths {
1549
1549
  patch?: never;
1550
1550
  trace?: never;
1551
1551
  };
1552
- "/workspaces/{workspaceId}/repo-eligibility": {
1553
- parameters: {
1554
- query?: never;
1555
- header?: never;
1556
- path?: never;
1557
- cookie?: never;
1558
- };
1559
- /**
1560
- * Get repo-sync eligibility gate (defaults + per-workspace overrides)
1561
- * @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.
1562
- */
1563
- get: operations["getWorkspaceRepoEligibility"];
1564
- /**
1565
- * Set per-workspace repo-sync eligibility overrides
1566
- * @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.
1567
- */
1568
- put: operations["putWorkspaceRepoEligibility"];
1569
- post?: never;
1570
- delete?: never;
1571
- options?: never;
1572
- head?: never;
1573
- patch?: never;
1574
- trace?: never;
1575
- };
1576
1552
  "/workspaces/{workspaceId}/readiness/cursor-key-usage": {
1577
1553
  parameters: {
1578
1554
  query?: never;
@@ -1753,6 +1729,24 @@ export interface paths {
1753
1729
  patch?: never;
1754
1730
  trace?: never;
1755
1731
  };
1732
+ "/me/consent": {
1733
+ parameters: {
1734
+ query?: never;
1735
+ header?: never;
1736
+ path?: never;
1737
+ cookie?: never;
1738
+ };
1739
+ /** Get cookie/storage consent for current user */
1740
+ get: operations["getMyConsent"];
1741
+ /** Upsert cookie/storage consent */
1742
+ put: operations["putMyConsent"];
1743
+ post?: never;
1744
+ delete?: never;
1745
+ options?: never;
1746
+ head?: never;
1747
+ patch?: never;
1748
+ trace?: never;
1749
+ };
1756
1750
  "/workspaces/{workspaceId}/org-chart/import": {
1757
1751
  parameters: {
1758
1752
  query?: never;
@@ -2782,56 +2776,6 @@ export interface components {
2782
2776
  * @description Last push or metadata update from GitHub when available.
2783
2777
  */
2784
2778
  updatedAt?: string | null;
2785
- /** @description True when the repository is archived (read-only on GitHub). */
2786
- archived?: boolean | null;
2787
- /** @description True when the repository is a fork of another repository. */
2788
- fork?: boolean | null;
2789
- /** @description True when the repository is disabled on GitHub. */
2790
- disabled?: boolean | null;
2791
- /** @description Repository size in KB as reported by GitHub. */
2792
- size?: number | null;
2793
- /** @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. */
2794
- readOnly?: boolean | null;
2795
- /** @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"). */
2796
- ineligibleReason?: string | null;
2797
- /**
2798
- * @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.
2799
- * @enum {string|null}
2800
- */
2801
- eligibilityStatus?: "eligible" | "ineligible" | null;
2802
- /** @description Human-readable explanation when `eligibilityStatus` is `ineligible` (e.g. "This repository's primary language (Python) is not supported in v1"). */
2803
- eligibilityReason?: string | null;
2804
- /** @description Dominant supported stack (by GitHub language bytes), one of backend_jvm | ios_app | web_spa | backend_go | backend_python. Null for ineligible repos. */
2805
- primaryStack?: string | null;
2806
- /** @description Second supported stack for a multi-stack repo, or null. */
2807
- secondaryStack?: string | null;
2808
- /** @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. */
2809
- supportedStacks?: string[] | null;
2810
- };
2811
- /** @description Resolved repo-sync eligibility gate (defaults or effective). All fields present. */
2812
- RepoEligibilityConfigDto: {
2813
- /** @description Skip archived repos during GitHub repo sync. */
2814
- excludeArchived: boolean;
2815
- /** @description Skip forked repos. Forks are included by default. */
2816
- excludeForks: boolean;
2817
- /** @description Max repo size in KB (GitHub-reported). 0 = no limit. */
2818
- maxRepoSizeKb: number;
2819
- /** @description Max repos materialized per workspace per sync. 0 = no limit. */
2820
- maxReposPerWorkspace: number;
2821
- };
2822
- /** @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. */
2823
- RepoEligibilityOverridesDto: {
2824
- excludeArchived?: boolean | null;
2825
- excludeForks?: boolean | null;
2826
- maxRepoSizeKb?: number | null;
2827
- maxReposPerWorkspace?: number | null;
2828
- };
2829
- WorkspaceRepoEligibilityDto: {
2830
- defaults: components["schemas"]["RepoEligibilityConfigDto"];
2831
- overrides: components["schemas"]["RepoEligibilityOverridesDto"];
2832
- effective: components["schemas"]["RepoEligibilityConfigDto"];
2833
- /** @description True when the caller is a platform admin (may set any value, incl. raising caps). */
2834
- canEditUnrestricted: boolean;
2835
2779
  };
2836
2780
  GithubMissingPermissionDto: {
2837
2781
  /** @description GitHub App permission key (e.g. contents, pull_requests). */
@@ -3230,7 +3174,7 @@ export interface components {
3230
3174
  scorePercent?: number;
3231
3175
  /** @description Per-criterion status counts from the latest successful scan */
3232
3176
  criteriaSummary?: components["schemas"]["ReadinessCriteriaSummaryDto"] | null;
3233
- /** @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. */
3177
+ /** @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. */
3234
3178
  criteriaDetails: components["schemas"]["CriterionDetailDto"][];
3235
3179
  issues: components["schemas"]["ReadinessIssueDto"][];
3236
3180
  };
@@ -3324,19 +3268,6 @@ export interface components {
3324
3268
  * @enum {string|null}
3325
3269
  */
3326
3270
  archivedReason?: "github_removed" | "installation_disconnected" | "installation_replaced" | "superseded" | null;
3327
- /**
3328
- * @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.
3329
- * @enum {string|null}
3330
- */
3331
- eligibilityStatus?: "eligible" | "ineligible" | null;
3332
- /** @description Human-readable explanation when `eligibilityStatus` is `ineligible`. */
3333
- eligibilityReason?: string | null;
3334
- /** @description Dominant supported stack — backend_jvm | ios_app | web_spa | backend_go | backend_python. Null when ineligible/uncomputed. */
3335
- primaryStack?: string | null;
3336
- /** @description Second supported stack for a multi-stack repo, or null. */
3337
- secondaryStack?: string | null;
3338
- /** @description All supported stacks detected (ordered, primary first). Empty/null when none. */
3339
- supportedStacks?: string[] | null;
3340
3271
  };
3341
3272
  /** @description Single-repo detail response. Identical to RepoReadinessScoreDto except dimensions use DimensionScoreDetailDto (criteriaDetails required per dimension). */
3342
3273
  RepoReadinessScoreDetailDto: {
@@ -3663,6 +3594,34 @@ export interface components {
3663
3594
  /** @description Temporary backward-compatibility alias (e.g. "Invalid timezone"). */
3664
3595
  legacyError?: string | null;
3665
3596
  };
3597
+ ConsentCategoriesDto: {
3598
+ /** @description Functional storage (preferences, onboarding, UI state). */
3599
+ functional: boolean;
3600
+ /** @description Analytics and product telemetry in the browser. */
3601
+ analytics: boolean;
3602
+ /** @description Advertising and remarketing tags. */
3603
+ marketing: boolean;
3604
+ };
3605
+ PutConsentBodyDto: {
3606
+ /** @description Cookie policy version the user consented to. */
3607
+ policyVersion: string;
3608
+ categories: components["schemas"]["ConsentCategoriesDto"];
3609
+ };
3610
+ ConsentRecordDto: {
3611
+ policyVersion: string;
3612
+ categories: components["schemas"]["ConsentCategoriesDto"];
3613
+ /**
3614
+ * Format: date-time
3615
+ * @description When consent was last recorded (UTC).
3616
+ */
3617
+ recordedAt: string;
3618
+ };
3619
+ ConsentValidationErrorDto: {
3620
+ /** @enum {string} */
3621
+ error: "ValidationError";
3622
+ issues: components["schemas"]["ValidationIssueDto"][];
3623
+ legacyError?: string | null;
3624
+ };
3666
3625
  OrgChartImportBodyDto: {
3667
3626
  /** @description Path in `org-charts` bucket after Supabase upload */
3668
3627
  storagePath: string;
@@ -3798,7 +3757,7 @@ export interface components {
3798
3757
  * @description Type of workspace lifecycle event.
3799
3758
  * @enum {string}
3800
3759
  */
3801
- 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";
3760
+ 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";
3802
3761
  ActivityLogActorDto: {
3803
3762
  /** Format: uuid */
3804
3763
  userId: string;
@@ -4169,9 +4128,6 @@ export type CreateWorkspaceBodyDto = components['schemas']['CreateWorkspaceBodyD
4169
4128
  export type CompanyProfileDto = components['schemas']['CompanyProfileDto'];
4170
4129
  export type GithubAccountDto = components['schemas']['GithubAccountDto'];
4171
4130
  export type GithubInstalledRepoDto = components['schemas']['GithubInstalledRepoDto'];
4172
- export type RepoEligibilityConfigDto = components['schemas']['RepoEligibilityConfigDto'];
4173
- export type RepoEligibilityOverridesDto = components['schemas']['RepoEligibilityOverridesDto'];
4174
- export type WorkspaceRepoEligibilityDto = components['schemas']['WorkspaceRepoEligibilityDto'];
4175
4131
  export type GithubMissingPermissionDto = components['schemas']['GithubMissingPermissionDto'];
4176
4132
  export type GithubInstallationSummaryDto = components['schemas']['GithubInstallationSummaryDto'];
4177
4133
  export type GithubPendingApprovalDto = components['schemas']['GithubPendingApprovalDto'];
@@ -4262,6 +4218,10 @@ export type NotificationPreferencesDto = components['schemas']['NotificationPref
4262
4218
  export type PreferencesDto = components['schemas']['PreferencesDto'];
4263
4219
  export type ValidationIssueDto = components['schemas']['ValidationIssueDto'];
4264
4220
  export type PreferencesValidationErrorDto = components['schemas']['PreferencesValidationErrorDto'];
4221
+ export type ConsentCategoriesDto = components['schemas']['ConsentCategoriesDto'];
4222
+ export type PutConsentBodyDto = components['schemas']['PutConsentBodyDto'];
4223
+ export type ConsentRecordDto = components['schemas']['ConsentRecordDto'];
4224
+ export type ConsentValidationErrorDto = components['schemas']['ConsentValidationErrorDto'];
4265
4225
  export type OrgChartImportBodyDto = components['schemas']['OrgChartImportBodyDto'];
4266
4226
  export type YourAiJourneyPrSignalsWeekDto = components['schemas']['YourAiJourneyPrSignalsWeekDto'];
4267
4227
  export type YourAiJourneyPrSignalsDto = components['schemas']['YourAiJourneyPrSignalsDto'];
@@ -7357,10 +7317,6 @@ export interface operations {
7357
7317
  offset?: components["parameters"]["PaginationOffset"];
7358
7318
  /** @description Sort direction. */
7359
7319
  order?: components["parameters"]["PaginationOrder"];
7360
- /** @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. */
7361
- sort?: "when" | "who" | "what" | "why" | "where";
7362
- /** @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. */
7363
- productArea?: "integration" | "agentic_foundation" | "workspace_team" | "all";
7364
7320
  /** @description Filter to a specific event type. */
7365
7321
  eventType?: components["schemas"]["ActivityLogEventTypeDto"];
7366
7322
  /** @description Filter to events performed by a specific user (UUID). */
@@ -8304,80 +8260,6 @@ export interface operations {
8304
8260
  403: components["responses"]["Forbidden"];
8305
8261
  };
8306
8262
  };
8307
- getWorkspaceRepoEligibility: {
8308
- parameters: {
8309
- query?: never;
8310
- header?: never;
8311
- path: {
8312
- workspaceId: components["parameters"]["WorkspaceId"];
8313
- };
8314
- cookie?: never;
8315
- };
8316
- requestBody?: never;
8317
- responses: {
8318
- /** @description Effective repo-eligibility configuration */
8319
- 200: {
8320
- headers: {
8321
- [name: string]: unknown;
8322
- };
8323
- content: {
8324
- "application/json": components["schemas"]["WorkspaceRepoEligibilityDto"];
8325
- };
8326
- };
8327
- 401: components["responses"]["Unauthorized"];
8328
- 403: components["responses"]["Forbidden"];
8329
- };
8330
- };
8331
- putWorkspaceRepoEligibility: {
8332
- parameters: {
8333
- query?: never;
8334
- header?: never;
8335
- path: {
8336
- workspaceId: components["parameters"]["WorkspaceId"];
8337
- };
8338
- cookie?: never;
8339
- };
8340
- requestBody: {
8341
- content: {
8342
- "application/json": {
8343
- overrides: components["schemas"]["RepoEligibilityOverridesDto"];
8344
- };
8345
- };
8346
- };
8347
- responses: {
8348
- /** @description Overrides saved */
8349
- 200: {
8350
- headers: {
8351
- [name: string]: unknown;
8352
- };
8353
- content: {
8354
- "application/json": {
8355
- overrides: components["schemas"]["RepoEligibilityOverridesDto"];
8356
- effective: components["schemas"]["RepoEligibilityConfigDto"];
8357
- };
8358
- };
8359
- };
8360
- /** @description Invalid request body */
8361
- 400: {
8362
- headers: {
8363
- [name: string]: unknown;
8364
- };
8365
- content: {
8366
- "application/json": components["schemas"]["ErrorMessageDto"];
8367
- };
8368
- };
8369
- 401: components["responses"]["Unauthorized"];
8370
- /** @description Forbidden, or a workspace-admin value exceeds a platform limit (`repo_eligibility_bound_exceeded`) */
8371
- 403: {
8372
- headers: {
8373
- [name: string]: unknown;
8374
- };
8375
- content: {
8376
- "application/json": components["schemas"]["ErrorMessageDto"];
8377
- };
8378
- };
8379
- };
8380
- };
8381
8263
  getCursorKeyUsage: {
8382
8264
  parameters: {
8383
8265
  query?: never;
@@ -8767,6 +8649,70 @@ export interface operations {
8767
8649
  401: components["responses"]["Unauthorized"];
8768
8650
  };
8769
8651
  };
8652
+ getMyConsent: {
8653
+ parameters: {
8654
+ query?: never;
8655
+ header?: never;
8656
+ path?: never;
8657
+ cookie?: never;
8658
+ };
8659
+ requestBody?: never;
8660
+ responses: {
8661
+ /** @description Consent record */
8662
+ 200: {
8663
+ headers: {
8664
+ [name: string]: unknown;
8665
+ };
8666
+ content: {
8667
+ "application/json": components["schemas"]["ConsentRecordDto"];
8668
+ };
8669
+ };
8670
+ 401: components["responses"]["Unauthorized"];
8671
+ /** @description No consent record stored yet */
8672
+ 404: {
8673
+ headers: {
8674
+ [name: string]: unknown;
8675
+ };
8676
+ content: {
8677
+ "application/json": components["schemas"]["ErrorMessageDto"];
8678
+ };
8679
+ };
8680
+ };
8681
+ };
8682
+ putMyConsent: {
8683
+ parameters: {
8684
+ query?: never;
8685
+ header?: never;
8686
+ path?: never;
8687
+ cookie?: never;
8688
+ };
8689
+ requestBody: {
8690
+ content: {
8691
+ "application/json": components["schemas"]["PutConsentBodyDto"];
8692
+ };
8693
+ };
8694
+ responses: {
8695
+ /** @description Saved consent record */
8696
+ 200: {
8697
+ headers: {
8698
+ [name: string]: unknown;
8699
+ };
8700
+ content: {
8701
+ "application/json": components["schemas"]["ConsentRecordDto"];
8702
+ };
8703
+ };
8704
+ /** @description Validation failed */
8705
+ 400: {
8706
+ headers: {
8707
+ [name: string]: unknown;
8708
+ };
8709
+ content: {
8710
+ "application/json": components["schemas"]["ConsentValidationErrorDto"];
8711
+ };
8712
+ };
8713
+ 401: components["responses"]["Unauthorized"];
8714
+ };
8715
+ };
8770
8716
  postOrgChartImport: {
8771
8717
  parameters: {
8772
8718
  query?: never;