@thinkai/tai-api-contract 2.11.1 → 2.12.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 +224 -1
- package/dist/generated/openapi.d.ts.map +1 -1
- package/openapi/openapi.yaml +287 -1
- package/package.json +2 -1
- package/src/generated/openapi.ts +224 -1
|
@@ -948,7 +948,12 @@ export interface paths {
|
|
|
948
948
|
delete?: never;
|
|
949
949
|
options?: never;
|
|
950
950
|
head?: never;
|
|
951
|
-
|
|
951
|
+
/**
|
|
952
|
+
* Archive (remove) or restore (re-add) a repository
|
|
953
|
+
* @description Set `archived: true` to soft-remove the repo (Inactive). Set `archived: false` to re-add a previously Inactive repo (Active). Re-add reuses the same `repo_id` row so historical scan foreign keys remain intact, and automatically enqueues a fresh readiness scan.
|
|
954
|
+
* Returns `409` with `code: repo_scan_in_progress` if a scan is queued or running when archiving. Returns `409` with `code: repo_already_active` if re-adding a repo that is already Active.
|
|
955
|
+
*/
|
|
956
|
+
patch: operations["patchReadinessRepo"];
|
|
952
957
|
trace?: never;
|
|
953
958
|
};
|
|
954
959
|
"/workspaces/{workspaceId}/readiness/repos/{repoId}/runs": {
|
|
@@ -991,6 +996,26 @@ export interface paths {
|
|
|
991
996
|
patch?: never;
|
|
992
997
|
trace?: never;
|
|
993
998
|
};
|
|
999
|
+
"/workspaces/{workspaceId}/activity": {
|
|
1000
|
+
parameters: {
|
|
1001
|
+
query?: never;
|
|
1002
|
+
header?: never;
|
|
1003
|
+
path?: never;
|
|
1004
|
+
cookie?: never;
|
|
1005
|
+
};
|
|
1006
|
+
/**
|
|
1007
|
+
* Workspace activity log (paginated)
|
|
1008
|
+
* @description Paginated, chronological feed of workspace-scoped lifecycle events: repository add/remove/re-add and GitHub integration add/remove. Inactive repos remain visible in this log. Filter by `eventType`, `actorUserId`, or date range (`since`/`until`).
|
|
1009
|
+
*/
|
|
1010
|
+
get: operations["listWorkspaceActivity"];
|
|
1011
|
+
put?: never;
|
|
1012
|
+
post?: never;
|
|
1013
|
+
delete?: never;
|
|
1014
|
+
options?: never;
|
|
1015
|
+
head?: never;
|
|
1016
|
+
patch?: never;
|
|
1017
|
+
trace?: never;
|
|
1018
|
+
};
|
|
994
1019
|
"/workspaces/{workspaceId}/readiness/score-history": {
|
|
995
1020
|
parameters: {
|
|
996
1021
|
query?: never;
|
|
@@ -3119,6 +3144,79 @@ export interface components {
|
|
|
3119
3144
|
activeUsers: number;
|
|
3120
3145
|
}[];
|
|
3121
3146
|
};
|
|
3147
|
+
PatchRepoArchiveBodyDto: {
|
|
3148
|
+
/** @description `true` to soft-remove (Inactive). `false` to restore a previously Inactive repo (Active), which also enqueues a fresh readiness scan. */
|
|
3149
|
+
archived: boolean;
|
|
3150
|
+
};
|
|
3151
|
+
PatchRepoArchiveResponseDto: {
|
|
3152
|
+
/** Format: uuid */
|
|
3153
|
+
repoId: string;
|
|
3154
|
+
/**
|
|
3155
|
+
* @description Current lifecycle status of the repository after the operation.
|
|
3156
|
+
* @enum {string}
|
|
3157
|
+
*/
|
|
3158
|
+
status: "Active" | "Inactive";
|
|
3159
|
+
/**
|
|
3160
|
+
* Format: uuid
|
|
3161
|
+
* @description ID of the freshly enqueued readiness scan run (only present on re-add).
|
|
3162
|
+
*/
|
|
3163
|
+
runId?: string | null;
|
|
3164
|
+
};
|
|
3165
|
+
/**
|
|
3166
|
+
* @description Type of workspace lifecycle event.
|
|
3167
|
+
* @enum {string}
|
|
3168
|
+
*/
|
|
3169
|
+
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" | "member.invited" | "member.role_changed" | "member.removed";
|
|
3170
|
+
ActivityLogActorDto: {
|
|
3171
|
+
/** Format: uuid */
|
|
3172
|
+
userId: string;
|
|
3173
|
+
/** Format: email */
|
|
3174
|
+
email?: string | null;
|
|
3175
|
+
name?: string | null;
|
|
3176
|
+
};
|
|
3177
|
+
ActivityLogEntryDto: {
|
|
3178
|
+
/** Format: uuid */
|
|
3179
|
+
id: string;
|
|
3180
|
+
eventType: components["schemas"]["ActivityLogEventTypeDto"];
|
|
3181
|
+
/** @description Namespace prefix derived from event_type (e.g. "fix", "repo", "config"). */
|
|
3182
|
+
eventCategory: string;
|
|
3183
|
+
/** Format: date-time */
|
|
3184
|
+
occurredAt: string;
|
|
3185
|
+
/**
|
|
3186
|
+
* @description Whether the event was triggered by a human user, a batch/system process, or a webhook.
|
|
3187
|
+
* @enum {string}
|
|
3188
|
+
*/
|
|
3189
|
+
actorType: "user" | "system" | "webhook";
|
|
3190
|
+
actor?: components["schemas"]["ActivityLogActorDto"] | null;
|
|
3191
|
+
/** Format: uuid */
|
|
3192
|
+
repoId?: string | null;
|
|
3193
|
+
repoName?: string | null;
|
|
3194
|
+
/** Format: uuid */
|
|
3195
|
+
integrationId?: string | null;
|
|
3196
|
+
integrationType?: string | null;
|
|
3197
|
+
/**
|
|
3198
|
+
* Format: uuid
|
|
3199
|
+
* @description ID of the related fix request (fix.* events).
|
|
3200
|
+
*/
|
|
3201
|
+
fixRequestId?: string | null;
|
|
3202
|
+
/**
|
|
3203
|
+
* Format: uuid
|
|
3204
|
+
* @description ID of the related readiness issue (fix.* events).
|
|
3205
|
+
*/
|
|
3206
|
+
issueId?: string | null;
|
|
3207
|
+
/**
|
|
3208
|
+
* Format: uuid
|
|
3209
|
+
* @description ID of the related readiness run (readiness.* events).
|
|
3210
|
+
*/
|
|
3211
|
+
readinessRunId?: string | null;
|
|
3212
|
+
/** @description Event-specific supplementary data (before/after state, installation IDs, etc.). */
|
|
3213
|
+
metadata?: {
|
|
3214
|
+
[key: string]: unknown;
|
|
3215
|
+
} | null;
|
|
3216
|
+
};
|
|
3217
|
+
ActivityLogPageDto: components["schemas"]["PageMetaDto"] & {
|
|
3218
|
+
items: components["schemas"]["ActivityLogEntryDto"][];
|
|
3219
|
+
};
|
|
3122
3220
|
};
|
|
3123
3221
|
responses: {
|
|
3124
3222
|
/** @description Missing or invalid bearer token */
|
|
@@ -3340,6 +3438,12 @@ export type YourAiJourneyReadinessAggregateDto = components['schemas']['YourAiJo
|
|
|
3340
3438
|
export type YourAiJourneyAnalyticsDto = components['schemas']['YourAiJourneyAnalyticsDto'];
|
|
3341
3439
|
export type YourAiJourneyAiSpendWeekDto = components['schemas']['YourAiJourneyAiSpendWeekDto'];
|
|
3342
3440
|
export type YourAiJourneyAiSpendDto = components['schemas']['YourAiJourneyAiSpendDto'];
|
|
3441
|
+
export type PatchRepoArchiveBodyDto = components['schemas']['PatchRepoArchiveBodyDto'];
|
|
3442
|
+
export type PatchRepoArchiveResponseDto = components['schemas']['PatchRepoArchiveResponseDto'];
|
|
3443
|
+
export type ActivityLogEventTypeDto = components['schemas']['ActivityLogEventTypeDto'];
|
|
3444
|
+
export type ActivityLogActorDto = components['schemas']['ActivityLogActorDto'];
|
|
3445
|
+
export type ActivityLogEntryDto = components['schemas']['ActivityLogEntryDto'];
|
|
3446
|
+
export type ActivityLogPageDto = components['schemas']['ActivityLogPageDto'];
|
|
3343
3447
|
export type ResponseUnauthorized = components['responses']['Unauthorized'];
|
|
3344
3448
|
export type ResponseForbidden = components['responses']['Forbidden'];
|
|
3345
3449
|
export type ParameterWorkspaceId = components['parameters']['WorkspaceId'];
|
|
@@ -5536,6 +5640,8 @@ export interface operations {
|
|
|
5536
5640
|
search?: components["parameters"]["ReadinessRepoSearch"];
|
|
5537
5641
|
/** @description Exact language filter (e.g. `typescript`). */
|
|
5538
5642
|
language?: components["parameters"]["ReadinessRepoLanguage"];
|
|
5643
|
+
/** @description When `true`, includes Inactive (user-removed) repos alongside Active ones. Default is `false` (active only). */
|
|
5644
|
+
includeArchived?: boolean;
|
|
5539
5645
|
};
|
|
5540
5646
|
header?: never;
|
|
5541
5647
|
path: {
|
|
@@ -5750,6 +5856,62 @@ export interface operations {
|
|
|
5750
5856
|
};
|
|
5751
5857
|
};
|
|
5752
5858
|
};
|
|
5859
|
+
patchReadinessRepo: {
|
|
5860
|
+
parameters: {
|
|
5861
|
+
query?: never;
|
|
5862
|
+
header?: never;
|
|
5863
|
+
path: {
|
|
5864
|
+
workspaceId: components["parameters"]["WorkspaceId"];
|
|
5865
|
+
repoId: components["parameters"]["RepoId"];
|
|
5866
|
+
};
|
|
5867
|
+
cookie?: never;
|
|
5868
|
+
};
|
|
5869
|
+
requestBody: {
|
|
5870
|
+
content: {
|
|
5871
|
+
"application/json": components["schemas"]["PatchRepoArchiveBodyDto"];
|
|
5872
|
+
};
|
|
5873
|
+
};
|
|
5874
|
+
responses: {
|
|
5875
|
+
/** @description Repo status updated */
|
|
5876
|
+
200: {
|
|
5877
|
+
headers: {
|
|
5878
|
+
[name: string]: unknown;
|
|
5879
|
+
};
|
|
5880
|
+
content: {
|
|
5881
|
+
"application/json": components["schemas"]["PatchRepoArchiveResponseDto"];
|
|
5882
|
+
};
|
|
5883
|
+
};
|
|
5884
|
+
/** @description Malformed request body or repoId */
|
|
5885
|
+
400: {
|
|
5886
|
+
headers: {
|
|
5887
|
+
[name: string]: unknown;
|
|
5888
|
+
};
|
|
5889
|
+
content: {
|
|
5890
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
5891
|
+
};
|
|
5892
|
+
};
|
|
5893
|
+
401: components["responses"]["Unauthorized"];
|
|
5894
|
+
403: components["responses"]["Forbidden"];
|
|
5895
|
+
/** @description Workspace or repository not found */
|
|
5896
|
+
404: {
|
|
5897
|
+
headers: {
|
|
5898
|
+
[name: string]: unknown;
|
|
5899
|
+
};
|
|
5900
|
+
content: {
|
|
5901
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
5902
|
+
};
|
|
5903
|
+
};
|
|
5904
|
+
/** @description Conflict — scan in progress or repo already in the requested state */
|
|
5905
|
+
409: {
|
|
5906
|
+
headers: {
|
|
5907
|
+
[name: string]: unknown;
|
|
5908
|
+
};
|
|
5909
|
+
content: {
|
|
5910
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
5911
|
+
};
|
|
5912
|
+
};
|
|
5913
|
+
};
|
|
5914
|
+
};
|
|
5753
5915
|
listReadinessRepoRuns: {
|
|
5754
5916
|
parameters: {
|
|
5755
5917
|
query?: {
|
|
@@ -5853,6 +6015,67 @@ export interface operations {
|
|
|
5853
6015
|
};
|
|
5854
6016
|
};
|
|
5855
6017
|
};
|
|
6018
|
+
listWorkspaceActivity: {
|
|
6019
|
+
parameters: {
|
|
6020
|
+
query?: {
|
|
6021
|
+
/** @description Page size (default 25, max 100). */
|
|
6022
|
+
limit?: components["parameters"]["PaginationLimit"];
|
|
6023
|
+
/** @description Zero-based row offset into the filtered, sorted result set. */
|
|
6024
|
+
offset?: components["parameters"]["PaginationOffset"];
|
|
6025
|
+
/** @description Sort direction. */
|
|
6026
|
+
order?: components["parameters"]["PaginationOrder"];
|
|
6027
|
+
/** @description Filter to a specific event type. */
|
|
6028
|
+
eventType?: components["schemas"]["ActivityLogEventTypeDto"];
|
|
6029
|
+
/** @description Filter to events performed by a specific user (UUID). */
|
|
6030
|
+
actorUserId?: string;
|
|
6031
|
+
/** @description ISO-8601 lower bound on `occurredAt` (inclusive). */
|
|
6032
|
+
since?: string;
|
|
6033
|
+
/** @description ISO-8601 upper bound on `occurredAt` (inclusive). */
|
|
6034
|
+
until?: string;
|
|
6035
|
+
/** @description Filter by event namespace prefix (e.g. "fix", "repo", "integration", "readiness", "config", "member"). */
|
|
6036
|
+
eventCategory?: string;
|
|
6037
|
+
/** @description Case-insensitive substring filter applied across repo name, integration type, actor email, and actor display name. */
|
|
6038
|
+
search?: string;
|
|
6039
|
+
};
|
|
6040
|
+
header?: never;
|
|
6041
|
+
path: {
|
|
6042
|
+
workspaceId: components["parameters"]["WorkspaceId"];
|
|
6043
|
+
};
|
|
6044
|
+
cookie?: never;
|
|
6045
|
+
};
|
|
6046
|
+
requestBody?: never;
|
|
6047
|
+
responses: {
|
|
6048
|
+
/** @description Paginated activity log entries */
|
|
6049
|
+
200: {
|
|
6050
|
+
headers: {
|
|
6051
|
+
[name: string]: unknown;
|
|
6052
|
+
};
|
|
6053
|
+
content: {
|
|
6054
|
+
"application/json": components["schemas"]["ActivityLogPageDto"];
|
|
6055
|
+
};
|
|
6056
|
+
};
|
|
6057
|
+
/** @description Invalid query parameters */
|
|
6058
|
+
400: {
|
|
6059
|
+
headers: {
|
|
6060
|
+
[name: string]: unknown;
|
|
6061
|
+
};
|
|
6062
|
+
content: {
|
|
6063
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
6064
|
+
};
|
|
6065
|
+
};
|
|
6066
|
+
401: components["responses"]["Unauthorized"];
|
|
6067
|
+
403: components["responses"]["Forbidden"];
|
|
6068
|
+
/** @description Workspace does not exist */
|
|
6069
|
+
404: {
|
|
6070
|
+
headers: {
|
|
6071
|
+
[name: string]: unknown;
|
|
6072
|
+
};
|
|
6073
|
+
content: {
|
|
6074
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
6075
|
+
};
|
|
6076
|
+
};
|
|
6077
|
+
};
|
|
6078
|
+
};
|
|
5856
6079
|
getReadinessScoreHistory: {
|
|
5857
6080
|
parameters: {
|
|
5858
6081
|
query?: {
|