@thinkai/tai-api-contract 2.166.0 → 2.168.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/generated/openapi.d.ts +230 -1
- package/dist/generated/openapi.d.ts.map +1 -1
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/openapi/openapi.yaml +204 -2
- package/package.json +1 -1
- package/src/generated/openapi.ts +230 -1
- package/src/index.ts +11 -0
|
@@ -24,6 +24,27 @@ export interface paths {
|
|
|
24
24
|
patch?: never;
|
|
25
25
|
trace?: never;
|
|
26
26
|
};
|
|
27
|
+
"/admin/users/{userId}/assessment-order": {
|
|
28
|
+
parameters: {
|
|
29
|
+
query?: never;
|
|
30
|
+
header?: never;
|
|
31
|
+
path?: never;
|
|
32
|
+
cookie?: never;
|
|
33
|
+
};
|
|
34
|
+
get?: never;
|
|
35
|
+
/**
|
|
36
|
+
* Authorize one extra assessment workspace
|
|
37
|
+
* @description Sets `tai_users.assessment_order_authorized`. When true, that account may create one workspace beyond the default single-workspace limit. The flag stays set until an operator clears it. Buyers cannot set it on `POST /workspaces`.
|
|
38
|
+
* **Authorization:** Bearer JWT required. Caller email must appear in `PLATFORM_ADMIN_EMAILS`. All other callers receive `403 Forbidden`.
|
|
39
|
+
*/
|
|
40
|
+
put: operations["adminSetAssessmentOrder"];
|
|
41
|
+
post?: never;
|
|
42
|
+
delete?: never;
|
|
43
|
+
options?: never;
|
|
44
|
+
head?: never;
|
|
45
|
+
patch?: never;
|
|
46
|
+
trace?: never;
|
|
47
|
+
};
|
|
27
48
|
"/admin/readiness/token-usage": {
|
|
28
49
|
parameters: {
|
|
29
50
|
query?: never;
|
|
@@ -4638,6 +4659,30 @@ export interface paths {
|
|
|
4638
4659
|
patch?: never;
|
|
4639
4660
|
trace?: never;
|
|
4640
4661
|
};
|
|
4662
|
+
"/workspaces/{workspaceId}/ingest/productivity/dual-vcs-cutover": {
|
|
4663
|
+
parameters: {
|
|
4664
|
+
query?: never;
|
|
4665
|
+
header?: never;
|
|
4666
|
+
path?: never;
|
|
4667
|
+
cookie?: never;
|
|
4668
|
+
};
|
|
4669
|
+
/**
|
|
4670
|
+
* Get prefer-GitHub dual-VCS cutover
|
|
4671
|
+
* @description Returns `productivity_vcs_github_since` on the primary GitHub App VCS row. When set, Bitbucket productivity drain is eligible alongside GitHub; Bitbucket events with `occurred_at` at or after this instant are dropped (prefer GitHub during a migration transition). Null means Bitbucket stays skipped while a GitHub App installation is connected. Requires workspace membership.
|
|
4672
|
+
*/
|
|
4673
|
+
get: operations["getWorkspaceProductivityDualVcsCutover"];
|
|
4674
|
+
put?: never;
|
|
4675
|
+
post?: never;
|
|
4676
|
+
delete?: never;
|
|
4677
|
+
options?: never;
|
|
4678
|
+
head?: never;
|
|
4679
|
+
/**
|
|
4680
|
+
* Set or clear prefer-GitHub dual-VCS cutover
|
|
4681
|
+
* @description Workspace admin (or platform admin) sets `githubSince` (ISO-8601 UTC) or clears it with `null`. Members receive 403.
|
|
4682
|
+
*/
|
|
4683
|
+
patch: operations["patchWorkspaceProductivityDualVcsCutover"];
|
|
4684
|
+
trace?: never;
|
|
4685
|
+
};
|
|
4641
4686
|
"/workspaces/{workspaceId}/ingest-runs": {
|
|
4642
4687
|
parameters: {
|
|
4643
4688
|
query?: never;
|
|
@@ -9014,6 +9059,20 @@ export interface components {
|
|
|
9014
9059
|
/** @description True when productivity_incremental_requested_at is already set; no second queue stamp. */
|
|
9015
9060
|
alreadyQueued?: boolean;
|
|
9016
9061
|
};
|
|
9062
|
+
ProductivityDualVcsCutoverDto: {
|
|
9063
|
+
/**
|
|
9064
|
+
* Format: date-time
|
|
9065
|
+
* @description Prefer-GitHub from this UTC instant. Null clears dual-VCS (Bitbucket skipped when a GitHub App installation is connected).
|
|
9066
|
+
*/
|
|
9067
|
+
githubSince: string | null;
|
|
9068
|
+
};
|
|
9069
|
+
ProductivityDualVcsCutoverPatchDto: {
|
|
9070
|
+
/**
|
|
9071
|
+
* Format: date-time
|
|
9072
|
+
* @description ISO-8601 UTC instant when GitHub became the preferred merge target, or null to clear.
|
|
9073
|
+
*/
|
|
9074
|
+
githubSince: string | null;
|
|
9075
|
+
};
|
|
9017
9076
|
/** @description Latest depth scan read from stored activity. `capturePercent` is the minimum existing capture ratio over that scan's repo checks with a GitHub merge count, or null when none qualify. */
|
|
9018
9077
|
IngestCoverageProductivityDepthScanDto: {
|
|
9019
9078
|
/** Format: date-time */
|
|
@@ -11420,6 +11479,8 @@ export type IngestCoverageLastRunDto = components['schemas']['IngestCoverageLast
|
|
|
11420
11479
|
export type IngestCoverageProductivityRepoDto = components['schemas']['IngestCoverageProductivityRepoDto'];
|
|
11421
11480
|
export type ProductivityRepoRetryResponseDto = components['schemas']['ProductivityRepoRetryResponseDto'];
|
|
11422
11481
|
export type ProductivityCatchUpResponseDto = components['schemas']['ProductivityCatchUpResponseDto'];
|
|
11482
|
+
export type ProductivityDualVcsCutoverDto = components['schemas']['ProductivityDualVcsCutoverDto'];
|
|
11483
|
+
export type ProductivityDualVcsCutoverPatchDto = components['schemas']['ProductivityDualVcsCutoverPatchDto'];
|
|
11423
11484
|
export type IngestCoverageProductivityDepthScanDto = components['schemas']['IngestCoverageProductivityDepthScanDto'];
|
|
11424
11485
|
export type IngestCoverageProductivityWeekReconcileDto = components['schemas']['IngestCoverageProductivityWeekReconcileDto'];
|
|
11425
11486
|
export type IngestCoverageProductivitySelfHealDto = components['schemas']['IngestCoverageProductivitySelfHealDto'];
|
|
@@ -11722,6 +11783,95 @@ export interface operations {
|
|
|
11722
11783
|
};
|
|
11723
11784
|
};
|
|
11724
11785
|
};
|
|
11786
|
+
adminSetAssessmentOrder: {
|
|
11787
|
+
parameters: {
|
|
11788
|
+
query?: never;
|
|
11789
|
+
header?: never;
|
|
11790
|
+
path: {
|
|
11791
|
+
/** @description `tai_users.id` of the account to authorize. */
|
|
11792
|
+
userId: string;
|
|
11793
|
+
};
|
|
11794
|
+
cookie?: never;
|
|
11795
|
+
};
|
|
11796
|
+
requestBody: {
|
|
11797
|
+
content: {
|
|
11798
|
+
"application/json": {
|
|
11799
|
+
authorized: boolean;
|
|
11800
|
+
};
|
|
11801
|
+
};
|
|
11802
|
+
};
|
|
11803
|
+
responses: {
|
|
11804
|
+
/** @description Authorization flag stored. */
|
|
11805
|
+
204: {
|
|
11806
|
+
headers: {
|
|
11807
|
+
[name: string]: unknown;
|
|
11808
|
+
};
|
|
11809
|
+
content?: never;
|
|
11810
|
+
};
|
|
11811
|
+
/** @description Invalid UUID or `authorized` is not a boolean. */
|
|
11812
|
+
400: {
|
|
11813
|
+
headers: {
|
|
11814
|
+
[name: string]: unknown;
|
|
11815
|
+
};
|
|
11816
|
+
content: {
|
|
11817
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
11818
|
+
};
|
|
11819
|
+
};
|
|
11820
|
+
/** @description Missing or invalid JWT. */
|
|
11821
|
+
401: {
|
|
11822
|
+
headers: {
|
|
11823
|
+
[name: string]: unknown;
|
|
11824
|
+
};
|
|
11825
|
+
content: {
|
|
11826
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
11827
|
+
};
|
|
11828
|
+
};
|
|
11829
|
+
/** @description Caller is not a platform admin. */
|
|
11830
|
+
403: {
|
|
11831
|
+
headers: {
|
|
11832
|
+
[name: string]: unknown;
|
|
11833
|
+
};
|
|
11834
|
+
content: {
|
|
11835
|
+
/**
|
|
11836
|
+
* @example {
|
|
11837
|
+
* "error": "Forbidden",
|
|
11838
|
+
* "code": "forbidden"
|
|
11839
|
+
* }
|
|
11840
|
+
*/
|
|
11841
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
11842
|
+
};
|
|
11843
|
+
};
|
|
11844
|
+
/** @description User not found. */
|
|
11845
|
+
404: {
|
|
11846
|
+
headers: {
|
|
11847
|
+
[name: string]: unknown;
|
|
11848
|
+
};
|
|
11849
|
+
content: {
|
|
11850
|
+
/**
|
|
11851
|
+
* @example {
|
|
11852
|
+
* "error": "User not found",
|
|
11853
|
+
* "code": "user_not_found"
|
|
11854
|
+
* }
|
|
11855
|
+
*/
|
|
11856
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
11857
|
+
};
|
|
11858
|
+
};
|
|
11859
|
+
/** @description Workspace store cannot persist the flag. */
|
|
11860
|
+
503: {
|
|
11861
|
+
headers: {
|
|
11862
|
+
[name: string]: unknown;
|
|
11863
|
+
};
|
|
11864
|
+
content: {
|
|
11865
|
+
/**
|
|
11866
|
+
* @example {
|
|
11867
|
+
* "error": "Service unavailable"
|
|
11868
|
+
* }
|
|
11869
|
+
*/
|
|
11870
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
11871
|
+
};
|
|
11872
|
+
};
|
|
11873
|
+
};
|
|
11874
|
+
};
|
|
11725
11875
|
adminListReadinessTokenUsage: {
|
|
11726
11876
|
parameters: {
|
|
11727
11877
|
query?: {
|
|
@@ -12586,7 +12736,7 @@ export interface operations {
|
|
|
12586
12736
|
};
|
|
12587
12737
|
};
|
|
12588
12738
|
401: components["responses"]["Unauthorized"];
|
|
12589
|
-
/** @description Conflict creating workspace
|
|
12739
|
+
/** @description Conflict creating workspace. Stable cases: verified-email identity conflict, duplicate workspace name/slug, or `workspace_limit_reached` when the caller already has a workspace. An operator-authorized account (`PUT /admin/users/{userId}/assessment-order`) may create exactly one extra workspace; a third workspace still returns `workspace_limit_reached`. A buyer body field cannot grant that exception. */
|
|
12590
12740
|
409: {
|
|
12591
12741
|
headers: {
|
|
12592
12742
|
[name: string]: unknown;
|
|
@@ -23565,6 +23715,85 @@ export interface operations {
|
|
|
23565
23715
|
};
|
|
23566
23716
|
};
|
|
23567
23717
|
};
|
|
23718
|
+
getWorkspaceProductivityDualVcsCutover: {
|
|
23719
|
+
parameters: {
|
|
23720
|
+
query?: never;
|
|
23721
|
+
header?: never;
|
|
23722
|
+
path: {
|
|
23723
|
+
workspaceId: components["parameters"]["WorkspaceId"];
|
|
23724
|
+
};
|
|
23725
|
+
cookie?: never;
|
|
23726
|
+
};
|
|
23727
|
+
requestBody?: never;
|
|
23728
|
+
responses: {
|
|
23729
|
+
/** @description Current cutover */
|
|
23730
|
+
200: {
|
|
23731
|
+
headers: {
|
|
23732
|
+
[name: string]: unknown;
|
|
23733
|
+
};
|
|
23734
|
+
content: {
|
|
23735
|
+
"application/json": components["schemas"]["ProductivityDualVcsCutoverDto"];
|
|
23736
|
+
};
|
|
23737
|
+
};
|
|
23738
|
+
401: components["responses"]["Unauthorized"];
|
|
23739
|
+
403: components["responses"]["Forbidden"];
|
|
23740
|
+
/** @description Productivity not connected */
|
|
23741
|
+
404: {
|
|
23742
|
+
headers: {
|
|
23743
|
+
[name: string]: unknown;
|
|
23744
|
+
};
|
|
23745
|
+
content: {
|
|
23746
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
23747
|
+
};
|
|
23748
|
+
};
|
|
23749
|
+
};
|
|
23750
|
+
};
|
|
23751
|
+
patchWorkspaceProductivityDualVcsCutover: {
|
|
23752
|
+
parameters: {
|
|
23753
|
+
query?: never;
|
|
23754
|
+
header?: never;
|
|
23755
|
+
path: {
|
|
23756
|
+
workspaceId: components["parameters"]["WorkspaceId"];
|
|
23757
|
+
};
|
|
23758
|
+
cookie?: never;
|
|
23759
|
+
};
|
|
23760
|
+
requestBody: {
|
|
23761
|
+
content: {
|
|
23762
|
+
"application/json": components["schemas"]["ProductivityDualVcsCutoverPatchDto"];
|
|
23763
|
+
};
|
|
23764
|
+
};
|
|
23765
|
+
responses: {
|
|
23766
|
+
/** @description Updated cutover */
|
|
23767
|
+
200: {
|
|
23768
|
+
headers: {
|
|
23769
|
+
[name: string]: unknown;
|
|
23770
|
+
};
|
|
23771
|
+
content: {
|
|
23772
|
+
"application/json": components["schemas"]["ProductivityDualVcsCutoverDto"];
|
|
23773
|
+
};
|
|
23774
|
+
};
|
|
23775
|
+
/** @description Invalid body or timestamp */
|
|
23776
|
+
400: {
|
|
23777
|
+
headers: {
|
|
23778
|
+
[name: string]: unknown;
|
|
23779
|
+
};
|
|
23780
|
+
content: {
|
|
23781
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
23782
|
+
};
|
|
23783
|
+
};
|
|
23784
|
+
401: components["responses"]["Unauthorized"];
|
|
23785
|
+
403: components["responses"]["Forbidden"];
|
|
23786
|
+
/** @description Productivity not connected */
|
|
23787
|
+
404: {
|
|
23788
|
+
headers: {
|
|
23789
|
+
[name: string]: unknown;
|
|
23790
|
+
};
|
|
23791
|
+
content: {
|
|
23792
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
23793
|
+
};
|
|
23794
|
+
};
|
|
23795
|
+
};
|
|
23796
|
+
};
|
|
23568
23797
|
getWorkspaceIngestRuns: {
|
|
23569
23798
|
parameters: {
|
|
23570
23799
|
query?: {
|