@vibexp/api-client 0.46.0 → 0.47.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.
@@ -1279,205 +1279,6 @@ export type SupportResponse = {
1279
1279
  message: string;
1280
1280
  success: boolean;
1281
1281
  };
1282
- export type IncomingHookPayload = {
1283
- /**
1284
- * Unique identifier for the Claude Code session
1285
- */
1286
- session_id: string;
1287
- /**
1288
- * Path to the conversation transcript file
1289
- */
1290
- transcript_path?: string | null;
1291
- /**
1292
- * Current working directory
1293
- */
1294
- cwd?: string | null;
1295
- /**
1296
- * Name of the hook event that triggered this payload
1297
- */
1298
- hook_event_name: string;
1299
- /**
1300
- * Name of the tool being used
1301
- */
1302
- tool_name?: string | null;
1303
- /**
1304
- * Input data for the tool
1305
- */
1306
- tool_input?: {
1307
- [key: string]: unknown;
1308
- } | null;
1309
- /**
1310
- * Response data from the tool
1311
- */
1312
- tool_response?: {
1313
- [key: string]: unknown;
1314
- } | null;
1315
- /**
1316
- * User prompt or message
1317
- */
1318
- prompt?: string | null;
1319
- /**
1320
- * Additional message or context
1321
- */
1322
- message?: string | null;
1323
- };
1324
- export type ClaudeCodeHookPayload = {
1325
- /**
1326
- * Unique identifier for the stored payload
1327
- */
1328
- id: number;
1329
- /**
1330
- * ID of the user who submitted the hook (omitted when not set)
1331
- */
1332
- user_id?: string;
1333
- /**
1334
- * ID of the user's default team at ingest time
1335
- */
1336
- team_id: string;
1337
- /**
1338
- * Unique identifier for the Claude Code session
1339
- */
1340
- session_id: string;
1341
- /**
1342
- * Path to the conversation transcript file
1343
- */
1344
- transcript_path?: string | null;
1345
- /**
1346
- * Current working directory
1347
- */
1348
- cwd?: string | null;
1349
- /**
1350
- * Name of the hook event that triggered this payload
1351
- */
1352
- hook_event_name: string;
1353
- /**
1354
- * Name of the tool being used
1355
- */
1356
- tool_name?: string | null;
1357
- /**
1358
- * Input data for the tool
1359
- */
1360
- tool_input?: {
1361
- [key: string]: unknown;
1362
- } | null;
1363
- /**
1364
- * Response data from the tool
1365
- */
1366
- tool_response?: {
1367
- [key: string]: unknown;
1368
- } | null;
1369
- /**
1370
- * User prompt or message
1371
- */
1372
- prompt?: string | null;
1373
- /**
1374
- * Additional message or context
1375
- */
1376
- message?: string | null;
1377
- /**
1378
- * Complete payload data as JSONB
1379
- */
1380
- payload: {
1381
- [key: string]: unknown;
1382
- };
1383
- /**
1384
- * When the record was created
1385
- */
1386
- created_at: string;
1387
- /**
1388
- * When the record was last updated
1389
- */
1390
- updated_at: string;
1391
- };
1392
- export type ClaudeCodeHooksPaginatedResponse = {
1393
- data: Array<ClaudeCodeHookPayload>;
1394
- /**
1395
- * Current page number
1396
- */
1397
- page: number;
1398
- /**
1399
- * Number of items per page
1400
- */
1401
- limit: number;
1402
- /**
1403
- * Total number of records
1404
- */
1405
- total: number;
1406
- /**
1407
- * Total number of pages
1408
- */
1409
- total_pages: number;
1410
- };
1411
- export type HookCreatedResponse = {
1412
- status: string;
1413
- message: string;
1414
- data: {
1415
- id: number;
1416
- created_at: string;
1417
- updated_at: string;
1418
- };
1419
- };
1420
- export type HookListResponse = {
1421
- status: string;
1422
- message: string;
1423
- data: ClaudeCodeHooksPaginatedResponse;
1424
- };
1425
- export type SessionSummary = {
1426
- session_id: string;
1427
- first_seen: string;
1428
- last_seen: string;
1429
- hook_count: number;
1430
- latest_cwd?: string | null;
1431
- unique_tools: number;
1432
- };
1433
- export type SessionsResponse = {
1434
- data: Array<SessionSummary>;
1435
- page: number;
1436
- limit: number;
1437
- total: number;
1438
- total_pages: number;
1439
- };
1440
- export type SessionCountsResponse = {
1441
- total_sessions: number;
1442
- counts: Array<{
1443
- date?: string;
1444
- count?: number;
1445
- }>;
1446
- };
1447
- export type OverviewStats = {
1448
- total_sessions: number;
1449
- sessions_this_week: number;
1450
- sessions_last_week: number;
1451
- weekly_trend_percent: number;
1452
- avg_user_prompts_per_session: number;
1453
- total_unique_tools: number;
1454
- top_tools: Array<{
1455
- tool_name?: string;
1456
- count?: number;
1457
- }>;
1458
- avg_session_duration_minutes: number;
1459
- /**
1460
- * Total number of memories created by the user
1461
- */
1462
- total_memories: number;
1463
- };
1464
- export type RecentActivity = {
1465
- session_id: string;
1466
- cwd?: string | null;
1467
- tool_name?: string | null;
1468
- tool_input?: {
1469
- [key: string]: unknown;
1470
- } | null;
1471
- hook_event_name: string;
1472
- created_at: string;
1473
- };
1474
- export type RecentActivitiesResponse = {
1475
- activities: Array<RecentActivity>;
1476
- page: number;
1477
- limit: number;
1478
- total: number;
1479
- total_pages: number;
1480
- };
1481
1282
  export type Artifact = {
1482
1283
  /**
1483
1284
  * Unique identifier for the artifact
@@ -3092,480 +2893,142 @@ export type ConversationExecutionsResponse = {
3092
2893
  count: number;
3093
2894
  };
3094
2895
  /**
3095
- * Legacy CLI-compatible error shape `{"status":"error","message":...}` emitted by the AI-tools hook handlers (NOT the RFC 9457 ErrorResponse used elsewhere). Resource-limit 403 responses additionally include a `details` object.
2896
+ * A team (workspace) in the system. `role`, `permissions` and `member_count` are computed at read time for the requesting user.
3096
2897
  */
3097
- export type HookErrorResponse = {
3098
- status: string;
3099
- message: string;
3100
- /**
3101
- * Present only on resource-limit (403) responses
3102
- */
3103
- details?: {
3104
- resource_type?: string;
3105
- current_usage?: number;
3106
- limit?: number;
3107
- };
3108
- };
3109
- export type SessionsListResponse = {
3110
- status: string;
3111
- message: string;
3112
- data: SessionsResponse;
3113
- };
3114
- export type SessionCountsApiResponse = {
3115
- status: string;
3116
- message: string;
3117
- data: SessionCountsResponse;
3118
- };
3119
- export type OverviewStatsApiResponse = {
3120
- status: string;
3121
- message: string;
3122
- data: OverviewStats;
3123
- };
3124
- export type RecentActivitiesApiResponse = {
3125
- status: string;
3126
- message: string;
3127
- data: RecentActivitiesResponse;
3128
- };
3129
- export type IncomingCursorHookPayload = unknown & {
2898
+ export type Team = {
2899
+ id: string;
3130
2900
  /**
3131
- * Cursor conversation identifier (used as session_id when session_id is absent)
2901
+ * User ID of the team owner
3132
2902
  */
3133
- conversation_id?: string;
2903
+ owner_id: string;
2904
+ name: string;
2905
+ slug: string;
2906
+ description: string;
3134
2907
  /**
3135
- * Cursor generation identifier
2908
+ * Whether this is the user's personal workspace (cannot be deleted or hold a team subscription)
3136
2909
  */
3137
- generation_id?: string;
2910
+ is_personal: boolean;
3138
2911
  /**
3139
- * Workspace root directories
2912
+ * The requesting user's role in this team: owner, admin, or member. Populated at runtime on every response that carries a team, including create (where the caller is by definition the owner). Not an enum constraint: older responses may still carry an empty string.
3140
2913
  */
3141
- workspace_roots?: Array<string>;
2914
+ role?: string;
3142
2915
  /**
3143
- * Session identifier (legacy/optional; falls back to conversation_id)
2916
+ * Exactly what `role` permits the requesting user to do in this team, expanded server-side from the role matrix (epic #220). Clients MUST gate their UI on these strings rather than re-deriving them from `role` — the matrix lives on the server and may change without a client release.
2917
+ * Computed at read time for the requesting user, alongside `role`, and always present (an empty array means the role grants nothing). The values are stable API surface: renaming one is a breaking change, and they are kept byte-identical to the `internal/authz` constants by a drift test. Meanings:
2918
+ * * `team.update` — change team name, slug or description. * `team.delete` — delete the team (owner only). * `team.transfer` — transfer ownership to another member (owner only). * `team.settings.update` — change team-level configuration, such as search ranking. * `member.invite` — invite new members. * `member.remove` — remove members from the team. * `member.role.update` — change a member's role. * `project.create` — create a project in the team. * `project.update` — update any project in the team. * `project.delete` — delete any project in the team. * `resource.create` — create a prompt, memory, artifact, blueprint or agent. * `resource.update.any` — update any resource, including other members'. * `resource.delete.own` — delete a resource the caller created. * `resource.delete.any` — delete a resource created by someone else. * `feed.delete.any` — delete another member's feed post or reply (moderation).
3144
2919
  */
3145
- session_id?: string;
2920
+ permissions: Array<'team.update' | 'team.delete' | 'team.transfer' | 'team.settings.update' | 'member.invite' | 'member.remove' | 'member.role.update' | 'project.create' | 'project.update' | 'project.delete' | 'resource.create' | 'resource.update.any' | 'resource.delete.own' | 'resource.delete.any' | 'feed.delete.any'>;
3146
2921
  /**
3147
- * Name of the hook event that triggered this payload
2922
+ * Number of members in this team. Populated only on list responses; 0 on create and single-team reads.
3148
2923
  */
3149
- hook_event_name: string;
2924
+ member_count?: number;
2925
+ created_at: string;
2926
+ updated_at: string;
2927
+ };
2928
+ /**
2929
+ * Request body for creating a team
2930
+ */
2931
+ export type CreateTeamRequest = {
3150
2932
  /**
3151
- * Name of the tool being used
2933
+ * Team name (required, at most 100 characters)
3152
2934
  */
3153
- tool_name?: string | null;
2935
+ name: string;
3154
2936
  /**
3155
- * Hook configuration data
2937
+ * Optional team description (at most 500 characters)
3156
2938
  */
3157
- configuration?: {
3158
- [key: string]: unknown;
3159
- } | null;
2939
+ description?: string;
2940
+ };
2941
+ /**
2942
+ * Request body for updating a team. At least one of `name` or `description` must be provided.
2943
+ */
2944
+ export type UpdateTeamRequest = {
3160
2945
  /**
3161
- * Reference data
2946
+ * New team name (must be non-empty when provided)
3162
2947
  */
3163
- reference?: {
3164
- [key: string]: unknown;
3165
- } | null;
2948
+ name?: string;
3166
2949
  /**
3167
- * Context data
2950
+ * New team description
3168
2951
  */
3169
- context?: {
3170
- [key: string]: unknown;
3171
- } | null;
2952
+ description?: string;
2953
+ };
2954
+ /**
2955
+ * Paginated list of teams the user belongs to
2956
+ */
2957
+ export type TeamListResponse = {
2958
+ teams: Array<Team>;
2959
+ total_count: number;
2960
+ page: number;
2961
+ page_size: number;
2962
+ };
2963
+ /**
2964
+ * Detailed information about a team member, including invitation status
2965
+ */
2966
+ export type TeamMemberDetail = {
2967
+ user_id: string;
2968
+ email: string;
2969
+ name: string;
2970
+ role: 'owner' | 'admin' | 'member';
3172
2971
  /**
3173
- * Input data for the hook
2972
+ * When the member joined the team
3174
2973
  */
3175
- input?: {
3176
- [key: string]: unknown;
3177
- } | null;
2974
+ joined_at: string;
3178
2975
  /**
3179
- * Output data from the hook
2976
+ * Invitation status for this member (omitted when not applicable)
3180
2977
  */
3181
- output?: {
3182
- [key: string]: unknown;
3183
- } | null;
2978
+ invitation_status?: 'pending' | 'accepted';
2979
+ };
2980
+ /**
2981
+ * Request body for changing a team member's role. Only `member` and `admin` are
2982
+ * accepted: a team has exactly one owner, and ownership moves solely through
2983
+ * the transfer-ownership operation.
2984
+ *
2985
+ */
2986
+ export type UpdateTeamMemberRoleRequest = {
3184
2987
  /**
3185
- * Induced failure data
2988
+ * The role to assign to the member
3186
2989
  */
3187
- inducedFailure?: {
3188
- [key: string]: unknown;
3189
- } | null;
2990
+ role: 'member' | 'admin';
2991
+ };
2992
+ /**
2993
+ * The team member after the role change
2994
+ */
2995
+ export type UpdateTeamMemberRoleResponse = {
2996
+ member: TeamMemberDetail;
2997
+ };
2998
+ /**
2999
+ * Request body for transferring team ownership. The target must already be a
3000
+ * member of the team; they become the owner and the current owner becomes an
3001
+ * admin, in a single transaction.
3002
+ *
3003
+ */
3004
+ export type TransferTeamOwnershipRequest = {
3190
3005
  /**
3191
- * Shell command (beforeShellExecution)
3006
+ * User ID of the member who will become the team owner
3192
3007
  */
3193
- command?: string | null;
3008
+ new_owner_id: string;
3009
+ };
3010
+ /**
3011
+ * The team after ownership has been transferred
3012
+ */
3013
+ export type TransferTeamOwnershipResponse = {
3014
+ team: Team;
3015
+ };
3016
+ /**
3017
+ * Paginated list of team members
3018
+ */
3019
+ export type TeamMembersListResponse = {
3020
+ members: Array<TeamMemberDetail>;
3021
+ total_count: number;
3022
+ page: number;
3023
+ page_size: number;
3024
+ };
3025
+ /**
3026
+ * Request body for sending team invitations (1–50 email addresses per request)
3027
+ */
3028
+ export type SendInvitationsRequest = {
3029
+ emails: Array<string>;
3194
3030
  /**
3195
- * Current working directory (beforeShellExecution)
3196
- */
3197
- cwd?: string | null;
3198
- /**
3199
- * Tool input data (beforeMCPExecution)
3200
- */
3201
- tool_input?: {
3202
- [key: string]: unknown;
3203
- } | null;
3204
- /**
3205
- * URL (beforeMCPExecution)
3206
- */
3207
- url?: string | null;
3208
- /**
3209
- * File path (afterFileEdit, beforeReadFile)
3210
- */
3211
- file_path?: string | null;
3212
- /**
3213
- * File edits (afterFileEdit)
3214
- */
3215
- edits?: Array<{
3216
- [key: string]: unknown;
3217
- }>;
3218
- /**
3219
- * File content (beforeReadFile)
3220
- */
3221
- content?: string | null;
3222
- /**
3223
- * Attachments (beforeReadFile, beforeSubmitPrompt)
3224
- */
3225
- attachments?: Array<{
3226
- [key: string]: unknown;
3227
- }>;
3228
- /**
3229
- * User prompt (beforeSubmitPrompt)
3230
- */
3231
- prompt?: string | null;
3232
- /**
3233
- * Status (stop hook)
3234
- */
3235
- status?: string | null;
3236
- /**
3237
- * Permission response field
3238
- */
3239
- permission?: string | null;
3240
- /**
3241
- * User message response field
3242
- */
3243
- userMessage?: string | null;
3244
- /**
3245
- * Agent message response field
3246
- */
3247
- agentMessage?: string | null;
3248
- /**
3249
- * Continue response field
3250
- */
3251
- continue?: boolean | null;
3252
- };
3253
- export type CursorIdeHookPayload = {
3254
- /**
3255
- * Unique identifier for the stored payload
3256
- */
3257
- id: number;
3258
- /**
3259
- * ID of the user who submitted the hook (omitted when not set)
3260
- */
3261
- user_id?: string;
3262
- /**
3263
- * ID of the user's default team at ingest time
3264
- */
3265
- team_id: string;
3266
- /**
3267
- * Session identifier (stores conversation_id from Cursor)
3268
- */
3269
- session_id: string;
3270
- /**
3271
- * Cursor conversation identifier
3272
- */
3273
- conversation_id?: string | null;
3274
- /**
3275
- * Cursor generation identifier
3276
- */
3277
- generation_id?: string | null;
3278
- /**
3279
- * Name of the hook event that triggered this payload
3280
- */
3281
- hook_event_name: string;
3282
- /**
3283
- * Name of the tool being used
3284
- */
3285
- tool_name?: string | null;
3286
- /**
3287
- * Workspace root directories
3288
- */
3289
- workspace_roots?: Array<string>;
3290
- /**
3291
- * Hook configuration data
3292
- */
3293
- configuration?: {
3294
- [key: string]: unknown;
3295
- } | null;
3296
- /**
3297
- * Reference data
3298
- */
3299
- reference?: {
3300
- [key: string]: unknown;
3301
- } | null;
3302
- /**
3303
- * Context data
3304
- */
3305
- context?: {
3306
- [key: string]: unknown;
3307
- } | null;
3308
- /**
3309
- * Input data for the hook
3310
- */
3311
- input?: {
3312
- [key: string]: unknown;
3313
- } | null;
3314
- /**
3315
- * Output data from the hook
3316
- */
3317
- output?: {
3318
- [key: string]: unknown;
3319
- } | null;
3320
- /**
3321
- * Induced failure data
3322
- */
3323
- induced_failure?: {
3324
- [key: string]: unknown;
3325
- } | null;
3326
- /**
3327
- * Complete payload data as JSONB
3328
- */
3329
- payload: {
3330
- [key: string]: unknown;
3331
- };
3332
- /**
3333
- * When the record was created
3334
- */
3335
- created_at: string;
3336
- /**
3337
- * When the record was last updated
3338
- */
3339
- updated_at: string;
3340
- };
3341
- export type CursorIdeHooksPaginatedResponse = {
3342
- data: Array<CursorIdeHookPayload>;
3343
- /**
3344
- * Current page number
3345
- */
3346
- page: number;
3347
- /**
3348
- * Number of items per page
3349
- */
3350
- limit: number;
3351
- /**
3352
- * Total number of records
3353
- */
3354
- total: number;
3355
- /**
3356
- * Total number of pages
3357
- */
3358
- total_pages: number;
3359
- };
3360
- export type CursorIdeHookListResponse = {
3361
- status: string;
3362
- message: string;
3363
- data: CursorIdeHooksPaginatedResponse;
3364
- };
3365
- /**
3366
- * Summary of a Cursor IDE session (unlike Claude Code sessions, no latest_cwd)
3367
- */
3368
- export type CursorSessionSummary = {
3369
- session_id: string;
3370
- first_seen: string;
3371
- last_seen: string;
3372
- hook_count: number;
3373
- unique_tools: number;
3374
- };
3375
- export type CursorSessionsResponse = {
3376
- data: Array<CursorSessionSummary>;
3377
- page: number;
3378
- limit: number;
3379
- total: number;
3380
- total_pages: number;
3381
- };
3382
- export type CursorSessionsListResponse = {
3383
- status: string;
3384
- message: string;
3385
- data: CursorSessionsResponse;
3386
- };
3387
- /**
3388
- * Overview statistics for Cursor IDE (unlike Claude Code, no total_memories)
3389
- */
3390
- export type CursorOverviewStats = {
3391
- total_sessions: number;
3392
- sessions_this_week: number;
3393
- sessions_last_week: number;
3394
- weekly_trend_percent: number;
3395
- avg_user_prompts_per_session: number;
3396
- total_unique_tools: number;
3397
- top_tools: Array<{
3398
- tool_name?: string;
3399
- count?: number;
3400
- }>;
3401
- avg_session_duration_minutes: number;
3402
- };
3403
- export type CursorOverviewStatsApiResponse = {
3404
- status: string;
3405
- message: string;
3406
- data: CursorOverviewStats;
3407
- };
3408
- /**
3409
- * Recent Cursor IDE activity (carries `input` instead of Claude Code's cwd/tool_input)
3410
- */
3411
- export type CursorRecentActivity = {
3412
- session_id: string;
3413
- tool_name?: string | null;
3414
- input?: {
3415
- [key: string]: unknown;
3416
- } | null;
3417
- hook_event_name: string;
3418
- created_at: string;
3419
- };
3420
- export type CursorRecentActivitiesResponse = {
3421
- activities: Array<CursorRecentActivity>;
3422
- page: number;
3423
- limit: number;
3424
- total: number;
3425
- total_pages: number;
3426
- };
3427
- export type CursorRecentActivitiesApiResponse = {
3428
- status: string;
3429
- message: string;
3430
- data: CursorRecentActivitiesResponse;
3431
- };
3432
- /**
3433
- * A team (workspace) in the system. `role`, `permissions` and `member_count` are computed at read time for the requesting user.
3434
- */
3435
- export type Team = {
3436
- id: string;
3437
- /**
3438
- * User ID of the team owner
3439
- */
3440
- owner_id: string;
3441
- name: string;
3442
- slug: string;
3443
- description: string;
3444
- /**
3445
- * Whether this is the user's personal workspace (cannot be deleted or hold a team subscription)
3446
- */
3447
- is_personal: boolean;
3448
- /**
3449
- * The requesting user's role in this team: owner, admin, or member. Populated at runtime on every response that carries a team, including create (where the caller is by definition the owner). Not an enum constraint: older responses may still carry an empty string.
3450
- */
3451
- role?: string;
3452
- /**
3453
- * Exactly what `role` permits the requesting user to do in this team, expanded server-side from the role matrix (epic #220). Clients MUST gate their UI on these strings rather than re-deriving them from `role` — the matrix lives on the server and may change without a client release.
3454
- * Computed at read time for the requesting user, alongside `role`, and always present (an empty array means the role grants nothing). The values are stable API surface: renaming one is a breaking change, and they are kept byte-identical to the `internal/authz` constants by a drift test. Meanings:
3455
- * * `team.update` — change team name, slug or description. * `team.delete` — delete the team (owner only). * `team.transfer` — transfer ownership to another member (owner only). * `team.settings.update` — change team-level configuration, such as search ranking. * `member.invite` — invite new members. * `member.remove` — remove members from the team. * `member.role.update` — change a member's role. * `project.create` — create a project in the team. * `project.update` — update any project in the team. * `project.delete` — delete any project in the team. * `resource.create` — create a prompt, memory, artifact, blueprint or agent. * `resource.update.any` — update any resource, including other members'. * `resource.delete.own` — delete a resource the caller created. * `resource.delete.any` — delete a resource created by someone else. * `feed.delete.any` — delete another member's feed post or reply (moderation).
3456
- */
3457
- permissions: Array<'team.update' | 'team.delete' | 'team.transfer' | 'team.settings.update' | 'member.invite' | 'member.remove' | 'member.role.update' | 'project.create' | 'project.update' | 'project.delete' | 'resource.create' | 'resource.update.any' | 'resource.delete.own' | 'resource.delete.any' | 'feed.delete.any'>;
3458
- /**
3459
- * Number of members in this team. Populated only on list responses; 0 on create and single-team reads.
3460
- */
3461
- member_count?: number;
3462
- created_at: string;
3463
- updated_at: string;
3464
- };
3465
- /**
3466
- * Request body for creating a team
3467
- */
3468
- export type CreateTeamRequest = {
3469
- /**
3470
- * Team name (required, at most 100 characters)
3471
- */
3472
- name: string;
3473
- /**
3474
- * Optional team description (at most 500 characters)
3475
- */
3476
- description?: string;
3477
- };
3478
- /**
3479
- * Request body for updating a team. At least one of `name` or `description` must be provided.
3480
- */
3481
- export type UpdateTeamRequest = {
3482
- /**
3483
- * New team name (must be non-empty when provided)
3484
- */
3485
- name?: string;
3486
- /**
3487
- * New team description
3488
- */
3489
- description?: string;
3490
- };
3491
- /**
3492
- * Paginated list of teams the user belongs to
3493
- */
3494
- export type TeamListResponse = {
3495
- teams: Array<Team>;
3496
- total_count: number;
3497
- page: number;
3498
- page_size: number;
3499
- };
3500
- /**
3501
- * Detailed information about a team member, including invitation status
3502
- */
3503
- export type TeamMemberDetail = {
3504
- user_id: string;
3505
- email: string;
3506
- name: string;
3507
- role: 'owner' | 'admin' | 'member';
3508
- /**
3509
- * When the member joined the team
3510
- */
3511
- joined_at: string;
3512
- /**
3513
- * Invitation status for this member (omitted when not applicable)
3514
- */
3515
- invitation_status?: 'pending' | 'accepted';
3516
- };
3517
- /**
3518
- * Request body for changing a team member's role. Only `member` and `admin` are
3519
- * accepted: a team has exactly one owner, and ownership moves solely through
3520
- * the transfer-ownership operation.
3521
- *
3522
- */
3523
- export type UpdateTeamMemberRoleRequest = {
3524
- /**
3525
- * The role to assign to the member
3526
- */
3527
- role: 'member' | 'admin';
3528
- };
3529
- /**
3530
- * The team member after the role change
3531
- */
3532
- export type UpdateTeamMemberRoleResponse = {
3533
- member: TeamMemberDetail;
3534
- };
3535
- /**
3536
- * Request body for transferring team ownership. The target must already be a
3537
- * member of the team; they become the owner and the current owner becomes an
3538
- * admin, in a single transaction.
3539
- *
3540
- */
3541
- export type TransferTeamOwnershipRequest = {
3542
- /**
3543
- * User ID of the member who will become the team owner
3544
- */
3545
- new_owner_id: string;
3546
- };
3547
- /**
3548
- * The team after ownership has been transferred
3549
- */
3550
- export type TransferTeamOwnershipResponse = {
3551
- team: Team;
3552
- };
3553
- /**
3554
- * Paginated list of team members
3555
- */
3556
- export type TeamMembersListResponse = {
3557
- members: Array<TeamMemberDetail>;
3558
- total_count: number;
3559
- page: number;
3560
- page_size: number;
3561
- };
3562
- /**
3563
- * Request body for sending team invitations (1–50 email addresses per request)
3564
- */
3565
- export type SendInvitationsRequest = {
3566
- emails: Array<string>;
3567
- /**
3568
- * Role granted to invitees when they accept
3031
+ * Role granted to invitees when they accept
3569
3032
  */
3570
3033
  role: 'member' | 'admin';
3571
3034
  };
@@ -7397,107 +6860,49 @@ export type RestoreBlueprintVersionData = {
7397
6860
  /**
7398
6861
  * Team identifier
7399
6862
  */
7400
- team_id: string;
7401
- /**
7402
- * UUID of the project
7403
- */
7404
- project_id: string;
7405
- /**
7406
- * Blueprint slug
7407
- */
7408
- slug: string;
7409
- /**
7410
- * Version number to restore
7411
- */
7412
- version_number: number;
7413
- };
7414
- query?: never;
7415
- url: '/api/v1/{team_id}/blueprints/{project_id}/{slug}/versions/{version_number}/restore';
7416
- };
7417
- export type RestoreBlueprintVersionErrors = {
7418
- /**
7419
- * Invalid version_number
7420
- */
7421
- 400: ErrorResponse;
7422
- /**
7423
- * Unauthorized
7424
- */
7425
- 401: ErrorResponse;
7426
- /**
7427
- * Forbidden (not a team member)
7428
- */
7429
- 403: ErrorResponse;
7430
- /**
7431
- * Blueprint or version not found
7432
- */
7433
- 404: ErrorResponse;
7434
- };
7435
- export type RestoreBlueprintVersionError = RestoreBlueprintVersionErrors[keyof RestoreBlueprintVersionErrors];
7436
- export type RestoreBlueprintVersionResponses = {
7437
- /**
7438
- * Blueprint restored successfully
7439
- */
7440
- 200: Blueprint;
7441
- };
7442
- export type RestoreBlueprintVersionResponse = RestoreBlueprintVersionResponses[keyof RestoreBlueprintVersionResponses];
7443
- export type DeleteClaudeCodeSessionData = {
7444
- body?: never;
7445
- path: {
7446
- /**
7447
- * Session ID
7448
- */
7449
- session_id: string;
7450
- };
7451
- query?: never;
7452
- url: '/api/v1/ai-tools/claude-code/sessions/{session_id}';
7453
- };
7454
- export type DeleteClaudeCodeSessionErrors = {
7455
- /**
7456
- * Unauthorized
7457
- */
7458
- 401: ErrorResponse;
7459
- /**
7460
- * Session not found or access denied
7461
- */
7462
- 404: ErrorResponse;
7463
- };
7464
- export type DeleteClaudeCodeSessionError = DeleteClaudeCodeSessionErrors[keyof DeleteClaudeCodeSessionErrors];
7465
- export type DeleteClaudeCodeSessionResponses = {
7466
- /**
7467
- * Session deleted successfully
7468
- */
7469
- 204: void;
7470
- };
7471
- export type DeleteClaudeCodeSessionResponse = DeleteClaudeCodeSessionResponses[keyof DeleteClaudeCodeSessionResponses];
7472
- export type DeleteCursorIdeSessionData = {
7473
- body?: never;
7474
- path: {
6863
+ team_id: string;
6864
+ /**
6865
+ * UUID of the project
6866
+ */
6867
+ project_id: string;
6868
+ /**
6869
+ * Blueprint slug
6870
+ */
6871
+ slug: string;
7475
6872
  /**
7476
- * Session ID
6873
+ * Version number to restore
7477
6874
  */
7478
- session_id: string;
6875
+ version_number: number;
7479
6876
  };
7480
6877
  query?: never;
7481
- url: '/api/v1/ai-tools/cursor-ide/sessions/{session_id}';
6878
+ url: '/api/v1/{team_id}/blueprints/{project_id}/{slug}/versions/{version_number}/restore';
7482
6879
  };
7483
- export type DeleteCursorIdeSessionErrors = {
6880
+ export type RestoreBlueprintVersionErrors = {
6881
+ /**
6882
+ * Invalid version_number
6883
+ */
6884
+ 400: ErrorResponse;
7484
6885
  /**
7485
6886
  * Unauthorized
7486
6887
  */
7487
6888
  401: ErrorResponse;
7488
6889
  /**
7489
- * Session not found or access denied
6890
+ * Forbidden (not a team member)
6891
+ */
6892
+ 403: ErrorResponse;
6893
+ /**
6894
+ * Blueprint or version not found
7490
6895
  */
7491
6896
  404: ErrorResponse;
7492
6897
  };
7493
- export type DeleteCursorIdeSessionError = DeleteCursorIdeSessionErrors[keyof DeleteCursorIdeSessionErrors];
7494
- export type DeleteCursorIdeSessionResponses = {
6898
+ export type RestoreBlueprintVersionError = RestoreBlueprintVersionErrors[keyof RestoreBlueprintVersionErrors];
6899
+ export type RestoreBlueprintVersionResponses = {
7495
6900
  /**
7496
- * Session deleted successfully
6901
+ * Blueprint restored successfully
7497
6902
  */
7498
- 204: void;
6903
+ 200: Blueprint;
7499
6904
  };
7500
- export type DeleteCursorIdeSessionResponse = DeleteCursorIdeSessionResponses[keyof DeleteCursorIdeSessionResponses];
6905
+ export type RestoreBlueprintVersionResponse = RestoreBlueprintVersionResponses[keyof RestoreBlueprintVersionResponses];
7501
6906
  export type GetResourceUsageData = {
7502
6907
  body?: never;
7503
6908
  path?: never;
@@ -7631,252 +7036,18 @@ export type CreatePromptResponses = {
7631
7036
  201: Prompt;
7632
7037
  };
7633
7038
  export type CreatePromptResponse = CreatePromptResponses[keyof CreatePromptResponses];
7634
- export type GetPromptLabelsData = {
7635
- body?: never;
7636
- path: {
7637
- /**
7638
- * Team identifier
7639
- */
7640
- team_id: string;
7641
- };
7642
- query?: never;
7643
- url: '/api/v1/{team_id}/prompts/labels';
7644
- };
7645
- export type GetPromptLabelsErrors = {
7646
- /**
7647
- * Unauthorized
7648
- */
7649
- 401: ErrorResponse;
7650
- /**
7651
- * Forbidden (subscription required)
7652
- */
7653
- 403: ErrorResponse;
7654
- };
7655
- export type GetPromptLabelsError = GetPromptLabelsErrors[keyof GetPromptLabelsErrors];
7656
- export type GetPromptLabelsResponses = {
7657
- /**
7658
- * Labels retrieved successfully
7659
- */
7660
- 200: SuccessResponse & {
7661
- data: {
7662
- labels: Array<string>;
7663
- };
7664
- };
7665
- };
7666
- export type GetPromptLabelsResponse = GetPromptLabelsResponses[keyof GetPromptLabelsResponses];
7667
- export type DeletePromptData = {
7668
- body?: never;
7669
- path: {
7670
- /**
7671
- * Team identifier
7672
- */
7673
- team_id: string;
7674
- /**
7675
- * Prompt slug identifier
7676
- */
7677
- slug: string;
7678
- };
7679
- query?: never;
7680
- url: '/api/v1/{team_id}/prompts/{slug}';
7681
- };
7682
- export type DeletePromptErrors = {
7683
- /**
7684
- * Unauthorized
7685
- */
7686
- 401: ErrorResponse;
7687
- /**
7688
- * Forbidden (subscription required)
7689
- */
7690
- 403: ErrorResponse;
7691
- /**
7692
- * Prompt not found
7693
- */
7694
- 404: ErrorResponse;
7695
- };
7696
- export type DeletePromptError = DeletePromptErrors[keyof DeletePromptErrors];
7697
- export type DeletePromptResponses = {
7698
- /**
7699
- * Prompt deleted successfully
7700
- */
7701
- 204: void;
7702
- };
7703
- export type DeletePromptResponse = DeletePromptResponses[keyof DeletePromptResponses];
7704
- export type GetPromptData = {
7705
- body?: never;
7706
- path: {
7707
- /**
7708
- * Team identifier
7709
- */
7710
- team_id: string;
7711
- /**
7712
- * Prompt slug identifier
7713
- */
7714
- slug: string;
7715
- };
7716
- query?: never;
7717
- url: '/api/v1/{team_id}/prompts/{slug}';
7718
- };
7719
- export type GetPromptErrors = {
7720
- /**
7721
- * Unauthorized
7722
- */
7723
- 401: ErrorResponse;
7724
- /**
7725
- * Forbidden (subscription required)
7726
- */
7727
- 403: ErrorResponse;
7728
- /**
7729
- * Prompt not found
7730
- */
7731
- 404: ErrorResponse;
7732
- };
7733
- export type GetPromptError = GetPromptErrors[keyof GetPromptErrors];
7734
- export type GetPromptResponses = {
7735
- /**
7736
- * Prompt retrieved successfully
7737
- */
7738
- 200: Prompt;
7739
- };
7740
- export type GetPromptResponse = GetPromptResponses[keyof GetPromptResponses];
7741
- export type UpdatePromptData = {
7742
- body: UpdatePromptRequest;
7743
- path: {
7744
- /**
7745
- * Team identifier
7746
- */
7747
- team_id: string;
7748
- /**
7749
- * Prompt slug identifier
7750
- */
7751
- slug: string;
7752
- };
7753
- query?: never;
7754
- url: '/api/v1/{team_id}/prompts/{slug}';
7755
- };
7756
- export type UpdatePromptErrors = {
7757
- /**
7758
- * Invalid request (validation error)
7759
- */
7760
- 400: ErrorResponse;
7761
- /**
7762
- * Unauthorized
7763
- */
7764
- 401: ErrorResponse;
7765
- /**
7766
- * Forbidden (subscription required)
7767
- */
7768
- 403: ErrorResponse;
7769
- /**
7770
- * Prompt not found
7771
- */
7772
- 404: ErrorResponse;
7773
- /**
7774
- * Conflict (slug already exists)
7775
- */
7776
- 409: ErrorResponse;
7777
- };
7778
- export type UpdatePromptError = UpdatePromptErrors[keyof UpdatePromptErrors];
7779
- export type UpdatePromptResponses = {
7780
- /**
7781
- * Prompt updated successfully
7782
- */
7783
- 200: Prompt;
7784
- };
7785
- export type UpdatePromptResponse = UpdatePromptResponses[keyof UpdatePromptResponses];
7786
- export type GetPromptPlaceholdersData = {
7787
- body?: never;
7788
- path: {
7789
- /**
7790
- * Team identifier
7791
- */
7792
- team_id: string;
7793
- /**
7794
- * Prompt slug identifier
7795
- */
7796
- slug: string;
7797
- };
7798
- query?: never;
7799
- url: '/api/v1/{team_id}/prompts/{slug}/placeholders';
7800
- };
7801
- export type GetPromptPlaceholdersErrors = {
7802
- /**
7803
- * Unauthorized
7804
- */
7805
- 401: ErrorResponse;
7806
- /**
7807
- * Forbidden (subscription required)
7808
- */
7809
- 403: ErrorResponse;
7810
- /**
7811
- * Prompt not found
7812
- */
7813
- 404: ErrorResponse;
7814
- };
7815
- export type GetPromptPlaceholdersError = GetPromptPlaceholdersErrors[keyof GetPromptPlaceholdersErrors];
7816
- export type GetPromptPlaceholdersResponses = {
7817
- /**
7818
- * Placeholders retrieved successfully
7819
- */
7820
- 200: PromptPlaceholdersResponse;
7821
- };
7822
- export type GetPromptPlaceholdersResponse = GetPromptPlaceholdersResponses[keyof GetPromptPlaceholdersResponses];
7823
- export type GetPromptDependenciesData = {
7824
- body?: never;
7825
- path: {
7826
- /**
7827
- * Team identifier
7828
- */
7829
- team_id: string;
7830
- /**
7831
- * Prompt slug identifier
7832
- */
7833
- slug: string;
7834
- };
7835
- query?: never;
7836
- url: '/api/v1/{team_id}/prompts/{slug}/dependencies';
7837
- };
7838
- export type GetPromptDependenciesErrors = {
7839
- /**
7840
- * Unauthorized
7841
- */
7842
- 401: ErrorResponse;
7843
- /**
7844
- * Forbidden (subscription required)
7845
- */
7846
- 403: ErrorResponse;
7847
- /**
7848
- * Prompt not found
7849
- */
7850
- 404: ErrorResponse;
7851
- };
7852
- export type GetPromptDependenciesError = GetPromptDependenciesErrors[keyof GetPromptDependenciesErrors];
7853
- export type GetPromptDependenciesResponses = {
7854
- /**
7855
- * Dependencies retrieved successfully
7856
- */
7857
- 200: PromptDependenciesResponse;
7858
- };
7859
- export type GetPromptDependenciesResponse = GetPromptDependenciesResponses[keyof GetPromptDependenciesResponses];
7860
- export type RenderPromptData = {
7861
- body: RenderPromptRequest;
7039
+ export type GetPromptLabelsData = {
7040
+ body?: never;
7862
7041
  path: {
7863
7042
  /**
7864
7043
  * Team identifier
7865
7044
  */
7866
7045
  team_id: string;
7867
- /**
7868
- * Prompt slug identifier
7869
- */
7870
- slug: string;
7871
7046
  };
7872
7047
  query?: never;
7873
- url: '/api/v1/{team_id}/prompts/{slug}/render';
7048
+ url: '/api/v1/{team_id}/prompts/labels';
7874
7049
  };
7875
- export type RenderPromptErrors = {
7876
- /**
7877
- * Invalid request
7878
- */
7879
- 400: ErrorResponse;
7050
+ export type GetPromptLabelsErrors = {
7880
7051
  /**
7881
7052
  * Unauthorized
7882
7053
  */
@@ -7885,20 +7056,20 @@ export type RenderPromptErrors = {
7885
7056
  * Forbidden (subscription required)
7886
7057
  */
7887
7058
  403: ErrorResponse;
7888
- /**
7889
- * Prompt not found
7890
- */
7891
- 404: ErrorResponse;
7892
7059
  };
7893
- export type RenderPromptError = RenderPromptErrors[keyof RenderPromptErrors];
7894
- export type RenderPromptResponses = {
7060
+ export type GetPromptLabelsError = GetPromptLabelsErrors[keyof GetPromptLabelsErrors];
7061
+ export type GetPromptLabelsResponses = {
7895
7062
  /**
7896
- * Prompt rendered successfully
7063
+ * Labels retrieved successfully
7897
7064
  */
7898
- 200: RenderPromptResponse;
7065
+ 200: SuccessResponse & {
7066
+ data: {
7067
+ labels: Array<string>;
7068
+ };
7069
+ };
7899
7070
  };
7900
- export type RenderPromptResponse2 = RenderPromptResponses[keyof RenderPromptResponses];
7901
- export type DeletePromptShareData = {
7071
+ export type GetPromptLabelsResponse = GetPromptLabelsResponses[keyof GetPromptLabelsResponses];
7072
+ export type DeletePromptData = {
7902
7073
  body?: never;
7903
7074
  path: {
7904
7075
  /**
@@ -7911,9 +7082,9 @@ export type DeletePromptShareData = {
7911
7082
  slug: string;
7912
7083
  };
7913
7084
  query?: never;
7914
- url: '/api/v1/{team_id}/prompts/{slug}/share';
7085
+ url: '/api/v1/{team_id}/prompts/{slug}';
7915
7086
  };
7916
- export type DeletePromptShareErrors = {
7087
+ export type DeletePromptErrors = {
7917
7088
  /**
7918
7089
  * Unauthorized
7919
7090
  */
@@ -7923,19 +7094,19 @@ export type DeletePromptShareErrors = {
7923
7094
  */
7924
7095
  403: ErrorResponse;
7925
7096
  /**
7926
- * Prompt or share not found
7097
+ * Prompt not found
7927
7098
  */
7928
7099
  404: ErrorResponse;
7929
7100
  };
7930
- export type DeletePromptShareError = DeletePromptShareErrors[keyof DeletePromptShareErrors];
7931
- export type DeletePromptShareResponses = {
7101
+ export type DeletePromptError = DeletePromptErrors[keyof DeletePromptErrors];
7102
+ export type DeletePromptResponses = {
7932
7103
  /**
7933
- * Share deleted successfully
7104
+ * Prompt deleted successfully
7934
7105
  */
7935
7106
  204: void;
7936
7107
  };
7937
- export type DeletePromptShareResponse = DeletePromptShareResponses[keyof DeletePromptShareResponses];
7938
- export type GetPromptShareData = {
7108
+ export type DeletePromptResponse = DeletePromptResponses[keyof DeletePromptResponses];
7109
+ export type GetPromptData = {
7939
7110
  body?: never;
7940
7111
  path: {
7941
7112
  /**
@@ -7948,9 +7119,9 @@ export type GetPromptShareData = {
7948
7119
  slug: string;
7949
7120
  };
7950
7121
  query?: never;
7951
- url: '/api/v1/{team_id}/prompts/{slug}/share';
7122
+ url: '/api/v1/{team_id}/prompts/{slug}';
7952
7123
  };
7953
- export type GetPromptShareErrors = {
7124
+ export type GetPromptErrors = {
7954
7125
  /**
7955
7126
  * Unauthorized
7956
7127
  */
@@ -7960,20 +7131,20 @@ export type GetPromptShareErrors = {
7960
7131
  */
7961
7132
  403: ErrorResponse;
7962
7133
  /**
7963
- * Prompt or share not found
7134
+ * Prompt not found
7964
7135
  */
7965
7136
  404: ErrorResponse;
7966
7137
  };
7967
- export type GetPromptShareError = GetPromptShareErrors[keyof GetPromptShareErrors];
7968
- export type GetPromptShareResponses = {
7138
+ export type GetPromptError = GetPromptErrors[keyof GetPromptErrors];
7139
+ export type GetPromptResponses = {
7969
7140
  /**
7970
- * Share details retrieved successfully
7141
+ * Prompt retrieved successfully
7971
7142
  */
7972
- 200: ShareResponse;
7143
+ 200: Prompt;
7973
7144
  };
7974
- export type GetPromptShareResponse = GetPromptShareResponses[keyof GetPromptShareResponses];
7975
- export type CreatePromptShareData = {
7976
- body: CreateShareRequest;
7145
+ export type GetPromptResponse = GetPromptResponses[keyof GetPromptResponses];
7146
+ export type UpdatePromptData = {
7147
+ body: UpdatePromptRequest;
7977
7148
  path: {
7978
7149
  /**
7979
7150
  * Team identifier
@@ -7985,11 +7156,11 @@ export type CreatePromptShareData = {
7985
7156
  slug: string;
7986
7157
  };
7987
7158
  query?: never;
7988
- url: '/api/v1/{team_id}/prompts/{slug}/share';
7159
+ url: '/api/v1/{team_id}/prompts/{slug}';
7989
7160
  };
7990
- export type CreatePromptShareErrors = {
7161
+ export type UpdatePromptErrors = {
7991
7162
  /**
7992
- * Invalid request (e.g., restricted share without emails)
7163
+ * Invalid request (validation error)
7993
7164
  */
7994
7165
  400: ErrorResponse;
7995
7166
  /**
@@ -8004,16 +7175,20 @@ export type CreatePromptShareErrors = {
8004
7175
  * Prompt not found
8005
7176
  */
8006
7177
  404: ErrorResponse;
7178
+ /**
7179
+ * Conflict (slug already exists)
7180
+ */
7181
+ 409: ErrorResponse;
8007
7182
  };
8008
- export type CreatePromptShareError = CreatePromptShareErrors[keyof CreatePromptShareErrors];
8009
- export type CreatePromptShareResponses = {
7183
+ export type UpdatePromptError = UpdatePromptErrors[keyof UpdatePromptErrors];
7184
+ export type UpdatePromptResponses = {
8010
7185
  /**
8011
- * Share created or updated successfully
7186
+ * Prompt updated successfully
8012
7187
  */
8013
- 200: ShareResponse;
7188
+ 200: Prompt;
8014
7189
  };
8015
- export type CreatePromptShareResponse = CreatePromptShareResponses[keyof CreatePromptShareResponses];
8016
- export type ListPromptVersionsData = {
7190
+ export type UpdatePromptResponse = UpdatePromptResponses[keyof UpdatePromptResponses];
7191
+ export type GetPromptPlaceholdersData = {
8017
7192
  body?: never;
8018
7193
  path: {
8019
7194
  /**
@@ -8021,20 +7196,20 @@ export type ListPromptVersionsData = {
8021
7196
  */
8022
7197
  team_id: string;
8023
7198
  /**
8024
- * Prompt slug
7199
+ * Prompt slug identifier
8025
7200
  */
8026
7201
  slug: string;
8027
7202
  };
8028
7203
  query?: never;
8029
- url: '/api/v1/{team_id}/prompts/{slug}/versions';
7204
+ url: '/api/v1/{team_id}/prompts/{slug}/placeholders';
8030
7205
  };
8031
- export type ListPromptVersionsErrors = {
7206
+ export type GetPromptPlaceholdersErrors = {
8032
7207
  /**
8033
7208
  * Unauthorized
8034
7209
  */
8035
7210
  401: ErrorResponse;
8036
7211
  /**
8037
- * Forbidden (not a team member)
7212
+ * Forbidden (subscription required)
8038
7213
  */
8039
7214
  403: ErrorResponse;
8040
7215
  /**
@@ -8042,15 +7217,15 @@ export type ListPromptVersionsErrors = {
8042
7217
  */
8043
7218
  404: ErrorResponse;
8044
7219
  };
8045
- export type ListPromptVersionsError = ListPromptVersionsErrors[keyof ListPromptVersionsErrors];
8046
- export type ListPromptVersionsResponses = {
7220
+ export type GetPromptPlaceholdersError = GetPromptPlaceholdersErrors[keyof GetPromptPlaceholdersErrors];
7221
+ export type GetPromptPlaceholdersResponses = {
8047
7222
  /**
8048
- * Prompt versions retrieved successfully
7223
+ * Placeholders retrieved successfully
8049
7224
  */
8050
- 200: PromptVersionListResponse;
7225
+ 200: PromptPlaceholdersResponse;
8051
7226
  };
8052
- export type ListPromptVersionsResponse = ListPromptVersionsResponses[keyof ListPromptVersionsResponses];
8053
- export type GetPromptVersionData = {
7227
+ export type GetPromptPlaceholdersResponse = GetPromptPlaceholdersResponses[keyof GetPromptPlaceholdersResponses];
7228
+ export type GetPromptDependenciesData = {
8054
7229
  body?: never;
8055
7230
  path: {
8056
7231
  /**
@@ -8058,65 +7233,53 @@ export type GetPromptVersionData = {
8058
7233
  */
8059
7234
  team_id: string;
8060
7235
  /**
8061
- * Prompt slug
7236
+ * Prompt slug identifier
8062
7237
  */
8063
7238
  slug: string;
8064
- /**
8065
- * Version number
8066
- */
8067
- version_number: number;
8068
7239
  };
8069
7240
  query?: never;
8070
- url: '/api/v1/{team_id}/prompts/{slug}/versions/{version_number}';
7241
+ url: '/api/v1/{team_id}/prompts/{slug}/dependencies';
8071
7242
  };
8072
- export type GetPromptVersionErrors = {
8073
- /**
8074
- * Invalid version_number
8075
- */
8076
- 400: ErrorResponse;
7243
+ export type GetPromptDependenciesErrors = {
8077
7244
  /**
8078
7245
  * Unauthorized
8079
7246
  */
8080
7247
  401: ErrorResponse;
8081
7248
  /**
8082
- * Forbidden (not a team member)
7249
+ * Forbidden (subscription required)
8083
7250
  */
8084
7251
  403: ErrorResponse;
8085
7252
  /**
8086
- * Prompt or version not found
7253
+ * Prompt not found
8087
7254
  */
8088
7255
  404: ErrorResponse;
8089
7256
  };
8090
- export type GetPromptVersionError = GetPromptVersionErrors[keyof GetPromptVersionErrors];
8091
- export type GetPromptVersionResponses = {
7257
+ export type GetPromptDependenciesError = GetPromptDependenciesErrors[keyof GetPromptDependenciesErrors];
7258
+ export type GetPromptDependenciesResponses = {
8092
7259
  /**
8093
- * Prompt version retrieved successfully
7260
+ * Dependencies retrieved successfully
8094
7261
  */
8095
- 200: ContentVersion;
7262
+ 200: PromptDependenciesResponse;
8096
7263
  };
8097
- export type GetPromptVersionResponse = GetPromptVersionResponses[keyof GetPromptVersionResponses];
8098
- export type RestorePromptVersionData = {
8099
- body?: never;
7264
+ export type GetPromptDependenciesResponse = GetPromptDependenciesResponses[keyof GetPromptDependenciesResponses];
7265
+ export type RenderPromptData = {
7266
+ body: RenderPromptRequest;
8100
7267
  path: {
8101
7268
  /**
8102
7269
  * Team identifier
8103
7270
  */
8104
7271
  team_id: string;
8105
7272
  /**
8106
- * Prompt slug
7273
+ * Prompt slug identifier
8107
7274
  */
8108
7275
  slug: string;
8109
- /**
8110
- * Version number to restore
8111
- */
8112
- version_number: number;
8113
7276
  };
8114
7277
  query?: never;
8115
- url: '/api/v1/{team_id}/prompts/{slug}/versions/{version_number}/restore';
7278
+ url: '/api/v1/{team_id}/prompts/{slug}/render';
8116
7279
  };
8117
- export type RestorePromptVersionErrors = {
7280
+ export type RenderPromptErrors = {
8118
7281
  /**
8119
- * Invalid version_number
7282
+ * Invalid request
8120
7283
  */
8121
7284
  400: ErrorResponse;
8122
7285
  /**
@@ -8124,308 +7287,241 @@ export type RestorePromptVersionErrors = {
8124
7287
  */
8125
7288
  401: ErrorResponse;
8126
7289
  /**
8127
- * Forbidden (not a team member)
7290
+ * Forbidden (subscription required)
8128
7291
  */
8129
7292
  403: ErrorResponse;
8130
- /**
8131
- * Prompt or version not found
8132
- */
8133
- 404: ErrorResponse;
8134
- };
8135
- export type RestorePromptVersionError = RestorePromptVersionErrors[keyof RestorePromptVersionErrors];
8136
- export type RestorePromptVersionResponses = {
8137
- /**
8138
- * Prompt restored successfully
8139
- */
8140
- 200: Prompt;
8141
- };
8142
- export type RestorePromptVersionResponse = RestorePromptVersionResponses[keyof RestorePromptVersionResponses];
8143
- export type GetPromptGalleryCategoriesData = {
8144
- body?: never;
8145
- path?: never;
8146
- query?: never;
8147
- url: '/api/v1/prompt-gallery/categories';
8148
- };
8149
- export type GetPromptGalleryCategoriesErrors = {
8150
- /**
8151
- * Unauthorized
8152
- */
8153
- 401: ErrorResponse;
8154
- };
8155
- export type GetPromptGalleryCategoriesError = GetPromptGalleryCategoriesErrors[keyof GetPromptGalleryCategoriesErrors];
8156
- export type GetPromptGalleryCategoriesResponses = {
8157
- /**
8158
- * Categories retrieved successfully
8159
- */
8160
- 200: Array<PromptGalleryCategory>;
8161
- };
8162
- export type GetPromptGalleryCategoriesResponse = GetPromptGalleryCategoriesResponses[keyof GetPromptGalleryCategoriesResponses];
8163
- export type ListPromptGalleryPromptsData = {
8164
- body?: never;
8165
- path?: never;
8166
- query?: {
8167
- /**
8168
- * Filter by category
8169
- */
8170
- category?: string;
8171
- /**
8172
- * Search in title and description
8173
- */
8174
- search?: string;
8175
- /**
8176
- * Page number
8177
- */
8178
- page?: number;
8179
- /**
8180
- * Items per page
8181
- */
8182
- limit?: number;
8183
- };
8184
- url: '/api/v1/prompt-gallery/prompts';
8185
- };
8186
- export type ListPromptGalleryPromptsErrors = {
8187
- /**
8188
- * Unauthorized
8189
- */
8190
- 401: ErrorResponse;
8191
- };
8192
- export type ListPromptGalleryPromptsError = ListPromptGalleryPromptsErrors[keyof ListPromptGalleryPromptsErrors];
8193
- export type ListPromptGalleryPromptsResponses = {
8194
- /**
8195
- * Prompts retrieved successfully
8196
- */
8197
- 200: PromptGalleryListResponse;
8198
- };
8199
- export type ListPromptGalleryPromptsResponse = ListPromptGalleryPromptsResponses[keyof ListPromptGalleryPromptsResponses];
8200
- export type GetPromptGalleryPromptData = {
8201
- body?: never;
8202
- path: {
8203
- /**
8204
- * Prompt ID
8205
- */
8206
- id: string;
8207
- };
8208
- query?: never;
8209
- url: '/api/v1/prompt-gallery/prompts/{id}';
8210
- };
8211
- export type GetPromptGalleryPromptErrors = {
8212
- /**
8213
- * Unauthorized
8214
- */
8215
- 401: ErrorResponse;
8216
7293
  /**
8217
7294
  * Prompt not found
8218
7295
  */
8219
7296
  404: ErrorResponse;
8220
7297
  };
8221
- export type GetPromptGalleryPromptError = GetPromptGalleryPromptErrors[keyof GetPromptGalleryPromptErrors];
8222
- export type GetPromptGalleryPromptResponses = {
7298
+ export type RenderPromptError = RenderPromptErrors[keyof RenderPromptErrors];
7299
+ export type RenderPromptResponses = {
8223
7300
  /**
8224
- * Prompt retrieved successfully
7301
+ * Prompt rendered successfully
8225
7302
  */
8226
- 200: PromptGalleryTemplate;
7303
+ 200: RenderPromptResponse;
8227
7304
  };
8228
- export type GetPromptGalleryPromptResponse = GetPromptGalleryPromptResponses[keyof GetPromptGalleryPromptResponses];
8229
- export type TrackPromptGalleryUsageData = {
7305
+ export type RenderPromptResponse2 = RenderPromptResponses[keyof RenderPromptResponses];
7306
+ export type DeletePromptShareData = {
8230
7307
  body?: never;
8231
7308
  path: {
8232
7309
  /**
8233
- * Prompt ID
7310
+ * Team identifier
8234
7311
  */
8235
- id: string;
7312
+ team_id: string;
7313
+ /**
7314
+ * Prompt slug identifier
7315
+ */
7316
+ slug: string;
8236
7317
  };
8237
7318
  query?: never;
8238
- url: '/api/v1/prompt-gallery/prompts/{id}/use';
7319
+ url: '/api/v1/{team_id}/prompts/{slug}/share';
8239
7320
  };
8240
- export type TrackPromptGalleryUsageErrors = {
7321
+ export type DeletePromptShareErrors = {
8241
7322
  /**
8242
7323
  * Unauthorized
8243
7324
  */
8244
7325
  401: ErrorResponse;
8245
7326
  /**
8246
- * Prompt not found
7327
+ * Forbidden (subscription required)
7328
+ */
7329
+ 403: ErrorResponse;
7330
+ /**
7331
+ * Prompt or share not found
8247
7332
  */
8248
7333
  404: ErrorResponse;
8249
7334
  };
8250
- export type TrackPromptGalleryUsageError = TrackPromptGalleryUsageErrors[keyof TrackPromptGalleryUsageErrors];
8251
- export type TrackPromptGalleryUsageResponses = {
7335
+ export type DeletePromptShareError = DeletePromptShareErrors[keyof DeletePromptShareErrors];
7336
+ export type DeletePromptShareResponses = {
8252
7337
  /**
8253
- * Usage tracked successfully
7338
+ * Share deleted successfully
8254
7339
  */
8255
- 200: SuccessResponse;
7340
+ 204: void;
8256
7341
  };
8257
- export type TrackPromptGalleryUsageResponse = TrackPromptGalleryUsageResponses[keyof TrackPromptGalleryUsageResponses];
8258
- export type GetSharedPromptData = {
7342
+ export type DeletePromptShareResponse = DeletePromptShareResponses[keyof DeletePromptShareResponses];
7343
+ export type GetPromptShareData = {
8259
7344
  body?: never;
8260
7345
  path: {
8261
7346
  /**
8262
- * Share token
7347
+ * Team identifier
8263
7348
  */
8264
- token: string;
7349
+ team_id: string;
7350
+ /**
7351
+ * Prompt slug identifier
7352
+ */
7353
+ slug: string;
8265
7354
  };
8266
7355
  query?: never;
8267
- url: '/api/v1/shared/prompts/{token}';
7356
+ url: '/api/v1/{team_id}/prompts/{slug}/share';
8268
7357
  };
8269
- export type GetSharedPromptErrors = {
7358
+ export type GetPromptShareErrors = {
8270
7359
  /**
8271
- * Authentication required for restricted share
7360
+ * Unauthorized
8272
7361
  */
8273
7362
  401: ErrorResponse;
8274
7363
  /**
8275
- * Access denied (share disabled, expired, or email not in access list)
7364
+ * Forbidden (subscription required)
8276
7365
  */
8277
7366
  403: ErrorResponse;
8278
7367
  /**
8279
- * Shared prompt not found
7368
+ * Prompt or share not found
8280
7369
  */
8281
7370
  404: ErrorResponse;
8282
7371
  };
8283
- export type GetSharedPromptError = GetSharedPromptErrors[keyof GetSharedPromptErrors];
8284
- export type GetSharedPromptResponses = {
7372
+ export type GetPromptShareError = GetPromptShareErrors[keyof GetPromptShareErrors];
7373
+ export type GetPromptShareResponses = {
8285
7374
  /**
8286
- * Shared prompt retrieved successfully
7375
+ * Share details retrieved successfully
8287
7376
  */
8288
- 200: SharedPromptResponse;
7377
+ 200: ShareResponse;
8289
7378
  };
8290
- export type GetSharedPromptResponse = GetSharedPromptResponses[keyof GetSharedPromptResponses];
8291
- export type GetUsageAndGrowthData = {
8292
- body?: never;
8293
- path?: never;
8294
- query?: {
7379
+ export type GetPromptShareResponse = GetPromptShareResponses[keyof GetPromptShareResponses];
7380
+ export type CreatePromptShareData = {
7381
+ body: CreateShareRequest;
7382
+ path: {
8295
7383
  /**
8296
- * Filter data from this date (YYYY-MM-DD format). Both 'from' and 'to' must be provided together.
7384
+ * Team identifier
8297
7385
  */
8298
- from?: string;
7386
+ team_id: string;
8299
7387
  /**
8300
- * Filter data until this date (YYYY-MM-DD format). Both 'from' and 'to' must be provided together.
7388
+ * Prompt slug identifier
8301
7389
  */
8302
- to?: string;
7390
+ slug: string;
8303
7391
  };
8304
- url: '/bo/v1/reports/usage-and-growth';
7392
+ query?: never;
7393
+ url: '/api/v1/{team_id}/prompts/{slug}/share';
8305
7394
  };
8306
- export type GetUsageAndGrowthErrors = {
7395
+ export type CreatePromptShareErrors = {
8307
7396
  /**
8308
- * Invalid request parameters (e.g., invalid date format, 'to' before 'from')
7397
+ * Invalid request (e.g., restricted share without emails)
8309
7398
  */
8310
7399
  400: ErrorResponse;
8311
7400
  /**
8312
- * Unauthorized - Missing or invalid back office admin API key
7401
+ * Unauthorized
8313
7402
  */
8314
7403
  401: ErrorResponse;
8315
7404
  /**
8316
- * Internal server error
7405
+ * Forbidden (subscription required)
8317
7406
  */
8318
- 500: ErrorResponse;
7407
+ 403: ErrorResponse;
7408
+ /**
7409
+ * Prompt not found
7410
+ */
7411
+ 404: ErrorResponse;
8319
7412
  };
8320
- export type GetUsageAndGrowthError = GetUsageAndGrowthErrors[keyof GetUsageAndGrowthErrors];
8321
- export type GetUsageAndGrowthResponses = {
7413
+ export type CreatePromptShareError = CreatePromptShareErrors[keyof CreatePromptShareErrors];
7414
+ export type CreatePromptShareResponses = {
8322
7415
  /**
8323
- * Usage and growth data retrieved successfully
7416
+ * Share created or updated successfully
8324
7417
  */
8325
- 200: UsageAndGrowthResponse;
7418
+ 200: ShareResponse;
8326
7419
  };
8327
- export type GetUsageAndGrowthResponse = GetUsageAndGrowthResponses[keyof GetUsageAndGrowthResponses];
8328
- export type GetGitHubStatusData = {
7420
+ export type CreatePromptShareResponse = CreatePromptShareResponses[keyof CreatePromptShareResponses];
7421
+ export type ListPromptVersionsData = {
8329
7422
  body?: never;
8330
7423
  path: {
8331
7424
  /**
8332
- * Team ID (UUID)
7425
+ * Team identifier
8333
7426
  */
8334
7427
  team_id: string;
7428
+ /**
7429
+ * Prompt slug
7430
+ */
7431
+ slug: string;
8335
7432
  };
8336
7433
  query?: never;
8337
- url: '/api/v1/{team_id}/integrations/github/status';
7434
+ url: '/api/v1/{team_id}/prompts/{slug}/versions';
8338
7435
  };
8339
- export type GetGitHubStatusErrors = {
7436
+ export type ListPromptVersionsErrors = {
8340
7437
  /**
8341
7438
  * Unauthorized
8342
7439
  */
8343
7440
  401: ErrorResponse;
8344
7441
  /**
8345
- * Forbidden - user does not have access to this team
7442
+ * Forbidden (not a team member)
8346
7443
  */
8347
7444
  403: ErrorResponse;
8348
7445
  /**
8349
- * Internal server error
7446
+ * Prompt not found
8350
7447
  */
8351
- 500: ErrorResponse;
7448
+ 404: ErrorResponse;
8352
7449
  };
8353
- export type GetGitHubStatusError = GetGitHubStatusErrors[keyof GetGitHubStatusErrors];
8354
- export type GetGitHubStatusResponses = {
7450
+ export type ListPromptVersionsError = ListPromptVersionsErrors[keyof ListPromptVersionsErrors];
7451
+ export type ListPromptVersionsResponses = {
8355
7452
  /**
8356
- * GitHub installation status retrieved successfully
7453
+ * Prompt versions retrieved successfully
8357
7454
  */
8358
- 200: GitHubInstallationStatus;
7455
+ 200: PromptVersionListResponse;
8359
7456
  };
8360
- export type GetGitHubStatusResponse = GetGitHubStatusResponses[keyof GetGitHubStatusResponses];
8361
- export type GetGitHubInstallUrlData = {
7457
+ export type ListPromptVersionsResponse = ListPromptVersionsResponses[keyof ListPromptVersionsResponses];
7458
+ export type GetPromptVersionData = {
8362
7459
  body?: never;
8363
7460
  path: {
8364
7461
  /**
8365
- * Team ID (UUID)
7462
+ * Team identifier
8366
7463
  */
8367
7464
  team_id: string;
7465
+ /**
7466
+ * Prompt slug
7467
+ */
7468
+ slug: string;
7469
+ /**
7470
+ * Version number
7471
+ */
7472
+ version_number: number;
8368
7473
  };
8369
7474
  query?: never;
8370
- url: '/api/v1/{team_id}/integrations/github/install-url';
7475
+ url: '/api/v1/{team_id}/prompts/{slug}/versions/{version_number}';
8371
7476
  };
8372
- export type GetGitHubInstallUrlErrors = {
7477
+ export type GetPromptVersionErrors = {
7478
+ /**
7479
+ * Invalid version_number
7480
+ */
7481
+ 400: ErrorResponse;
8373
7482
  /**
8374
7483
  * Unauthorized
8375
7484
  */
8376
7485
  401: ErrorResponse;
8377
7486
  /**
8378
- * Forbidden - user does not have access to this team, or is not a team owner/admin
7487
+ * Forbidden (not a team member)
8379
7488
  */
8380
7489
  403: ErrorResponse;
8381
7490
  /**
8382
- * Conflict - the team has no GitHub App configured, so there is no App slug to build an install URL from. Register the team's App first.
8383
- */
8384
- 409: ErrorResponse;
8385
- /**
8386
- * Internal server error
7491
+ * Prompt or version not found
8387
7492
  */
8388
- 500: ErrorResponse;
7493
+ 404: ErrorResponse;
8389
7494
  };
8390
- export type GetGitHubInstallUrlError = GetGitHubInstallUrlErrors[keyof GetGitHubInstallUrlErrors];
8391
- export type GetGitHubInstallUrlResponses = {
7495
+ export type GetPromptVersionError = GetPromptVersionErrors[keyof GetPromptVersionErrors];
7496
+ export type GetPromptVersionResponses = {
8392
7497
  /**
8393
- * Install URL generated successfully
7498
+ * Prompt version retrieved successfully
8394
7499
  */
8395
- 200: GitHubInstallUrl;
7500
+ 200: ContentVersion;
8396
7501
  };
8397
- export type GetGitHubInstallUrlResponse = GetGitHubInstallUrlResponses[keyof GetGitHubInstallUrlResponses];
8398
- export type HandleGitHubCallbackData = {
8399
- body: {
8400
- /**
8401
- * GitHub App installation ID from the callback URL
8402
- */
8403
- installation_id: number;
8404
- /**
8405
- * Setup action reported by GitHub on the callback URL (e.g. "install"). Accepted for forward compatibility but currently ignored server-side.
8406
- */
8407
- setup_action?: string;
7502
+ export type GetPromptVersionResponse = GetPromptVersionResponses[keyof GetPromptVersionResponses];
7503
+ export type RestorePromptVersionData = {
7504
+ body?: never;
7505
+ path: {
8408
7506
  /**
8409
- * HMAC-signed state parameter from the install URL (CSRF protection). It is bound to the team's GitHub App config, so a state minted before the team replaced or rotated its App is no longer redeemable.
7507
+ * Team identifier
8410
7508
  */
8411
- state: string;
7509
+ team_id: string;
8412
7510
  /**
8413
- * OAuth authorization code from GitHub's post-install redirect. Exchanged server-side for a user access token to verify the caller has access to the installation on GitHub.
7511
+ * Prompt slug
8414
7512
  */
8415
- code: string;
8416
- };
8417
- path: {
7513
+ slug: string;
8418
7514
  /**
8419
- * Team ID (UUID)
7515
+ * Version number to restore
8420
7516
  */
8421
- team_id: string;
7517
+ version_number: number;
8422
7518
  };
8423
7519
  query?: never;
8424
- url: '/api/v1/{team_id}/integrations/github/callback';
7520
+ url: '/api/v1/{team_id}/prompts/{slug}/versions/{version_number}/restore';
8425
7521
  };
8426
- export type HandleGitHubCallbackErrors = {
7522
+ export type RestorePromptVersionErrors = {
8427
7523
  /**
8428
- * Invalid request body, missing required fields, an invalid/expired state parameter, or a state bound to a different installation or GitHub App than the team's current one
7524
+ * Invalid version_number
8429
7525
  */
8430
7526
  400: ErrorResponse;
8431
7527
  /**
@@ -8433,326 +7529,308 @@ export type HandleGitHubCallbackErrors = {
8433
7529
  */
8434
7530
  401: ErrorResponse;
8435
7531
  /**
8436
- * Forbidden - state does not match team, the caller is not a team owner/admin, or the caller has no access to the submitted GitHub App installation on GitHub
7532
+ * Forbidden (not a team member)
8437
7533
  */
8438
7534
  403: ErrorResponse;
8439
7535
  /**
8440
- * Conflict - this GitHub organization is already connected to another team, or the team has no GitHub App configured to complete the installation against
7536
+ * Prompt or version not found
8441
7537
  */
8442
- 409: ErrorResponse;
7538
+ 404: ErrorResponse;
7539
+ };
7540
+ export type RestorePromptVersionError = RestorePromptVersionErrors[keyof RestorePromptVersionErrors];
7541
+ export type RestorePromptVersionResponses = {
8443
7542
  /**
8444
- * Internal server error
7543
+ * Prompt restored successfully
8445
7544
  */
8446
- 500: ErrorResponse;
7545
+ 200: Prompt;
7546
+ };
7547
+ export type RestorePromptVersionResponse = RestorePromptVersionResponses[keyof RestorePromptVersionResponses];
7548
+ export type GetPromptGalleryCategoriesData = {
7549
+ body?: never;
7550
+ path?: never;
7551
+ query?: never;
7552
+ url: '/api/v1/prompt-gallery/categories';
7553
+ };
7554
+ export type GetPromptGalleryCategoriesErrors = {
7555
+ /**
7556
+ * Unauthorized
7557
+ */
7558
+ 401: ErrorResponse;
7559
+ };
7560
+ export type GetPromptGalleryCategoriesError = GetPromptGalleryCategoriesErrors[keyof GetPromptGalleryCategoriesErrors];
7561
+ export type GetPromptGalleryCategoriesResponses = {
7562
+ /**
7563
+ * Categories retrieved successfully
7564
+ */
7565
+ 200: Array<PromptGalleryCategory>;
7566
+ };
7567
+ export type GetPromptGalleryCategoriesResponse = GetPromptGalleryCategoriesResponses[keyof GetPromptGalleryCategoriesResponses];
7568
+ export type ListPromptGalleryPromptsData = {
7569
+ body?: never;
7570
+ path?: never;
7571
+ query?: {
7572
+ /**
7573
+ * Filter by category
7574
+ */
7575
+ category?: string;
7576
+ /**
7577
+ * Search in title and description
7578
+ */
7579
+ search?: string;
7580
+ /**
7581
+ * Page number
7582
+ */
7583
+ page?: number;
7584
+ /**
7585
+ * Items per page
7586
+ */
7587
+ limit?: number;
7588
+ };
7589
+ url: '/api/v1/prompt-gallery/prompts';
7590
+ };
7591
+ export type ListPromptGalleryPromptsErrors = {
8447
7592
  /**
8448
- * GitHub App user authorization is not configured on this instance, so caller authority cannot be verified and the installation is not connected
7593
+ * Unauthorized
8449
7594
  */
8450
- 503: ErrorResponse;
7595
+ 401: ErrorResponse;
8451
7596
  };
8452
- export type HandleGitHubCallbackError = HandleGitHubCallbackErrors[keyof HandleGitHubCallbackErrors];
8453
- export type HandleGitHubCallbackResponses = {
7597
+ export type ListPromptGalleryPromptsError = ListPromptGalleryPromptsErrors[keyof ListPromptGalleryPromptsErrors];
7598
+ export type ListPromptGalleryPromptsResponses = {
8454
7599
  /**
8455
- * GitHub App installation connected successfully
7600
+ * Prompts retrieved successfully
8456
7601
  */
8457
- 201: GitHubCallbackResponse;
7602
+ 200: PromptGalleryListResponse;
8458
7603
  };
8459
- export type HandleGitHubCallbackResponse = HandleGitHubCallbackResponses[keyof HandleGitHubCallbackResponses];
8460
- export type ListGitHubRepositoriesData = {
7604
+ export type ListPromptGalleryPromptsResponse = ListPromptGalleryPromptsResponses[keyof ListPromptGalleryPromptsResponses];
7605
+ export type GetPromptGalleryPromptData = {
8461
7606
  body?: never;
8462
7607
  path: {
8463
7608
  /**
8464
- * Team ID (UUID)
8465
- */
8466
- team_id: string;
8467
- };
8468
- query?: {
8469
- /**
8470
- * Page number for pagination (1-based)
7609
+ * Prompt ID
8471
7610
  */
8472
- page?: number;
7611
+ id: string;
8473
7612
  };
8474
- url: '/api/v1/{team_id}/integrations/github/repositories';
7613
+ query?: never;
7614
+ url: '/api/v1/prompt-gallery/prompts/{id}';
8475
7615
  };
8476
- export type ListGitHubRepositoriesErrors = {
7616
+ export type GetPromptGalleryPromptErrors = {
8477
7617
  /**
8478
7618
  * Unauthorized
8479
7619
  */
8480
7620
  401: ErrorResponse;
8481
7621
  /**
8482
- * Forbidden - user does not have access to this team
8483
- */
8484
- 403: ErrorResponse;
8485
- /**
8486
- * GitHub App not installed for this team
7622
+ * Prompt not found
8487
7623
  */
8488
7624
  404: ErrorResponse;
8489
- /**
8490
- * Internal server error
8491
- */
8492
- 500: ErrorResponse;
8493
7625
  };
8494
- export type ListGitHubRepositoriesError = ListGitHubRepositoriesErrors[keyof ListGitHubRepositoriesErrors];
8495
- export type ListGitHubRepositoriesResponses = {
7626
+ export type GetPromptGalleryPromptError = GetPromptGalleryPromptErrors[keyof GetPromptGalleryPromptErrors];
7627
+ export type GetPromptGalleryPromptResponses = {
8496
7628
  /**
8497
- * Repositories listed successfully
7629
+ * Prompt retrieved successfully
8498
7630
  */
8499
- 200: GitHubRepositoriesResponse;
7631
+ 200: PromptGalleryTemplate;
8500
7632
  };
8501
- export type ListGitHubRepositoriesResponse = ListGitHubRepositoriesResponses[keyof ListGitHubRepositoriesResponses];
8502
- export type ImportGitHubProjectData = {
7633
+ export type GetPromptGalleryPromptResponse = GetPromptGalleryPromptResponses[keyof GetPromptGalleryPromptResponses];
7634
+ export type TrackPromptGalleryUsageData = {
8503
7635
  body?: never;
8504
7636
  path: {
8505
7637
  /**
8506
- * Team ID (UUID)
8507
- */
8508
- team_id: string;
8509
- /**
8510
- * GitHub repository ID
7638
+ * Prompt ID
8511
7639
  */
8512
- repo_id: number;
7640
+ id: string;
8513
7641
  };
8514
7642
  query?: never;
8515
- url: '/api/v1/{team_id}/integrations/github/repositories/{repo_id}/import-project';
7643
+ url: '/api/v1/prompt-gallery/prompts/{id}/use';
8516
7644
  };
8517
- export type ImportGitHubProjectErrors = {
8518
- /**
8519
- * Invalid repository ID
8520
- */
8521
- 400: ErrorResponse;
7645
+ export type TrackPromptGalleryUsageErrors = {
8522
7646
  /**
8523
7647
  * Unauthorized
8524
7648
  */
8525
7649
  401: ErrorResponse;
8526
7650
  /**
8527
- * Forbidden - user does not have access to this team
8528
- */
8529
- 403: ErrorResponse;
8530
- /**
8531
- * GitHub App not installed for this team or repository not found
7651
+ * Prompt not found
8532
7652
  */
8533
7653
  404: ErrorResponse;
8534
- /**
8535
- * Internal server error
8536
- */
8537
- 500: ErrorResponse;
8538
7654
  };
8539
- export type ImportGitHubProjectError = ImportGitHubProjectErrors[keyof ImportGitHubProjectErrors];
8540
- export type ImportGitHubProjectResponses = {
8541
- /**
8542
- * Project already exists — returned without creating a new one
8543
- */
8544
- 200: {
8545
- project: Project;
8546
- created: boolean;
8547
- message?: string;
8548
- };
7655
+ export type TrackPromptGalleryUsageError = TrackPromptGalleryUsageErrors[keyof TrackPromptGalleryUsageErrors];
7656
+ export type TrackPromptGalleryUsageResponses = {
8549
7657
  /**
8550
- * Project created successfully from the GitHub repository
7658
+ * Usage tracked successfully
8551
7659
  */
8552
- 201: {
8553
- project: Project;
8554
- created: boolean;
8555
- };
7660
+ 200: SuccessResponse;
8556
7661
  };
8557
- export type ImportGitHubProjectResponse = ImportGitHubProjectResponses[keyof ImportGitHubProjectResponses];
8558
- export type ImportGitHubBlueprintsData = {
8559
- body: {
8560
- /**
8561
- * GitHub repository ID to import blueprints from
8562
- */
8563
- repository_id: number;
8564
- };
7662
+ export type TrackPromptGalleryUsageResponse = TrackPromptGalleryUsageResponses[keyof TrackPromptGalleryUsageResponses];
7663
+ export type GetSharedPromptData = {
7664
+ body?: never;
8565
7665
  path: {
8566
7666
  /**
8567
- * Team ID (UUID)
7667
+ * Share token
8568
7668
  */
8569
- team_id: string;
7669
+ token: string;
8570
7670
  };
8571
7671
  query?: never;
8572
- url: '/api/v1/{team_id}/integrations/github/import-blueprints';
7672
+ url: '/api/v1/shared/prompts/{token}';
8573
7673
  };
8574
- export type ImportGitHubBlueprintsErrors = {
8575
- /**
8576
- * Invalid request body or missing repository_id
8577
- */
8578
- 400: ErrorResponse;
7674
+ export type GetSharedPromptErrors = {
8579
7675
  /**
8580
- * Unauthorized
7676
+ * Authentication required for restricted share
8581
7677
  */
8582
7678
  401: ErrorResponse;
8583
7679
  /**
8584
- * Forbidden - user does not have access to this team
7680
+ * Access denied (share disabled, expired, or email not in access list)
8585
7681
  */
8586
7682
  403: ErrorResponse;
8587
7683
  /**
8588
- * GitHub App not installed for this team or repository not found
7684
+ * Shared prompt not found
8589
7685
  */
8590
7686
  404: ErrorResponse;
8591
- /**
8592
- * Precondition Failed - no project exists for this repository; import the repository as a project first
8593
- */
8594
- 412: ErrorResponse;
8595
- /**
8596
- * Internal server error
8597
- */
8598
- 500: ErrorResponse;
8599
7687
  };
8600
- export type ImportGitHubBlueprintsError = ImportGitHubBlueprintsErrors[keyof ImportGitHubBlueprintsErrors];
8601
- export type ImportGitHubBlueprintsResponses = {
7688
+ export type GetSharedPromptError = GetSharedPromptErrors[keyof GetSharedPromptErrors];
7689
+ export type GetSharedPromptResponses = {
8602
7690
  /**
8603
- * Import completed check the report for per-file results
7691
+ * Shared prompt retrieved successfully
8604
7692
  */
8605
- 200: BlueprintImportReport;
7693
+ 200: SharedPromptResponse;
8606
7694
  };
8607
- export type ImportGitHubBlueprintsResponse = ImportGitHubBlueprintsResponses[keyof ImportGitHubBlueprintsResponses];
8608
- export type DisconnectGitHubData = {
7695
+ export type GetSharedPromptResponse = GetSharedPromptResponses[keyof GetSharedPromptResponses];
7696
+ export type GetUsageAndGrowthData = {
8609
7697
  body?: never;
8610
- path: {
7698
+ path?: never;
7699
+ query?: {
8611
7700
  /**
8612
- * Team ID (UUID)
7701
+ * Filter data from this date (YYYY-MM-DD format). Both 'from' and 'to' must be provided together.
8613
7702
  */
8614
- team_id: string;
7703
+ from?: string;
7704
+ /**
7705
+ * Filter data until this date (YYYY-MM-DD format). Both 'from' and 'to' must be provided together.
7706
+ */
7707
+ to?: string;
8615
7708
  };
8616
- query?: never;
8617
- url: '/api/v1/{team_id}/integrations/github/disconnect';
7709
+ url: '/bo/v1/reports/usage-and-growth';
8618
7710
  };
8619
- export type DisconnectGitHubErrors = {
7711
+ export type GetUsageAndGrowthErrors = {
8620
7712
  /**
8621
- * Unauthorized
7713
+ * Invalid request parameters (e.g., invalid date format, 'to' before 'from')
8622
7714
  */
8623
- 401: ErrorResponse;
7715
+ 400: ErrorResponse;
8624
7716
  /**
8625
- * Forbidden - user does not have access to this team
7717
+ * Unauthorized - Missing or invalid back office admin API key
8626
7718
  */
8627
- 403: ErrorResponse;
7719
+ 401: ErrorResponse;
8628
7720
  /**
8629
7721
  * Internal server error
8630
7722
  */
8631
7723
  500: ErrorResponse;
8632
7724
  };
8633
- export type DisconnectGitHubError = DisconnectGitHubErrors[keyof DisconnectGitHubErrors];
8634
- export type DisconnectGitHubResponses = {
8635
- /**
8636
- * GitHub installation disconnected successfully
8637
- */
8638
- 204: void;
8639
- };
8640
- export type DisconnectGitHubResponse = DisconnectGitHubResponses[keyof DisconnectGitHubResponses];
8641
- export type HandleGitHubWebhookData = {
8642
- /**
8643
- * GitHub webhook event payload (varies by event type)
8644
- */
8645
- body: {
8646
- [key: string]: unknown;
8647
- };
8648
- path?: never;
8649
- query?: never;
8650
- url: '/api/v1/webhooks/github';
8651
- };
8652
- export type HandleGitHubWebhookErrors = {
7725
+ export type GetUsageAndGrowthError = GetUsageAndGrowthErrors[keyof GetUsageAndGrowthErrors];
7726
+ export type GetUsageAndGrowthResponses = {
8653
7727
  /**
8654
- * Endpoint retired; use the team's per-App webhook URL
7728
+ * Usage and growth data retrieved successfully
8655
7729
  */
8656
- 410: ErrorResponse;
7730
+ 200: UsageAndGrowthResponse;
8657
7731
  };
8658
- export type HandleGitHubWebhookError = HandleGitHubWebhookErrors[keyof HandleGitHubWebhookErrors];
8659
- export type HandleGitHubWebhookByTokenData = {
8660
- /**
8661
- * GitHub webhook event payload (varies by event type)
8662
- */
8663
- body: {
8664
- [key: string]: unknown;
8665
- };
7732
+ export type GetUsageAndGrowthResponse = GetUsageAndGrowthResponses[keyof GetUsageAndGrowthResponses];
7733
+ export type GetGitHubStatusData = {
7734
+ body?: never;
8666
7735
  path: {
8667
7736
  /**
8668
- * Opaque routing token identifying which team's GitHub App this delivery belongs to. Minted as unpadded URL-safe base64, so it needs no percent-encoding. Treat it as a secret: it selects the secret the signature is verified against, and it is redacted from access logs.
7737
+ * Team ID (UUID)
8669
7738
  */
8670
- token: string;
7739
+ team_id: string;
8671
7740
  };
8672
7741
  query?: never;
8673
- url: '/api/v1/webhooks/github/{token}';
7742
+ url: '/api/v1/{team_id}/integrations/github/status';
8674
7743
  };
8675
- export type HandleGitHubWebhookByTokenErrors = {
8676
- /**
8677
- * Unreadable body, unparseable payload, or missing installation reference
8678
- */
8679
- 400: ErrorResponse;
7744
+ export type GetGitHubStatusErrors = {
8680
7745
  /**
8681
- * Missing or invalid `X-Hub-Signature-256`
7746
+ * Unauthorized
8682
7747
  */
8683
7748
  401: ErrorResponse;
8684
7749
  /**
8685
- * Unknown or malformed routing token (deliberately indistinguishable)
7750
+ * Forbidden - user does not have access to this team
8686
7751
  */
8687
- 404: ErrorResponse;
7752
+ 403: ErrorResponse;
8688
7753
  /**
8689
7754
  * Internal server error
8690
7755
  */
8691
7756
  500: ErrorResponse;
8692
7757
  };
8693
- export type HandleGitHubWebhookByTokenError = HandleGitHubWebhookByTokenErrors[keyof HandleGitHubWebhookByTokenErrors];
8694
- export type HandleGitHubWebhookByTokenResponses = {
7758
+ export type GetGitHubStatusError = GetGitHubStatusErrors[keyof GetGitHubStatusErrors];
7759
+ export type GetGitHubStatusResponses = {
8695
7760
  /**
8696
- * Delivery accepted (or already processed — dedup by delivery id)
7761
+ * GitHub installation status retrieved successfully
8697
7762
  */
8698
- 200: unknown;
7763
+ 200: GitHubInstallationStatus;
8699
7764
  };
8700
- export type ListFeedsData = {
8701
- body?: never;
8702
- path: {
8703
- /**
8704
- * Team identifier
8705
- */
8706
- team_id: string;
8707
- };
8708
- query?: {
8709
- /**
8710
- * Search in feed name and description
8711
- */
8712
- search?: string;
8713
- /**
8714
- * Page number (default 1)
8715
- */
8716
- page?: number;
7765
+ export type GetGitHubStatusResponse = GetGitHubStatusResponses[keyof GetGitHubStatusResponses];
7766
+ export type GetGitHubInstallUrlData = {
7767
+ body?: never;
7768
+ path: {
8717
7769
  /**
8718
- * Items per page (default 20, max 100)
7770
+ * Team ID (UUID)
8719
7771
  */
8720
- limit?: number;
7772
+ team_id: string;
8721
7773
  };
8722
- url: '/api/v1/{team_id}/feeds';
7774
+ query?: never;
7775
+ url: '/api/v1/{team_id}/integrations/github/install-url';
8723
7776
  };
8724
- export type ListFeedsErrors = {
7777
+ export type GetGitHubInstallUrlErrors = {
8725
7778
  /**
8726
7779
  * Unauthorized
8727
7780
  */
8728
7781
  401: ErrorResponse;
8729
7782
  /**
8730
- * Forbidden not a team member
7783
+ * Forbidden - user does not have access to this team, or is not a team owner/admin
8731
7784
  */
8732
7785
  403: ErrorResponse;
7786
+ /**
7787
+ * Conflict - the team has no GitHub App configured, so there is no App slug to build an install URL from. Register the team's App first.
7788
+ */
7789
+ 409: ErrorResponse;
7790
+ /**
7791
+ * Internal server error
7792
+ */
7793
+ 500: ErrorResponse;
8733
7794
  };
8734
- export type ListFeedsError = ListFeedsErrors[keyof ListFeedsErrors];
8735
- export type ListFeedsResponses = {
7795
+ export type GetGitHubInstallUrlError = GetGitHubInstallUrlErrors[keyof GetGitHubInstallUrlErrors];
7796
+ export type GetGitHubInstallUrlResponses = {
8736
7797
  /**
8737
- * Feeds retrieved successfully
7798
+ * Install URL generated successfully
8738
7799
  */
8739
- 200: FeedListResponse;
7800
+ 200: GitHubInstallUrl;
8740
7801
  };
8741
- export type ListFeedsResponse = ListFeedsResponses[keyof ListFeedsResponses];
8742
- export type CreateFeedData = {
8743
- body: CreateFeedRequest;
7802
+ export type GetGitHubInstallUrlResponse = GetGitHubInstallUrlResponses[keyof GetGitHubInstallUrlResponses];
7803
+ export type HandleGitHubCallbackData = {
7804
+ body: {
7805
+ /**
7806
+ * GitHub App installation ID from the callback URL
7807
+ */
7808
+ installation_id: number;
7809
+ /**
7810
+ * Setup action reported by GitHub on the callback URL (e.g. "install"). Accepted for forward compatibility but currently ignored server-side.
7811
+ */
7812
+ setup_action?: string;
7813
+ /**
7814
+ * HMAC-signed state parameter from the install URL (CSRF protection). It is bound to the team's GitHub App config, so a state minted before the team replaced or rotated its App is no longer redeemable.
7815
+ */
7816
+ state: string;
7817
+ /**
7818
+ * OAuth authorization code from GitHub's post-install redirect. Exchanged server-side for a user access token to verify the caller has access to the installation on GitHub.
7819
+ */
7820
+ code: string;
7821
+ };
8744
7822
  path: {
8745
7823
  /**
8746
- * Team identifier
7824
+ * Team ID (UUID)
8747
7825
  */
8748
7826
  team_id: string;
8749
7827
  };
8750
7828
  query?: never;
8751
- url: '/api/v1/{team_id}/feeds';
7829
+ url: '/api/v1/{team_id}/integrations/github/callback';
8752
7830
  };
8753
- export type CreateFeedErrors = {
7831
+ export type HandleGitHubCallbackErrors = {
8754
7832
  /**
8755
- * Invalid request data or validation error
7833
+ * Invalid request body, missing required fields, an invalid/expired state parameter, or a state bound to a different installation or GitHub App than the team's current one
8756
7834
  */
8757
7835
  400: ErrorResponse;
8758
7836
  /**
@@ -8760,81 +7838,90 @@ export type CreateFeedErrors = {
8760
7838
  */
8761
7839
  401: ErrorResponse;
8762
7840
  /**
8763
- * Forbidden not a team member
7841
+ * Forbidden - state does not match team, the caller is not a team owner/admin, or the caller has no access to the submitted GitHub App installation on GitHub
8764
7842
  */
8765
7843
  403: ErrorResponse;
8766
7844
  /**
8767
- * A feed with that name already exists in this team
7845
+ * Conflict - this GitHub organization is already connected to another team, or the team has no GitHub App configured to complete the installation against
8768
7846
  */
8769
7847
  409: ErrorResponse;
7848
+ /**
7849
+ * Internal server error
7850
+ */
7851
+ 500: ErrorResponse;
7852
+ /**
7853
+ * GitHub App user authorization is not configured on this instance, so caller authority cannot be verified and the installation is not connected
7854
+ */
7855
+ 503: ErrorResponse;
8770
7856
  };
8771
- export type CreateFeedError = CreateFeedErrors[keyof CreateFeedErrors];
8772
- export type CreateFeedResponses = {
7857
+ export type HandleGitHubCallbackError = HandleGitHubCallbackErrors[keyof HandleGitHubCallbackErrors];
7858
+ export type HandleGitHubCallbackResponses = {
8773
7859
  /**
8774
- * Feed created successfully
7860
+ * GitHub App installation connected successfully
8775
7861
  */
8776
- 201: Feed;
7862
+ 201: GitHubCallbackResponse;
8777
7863
  };
8778
- export type CreateFeedResponse = CreateFeedResponses[keyof CreateFeedResponses];
8779
- export type DeleteFeedData = {
7864
+ export type HandleGitHubCallbackResponse = HandleGitHubCallbackResponses[keyof HandleGitHubCallbackResponses];
7865
+ export type ListGitHubRepositoriesData = {
8780
7866
  body?: never;
8781
7867
  path: {
8782
7868
  /**
8783
- * Team identifier
7869
+ * Team ID (UUID)
8784
7870
  */
8785
7871
  team_id: string;
7872
+ };
7873
+ query?: {
8786
7874
  /**
8787
- * Feed identifier
7875
+ * Page number for pagination (1-based)
8788
7876
  */
8789
- feed_id: string;
7877
+ page?: number;
8790
7878
  };
8791
- query?: never;
8792
- url: '/api/v1/{team_id}/feeds/{feed_id}';
7879
+ url: '/api/v1/{team_id}/integrations/github/repositories';
8793
7880
  };
8794
- export type DeleteFeedErrors = {
8795
- /**
8796
- * Invalid feed_id format
8797
- */
8798
- 400: ErrorResponse;
7881
+ export type ListGitHubRepositoriesErrors = {
8799
7882
  /**
8800
7883
  * Unauthorized
8801
7884
  */
8802
7885
  401: ErrorResponse;
8803
7886
  /**
8804
- * Forbidden not a team member
7887
+ * Forbidden - user does not have access to this team
8805
7888
  */
8806
7889
  403: ErrorResponse;
8807
7890
  /**
8808
- * Feed not found
7891
+ * GitHub App not installed for this team
8809
7892
  */
8810
7893
  404: ErrorResponse;
7894
+ /**
7895
+ * Internal server error
7896
+ */
7897
+ 500: ErrorResponse;
8811
7898
  };
8812
- export type DeleteFeedError = DeleteFeedErrors[keyof DeleteFeedErrors];
8813
- export type DeleteFeedResponses = {
7899
+ export type ListGitHubRepositoriesError = ListGitHubRepositoriesErrors[keyof ListGitHubRepositoriesErrors];
7900
+ export type ListGitHubRepositoriesResponses = {
8814
7901
  /**
8815
- * Feed deleted successfully
7902
+ * Repositories listed successfully
8816
7903
  */
8817
- 204: void;
7904
+ 200: GitHubRepositoriesResponse;
8818
7905
  };
8819
- export type DeleteFeedResponse = DeleteFeedResponses[keyof DeleteFeedResponses];
8820
- export type GetFeedData = {
7906
+ export type ListGitHubRepositoriesResponse = ListGitHubRepositoriesResponses[keyof ListGitHubRepositoriesResponses];
7907
+ export type ImportGitHubProjectData = {
8821
7908
  body?: never;
8822
7909
  path: {
8823
7910
  /**
8824
- * Team identifier
7911
+ * Team ID (UUID)
8825
7912
  */
8826
7913
  team_id: string;
8827
7914
  /**
8828
- * Feed identifier
7915
+ * GitHub repository ID
8829
7916
  */
8830
- feed_id: string;
7917
+ repo_id: number;
8831
7918
  };
8832
7919
  query?: never;
8833
- url: '/api/v1/{team_id}/feeds/{feed_id}';
7920
+ url: '/api/v1/{team_id}/integrations/github/repositories/{repo_id}/import-project';
8834
7921
  };
8835
- export type GetFeedErrors = {
7922
+ export type ImportGitHubProjectErrors = {
8836
7923
  /**
8837
- * Invalid feed_id format
7924
+ * Invalid repository ID
8838
7925
  */
8839
7926
  400: ErrorResponse;
8840
7927
  /**
@@ -8842,40 +7929,56 @@ export type GetFeedErrors = {
8842
7929
  */
8843
7930
  401: ErrorResponse;
8844
7931
  /**
8845
- * Forbidden not a team member
7932
+ * Forbidden - user does not have access to this team
8846
7933
  */
8847
7934
  403: ErrorResponse;
8848
7935
  /**
8849
- * Feed not found
7936
+ * GitHub App not installed for this team or repository not found
8850
7937
  */
8851
7938
  404: ErrorResponse;
7939
+ /**
7940
+ * Internal server error
7941
+ */
7942
+ 500: ErrorResponse;
8852
7943
  };
8853
- export type GetFeedError = GetFeedErrors[keyof GetFeedErrors];
8854
- export type GetFeedResponses = {
7944
+ export type ImportGitHubProjectError = ImportGitHubProjectErrors[keyof ImportGitHubProjectErrors];
7945
+ export type ImportGitHubProjectResponses = {
8855
7946
  /**
8856
- * Feed retrieved successfully
7947
+ * Project already exists — returned without creating a new one
8857
7948
  */
8858
- 200: Feed;
7949
+ 200: {
7950
+ project: Project;
7951
+ created: boolean;
7952
+ message?: string;
7953
+ };
7954
+ /**
7955
+ * Project created successfully from the GitHub repository
7956
+ */
7957
+ 201: {
7958
+ project: Project;
7959
+ created: boolean;
7960
+ };
8859
7961
  };
8860
- export type GetFeedResponse = GetFeedResponses[keyof GetFeedResponses];
8861
- export type UpdateFeedData = {
8862
- body: UpdateFeedRequest;
8863
- path: {
7962
+ export type ImportGitHubProjectResponse = ImportGitHubProjectResponses[keyof ImportGitHubProjectResponses];
7963
+ export type ImportGitHubBlueprintsData = {
7964
+ body: {
8864
7965
  /**
8865
- * Team identifier
7966
+ * GitHub repository ID to import blueprints from
8866
7967
  */
8867
- team_id: string;
7968
+ repository_id: number;
7969
+ };
7970
+ path: {
8868
7971
  /**
8869
- * Feed identifier
7972
+ * Team ID (UUID)
8870
7973
  */
8871
- feed_id: string;
7974
+ team_id: string;
8872
7975
  };
8873
7976
  query?: never;
8874
- url: '/api/v1/{team_id}/feeds/{feed_id}';
7977
+ url: '/api/v1/{team_id}/integrations/github/import-blueprints';
8875
7978
  };
8876
- export type UpdateFeedErrors = {
7979
+ export type ImportGitHubBlueprintsErrors = {
8877
7980
  /**
8878
- * Invalid request data or validation error
7981
+ * Invalid request body or missing repository_id
8879
7982
  */
8880
7983
  400: ErrorResponse;
8881
7984
  /**
@@ -8883,126 +7986,123 @@ export type UpdateFeedErrors = {
8883
7986
  */
8884
7987
  401: ErrorResponse;
8885
7988
  /**
8886
- * Forbidden not a team member
7989
+ * Forbidden - user does not have access to this team
8887
7990
  */
8888
7991
  403: ErrorResponse;
8889
7992
  /**
8890
- * Feed not found
7993
+ * GitHub App not installed for this team or repository not found
8891
7994
  */
8892
7995
  404: ErrorResponse;
8893
7996
  /**
8894
- * A feed with that name already exists in this team
7997
+ * Precondition Failed - no project exists for this repository; import the repository as a project first
8895
7998
  */
8896
- 409: ErrorResponse;
7999
+ 412: ErrorResponse;
8000
+ /**
8001
+ * Internal server error
8002
+ */
8003
+ 500: ErrorResponse;
8897
8004
  };
8898
- export type UpdateFeedError = UpdateFeedErrors[keyof UpdateFeedErrors];
8899
- export type UpdateFeedResponses = {
8005
+ export type ImportGitHubBlueprintsError = ImportGitHubBlueprintsErrors[keyof ImportGitHubBlueprintsErrors];
8006
+ export type ImportGitHubBlueprintsResponses = {
8900
8007
  /**
8901
- * Feed updated successfully
8008
+ * Import completed — check the report for per-file results
8902
8009
  */
8903
- 200: Feed;
8010
+ 200: BlueprintImportReport;
8904
8011
  };
8905
- export type UpdateFeedResponse = UpdateFeedResponses[keyof UpdateFeedResponses];
8906
- export type ListFeedItemsByFeedData = {
8012
+ export type ImportGitHubBlueprintsResponse = ImportGitHubBlueprintsResponses[keyof ImportGitHubBlueprintsResponses];
8013
+ export type DisconnectGitHubData = {
8907
8014
  body?: never;
8908
8015
  path: {
8909
8016
  /**
8910
- * Team identifier
8017
+ * Team ID (UUID)
8911
8018
  */
8912
8019
  team_id: string;
8913
- /**
8914
- * Feed identifier
8915
- */
8916
- feed_id: string;
8917
- };
8918
- query?: {
8919
- /**
8920
- * Filter by project ID
8921
- */
8922
- project_id?: string;
8923
- /**
8924
- * Filter by AI assistant name
8925
- */
8926
- ai_assistant_name?: string;
8927
- /**
8928
- * Search in feed item title and content (case-insensitive substring)
8929
- */
8930
- search?: string;
8931
- /**
8932
- * Filter by archived status: 'true' (archived only), 'false' (active only, default), 'all'
8933
- */
8934
- archived?: 'true' | 'false' | 'all';
8935
- /**
8936
- * Page number (default 1)
8937
- */
8938
- page?: number;
8939
- /**
8940
- * Items per page (default 20, max 100)
8941
- */
8942
- limit?: number;
8943
8020
  };
8944
- url: '/api/v1/{team_id}/feeds/{feed_id}/items';
8021
+ query?: never;
8022
+ url: '/api/v1/{team_id}/integrations/github/disconnect';
8023
+ };
8024
+ export type DisconnectGitHubErrors = {
8025
+ /**
8026
+ * Unauthorized
8027
+ */
8028
+ 401: ErrorResponse;
8029
+ /**
8030
+ * Forbidden - user does not have access to this team
8031
+ */
8032
+ 403: ErrorResponse;
8033
+ /**
8034
+ * Internal server error
8035
+ */
8036
+ 500: ErrorResponse;
8945
8037
  };
8946
- export type ListFeedItemsByFeedErrors = {
8038
+ export type DisconnectGitHubError = DisconnectGitHubErrors[keyof DisconnectGitHubErrors];
8039
+ export type DisconnectGitHubResponses = {
8947
8040
  /**
8948
- * Invalid feed_id format
8041
+ * GitHub installation disconnected successfully
8949
8042
  */
8950
- 400: ErrorResponse;
8043
+ 204: void;
8044
+ };
8045
+ export type DisconnectGitHubResponse = DisconnectGitHubResponses[keyof DisconnectGitHubResponses];
8046
+ export type HandleGitHubWebhookData = {
8951
8047
  /**
8952
- * Unauthorized
8048
+ * GitHub webhook event payload (varies by event type)
8953
8049
  */
8954
- 401: ErrorResponse;
8050
+ body: {
8051
+ [key: string]: unknown;
8052
+ };
8053
+ path?: never;
8054
+ query?: never;
8055
+ url: '/api/v1/webhooks/github';
8056
+ };
8057
+ export type HandleGitHubWebhookErrors = {
8955
8058
  /**
8956
- * Forbidden not a team member
8059
+ * Endpoint retired; use the team's per-App webhook URL
8957
8060
  */
8958
- 403: ErrorResponse;
8061
+ 410: ErrorResponse;
8959
8062
  };
8960
- export type ListFeedItemsByFeedError = ListFeedItemsByFeedErrors[keyof ListFeedItemsByFeedErrors];
8961
- export type ListFeedItemsByFeedResponses = {
8063
+ export type HandleGitHubWebhookError = HandleGitHubWebhookErrors[keyof HandleGitHubWebhookErrors];
8064
+ export type HandleGitHubWebhookByTokenData = {
8962
8065
  /**
8963
- * Feed items retrieved successfully
8066
+ * GitHub webhook event payload (varies by event type)
8964
8067
  */
8965
- 200: FeedItemListResponse;
8966
- };
8967
- export type ListFeedItemsByFeedResponse = ListFeedItemsByFeedResponses[keyof ListFeedItemsByFeedResponses];
8968
- export type CreateFeedItemData = {
8969
- body: CreateFeedItemRequest;
8068
+ body: {
8069
+ [key: string]: unknown;
8070
+ };
8970
8071
  path: {
8971
8072
  /**
8972
- * Team identifier
8973
- */
8974
- team_id: string;
8975
- /**
8976
- * Feed identifier
8073
+ * Opaque routing token identifying which team's GitHub App this delivery belongs to. Minted as unpadded URL-safe base64, so it needs no percent-encoding. Treat it as a secret: it selects the secret the signature is verified against, and it is redacted from access logs.
8977
8074
  */
8978
- feed_id: string;
8075
+ token: string;
8979
8076
  };
8980
8077
  query?: never;
8981
- url: '/api/v1/{team_id}/feeds/{feed_id}/items';
8078
+ url: '/api/v1/webhooks/github/{token}';
8982
8079
  };
8983
- export type CreateFeedItemErrors = {
8080
+ export type HandleGitHubWebhookByTokenErrors = {
8984
8081
  /**
8985
- * Invalid request data or validation error
8082
+ * Unreadable body, unparseable payload, or missing installation reference
8986
8083
  */
8987
8084
  400: ErrorResponse;
8988
8085
  /**
8989
- * Unauthorized
8086
+ * Missing or invalid `X-Hub-Signature-256`
8990
8087
  */
8991
8088
  401: ErrorResponse;
8992
8089
  /**
8993
- * Forbidden — not a team member or project belongs to a different team
8090
+ * Unknown or malformed routing token (deliberately indistinguishable)
8994
8091
  */
8995
- 403: ErrorResponse;
8092
+ 404: ErrorResponse;
8093
+ /**
8094
+ * Internal server error
8095
+ */
8096
+ 500: ErrorResponse;
8996
8097
  };
8997
- export type CreateFeedItemError = CreateFeedItemErrors[keyof CreateFeedItemErrors];
8998
- export type CreateFeedItemResponses = {
8098
+ export type HandleGitHubWebhookByTokenError = HandleGitHubWebhookByTokenErrors[keyof HandleGitHubWebhookByTokenErrors];
8099
+ export type HandleGitHubWebhookByTokenResponses = {
8999
8100
  /**
9000
- * Feed item created successfully
8101
+ * Delivery accepted (or already processed — dedup by delivery id)
9001
8102
  */
9002
- 201: FeedItem;
8103
+ 200: unknown;
9003
8104
  };
9004
- export type CreateFeedItemResponse = CreateFeedItemResponses[keyof CreateFeedItemResponses];
9005
- export type ListFeedItemsData = {
8105
+ export type ListFeedsData = {
9006
8106
  body?: never;
9007
8107
  path: {
9008
8108
  /**
@@ -9012,25 +8112,9 @@ export type ListFeedItemsData = {
9012
8112
  };
9013
8113
  query?: {
9014
8114
  /**
9015
- * Filter by feed ID
9016
- */
9017
- feed_id?: string;
9018
- /**
9019
- * Filter by project ID
9020
- */
9021
- project_id?: string;
9022
- /**
9023
- * Filter by AI assistant name
9024
- */
9025
- ai_assistant_name?: string;
9026
- /**
9027
- * Search in feed item title and content (case-insensitive substring)
8115
+ * Search in feed name and description
9028
8116
  */
9029
8117
  search?: string;
9030
- /**
9031
- * Filter by archived status: 'true' (archived only), 'false' (active only, default), 'all'
9032
- */
9033
- archived?: 'true' | 'false' | 'all';
9034
8118
  /**
9035
8119
  * Page number (default 1)
9036
8120
  */
@@ -9040,9 +8124,9 @@ export type ListFeedItemsData = {
9040
8124
  */
9041
8125
  limit?: number;
9042
8126
  };
9043
- url: '/api/v1/{team_id}/feed-items';
8127
+ url: '/api/v1/{team_id}/feeds';
9044
8128
  };
9045
- export type ListFeedItemsErrors = {
8129
+ export type ListFeedsErrors = {
9046
8130
  /**
9047
8131
  * Unauthorized
9048
8132
  */
@@ -9052,32 +8136,28 @@ export type ListFeedItemsErrors = {
9052
8136
  */
9053
8137
  403: ErrorResponse;
9054
8138
  };
9055
- export type ListFeedItemsError = ListFeedItemsErrors[keyof ListFeedItemsErrors];
9056
- export type ListFeedItemsResponses = {
8139
+ export type ListFeedsError = ListFeedsErrors[keyof ListFeedsErrors];
8140
+ export type ListFeedsResponses = {
9057
8141
  /**
9058
- * Feed items retrieved successfully
8142
+ * Feeds retrieved successfully
9059
8143
  */
9060
- 200: FeedItemListResponse;
8144
+ 200: FeedListResponse;
9061
8145
  };
9062
- export type ListFeedItemsResponse = ListFeedItemsResponses[keyof ListFeedItemsResponses];
9063
- export type DeleteFeedItemData = {
9064
- body?: never;
8146
+ export type ListFeedsResponse = ListFeedsResponses[keyof ListFeedsResponses];
8147
+ export type CreateFeedData = {
8148
+ body: CreateFeedRequest;
9065
8149
  path: {
9066
8150
  /**
9067
8151
  * Team identifier
9068
8152
  */
9069
8153
  team_id: string;
9070
- /**
9071
- * Feed item identifier
9072
- */
9073
- item_id: string;
9074
8154
  };
9075
8155
  query?: never;
9076
- url: '/api/v1/{team_id}/feed-items/{item_id}';
8156
+ url: '/api/v1/{team_id}/feeds';
9077
8157
  };
9078
- export type DeleteFeedItemErrors = {
8158
+ export type CreateFeedErrors = {
9079
8159
  /**
9080
- * Invalid item_id format
8160
+ * Invalid request data or validation error
9081
8161
  */
9082
8162
  400: ErrorResponse;
9083
8163
  /**
@@ -9085,23 +8165,23 @@ export type DeleteFeedItemErrors = {
9085
8165
  */
9086
8166
  401: ErrorResponse;
9087
8167
  /**
9088
- * Forbidden — caller is not a team member, or is not the item's poster, owner, or admin
8168
+ * Forbidden — not a team member
9089
8169
  */
9090
8170
  403: ErrorResponse;
9091
8171
  /**
9092
- * Feed item not found
8172
+ * A feed with that name already exists in this team
9093
8173
  */
9094
- 404: ErrorResponse;
8174
+ 409: ErrorResponse;
9095
8175
  };
9096
- export type DeleteFeedItemError = DeleteFeedItemErrors[keyof DeleteFeedItemErrors];
9097
- export type DeleteFeedItemResponses = {
8176
+ export type CreateFeedError = CreateFeedErrors[keyof CreateFeedErrors];
8177
+ export type CreateFeedResponses = {
9098
8178
  /**
9099
- * Feed item deleted successfully
8179
+ * Feed created successfully
9100
8180
  */
9101
- 204: void;
8181
+ 201: Feed;
9102
8182
  };
9103
- export type DeleteFeedItemResponse = DeleteFeedItemResponses[keyof DeleteFeedItemResponses];
9104
- export type GetFeedItemData = {
8183
+ export type CreateFeedResponse = CreateFeedResponses[keyof CreateFeedResponses];
8184
+ export type DeleteFeedData = {
9105
8185
  body?: never;
9106
8186
  path: {
9107
8187
  /**
@@ -9109,16 +8189,16 @@ export type GetFeedItemData = {
9109
8189
  */
9110
8190
  team_id: string;
9111
8191
  /**
9112
- * Feed item identifier
8192
+ * Feed identifier
9113
8193
  */
9114
- item_id: string;
8194
+ feed_id: string;
9115
8195
  };
9116
8196
  query?: never;
9117
- url: '/api/v1/{team_id}/feed-items/{item_id}';
8197
+ url: '/api/v1/{team_id}/feeds/{feed_id}';
9118
8198
  };
9119
- export type GetFeedItemErrors = {
8199
+ export type DeleteFeedErrors = {
9120
8200
  /**
9121
- * Invalid item_id format, or team_id is not a valid UUID
8201
+ * Invalid feed_id format
9122
8202
  */
9123
8203
  400: ErrorResponse;
9124
8204
  /**
@@ -9130,19 +8210,19 @@ export type GetFeedItemErrors = {
9130
8210
  */
9131
8211
  403: ErrorResponse;
9132
8212
  /**
9133
- * Feed item not found
8213
+ * Feed not found
9134
8214
  */
9135
8215
  404: ErrorResponse;
9136
8216
  };
9137
- export type GetFeedItemError = GetFeedItemErrors[keyof GetFeedItemErrors];
9138
- export type GetFeedItemResponses = {
8217
+ export type DeleteFeedError = DeleteFeedErrors[keyof DeleteFeedErrors];
8218
+ export type DeleteFeedResponses = {
9139
8219
  /**
9140
- * Feed item retrieved successfully
8220
+ * Feed deleted successfully
9141
8221
  */
9142
- 200: FeedItem;
8222
+ 204: void;
9143
8223
  };
9144
- export type GetFeedItemResponse = GetFeedItemResponses[keyof GetFeedItemResponses];
9145
- export type ArchiveFeedItemData = {
8224
+ export type DeleteFeedResponse = DeleteFeedResponses[keyof DeleteFeedResponses];
8225
+ export type GetFeedData = {
9146
8226
  body?: never;
9147
8227
  path: {
9148
8228
  /**
@@ -9150,16 +8230,16 @@ export type ArchiveFeedItemData = {
9150
8230
  */
9151
8231
  team_id: string;
9152
8232
  /**
9153
- * Feed item identifier
8233
+ * Feed identifier
9154
8234
  */
9155
- item_id: string;
8235
+ feed_id: string;
9156
8236
  };
9157
8237
  query?: never;
9158
- url: '/api/v1/{team_id}/feed-items/{item_id}/archive';
8238
+ url: '/api/v1/{team_id}/feeds/{feed_id}';
9159
8239
  };
9160
- export type ArchiveFeedItemErrors = {
8240
+ export type GetFeedErrors = {
9161
8241
  /**
9162
- * Invalid item_id format
8242
+ * Invalid feed_id format
9163
8243
  */
9164
8244
  400: ErrorResponse;
9165
8245
  /**
@@ -9171,36 +8251,36 @@ export type ArchiveFeedItemErrors = {
9171
8251
  */
9172
8252
  403: ErrorResponse;
9173
8253
  /**
9174
- * Feed item not found
8254
+ * Feed not found
9175
8255
  */
9176
8256
  404: ErrorResponse;
9177
8257
  };
9178
- export type ArchiveFeedItemError = ArchiveFeedItemErrors[keyof ArchiveFeedItemErrors];
9179
- export type ArchiveFeedItemResponses = {
8258
+ export type GetFeedError = GetFeedErrors[keyof GetFeedErrors];
8259
+ export type GetFeedResponses = {
9180
8260
  /**
9181
- * Feed item archived successfully
8261
+ * Feed retrieved successfully
9182
8262
  */
9183
- 204: void;
8263
+ 200: Feed;
9184
8264
  };
9185
- export type ArchiveFeedItemResponse = ArchiveFeedItemResponses[keyof ArchiveFeedItemResponses];
9186
- export type UnarchiveFeedItemData = {
9187
- body?: never;
8265
+ export type GetFeedResponse = GetFeedResponses[keyof GetFeedResponses];
8266
+ export type UpdateFeedData = {
8267
+ body: UpdateFeedRequest;
9188
8268
  path: {
9189
8269
  /**
9190
8270
  * Team identifier
9191
8271
  */
9192
8272
  team_id: string;
9193
8273
  /**
9194
- * Feed item identifier
8274
+ * Feed identifier
9195
8275
  */
9196
- item_id: string;
8276
+ feed_id: string;
9197
8277
  };
9198
8278
  query?: never;
9199
- url: '/api/v1/{team_id}/feed-items/{item_id}/unarchive';
8279
+ url: '/api/v1/{team_id}/feeds/{feed_id}';
9200
8280
  };
9201
- export type UnarchiveFeedItemErrors = {
8281
+ export type UpdateFeedErrors = {
9202
8282
  /**
9203
- * Invalid item_id format
8283
+ * Invalid request data or validation error
9204
8284
  */
9205
8285
  400: ErrorResponse;
9206
8286
  /**
@@ -9212,139 +8292,102 @@ export type UnarchiveFeedItemErrors = {
9212
8292
  */
9213
8293
  403: ErrorResponse;
9214
8294
  /**
9215
- * Feed item not found
9216
- */
9217
- 404: ErrorResponse;
9218
- };
9219
- export type UnarchiveFeedItemError = UnarchiveFeedItemErrors[keyof UnarchiveFeedItemErrors];
9220
- export type UnarchiveFeedItemResponses = {
9221
- /**
9222
- * Feed item unarchived successfully
9223
- */
9224
- 204: void;
9225
- };
9226
- export type UnarchiveFeedItemResponse = UnarchiveFeedItemResponses[keyof UnarchiveFeedItemResponses];
9227
- export type GetInvitationByTokenData = {
9228
- body?: never;
9229
- path: {
9230
- /**
9231
- * Opaque invitation token from the invitation email link
9232
- */
9233
- token: string;
9234
- };
9235
- query?: never;
9236
- url: '/api/v1/invitations/{token}';
9237
- };
9238
- export type GetInvitationByTokenErrors = {
9239
- /**
9240
- * Authentication required
9241
- */
9242
- 401: ErrorResponse;
9243
- /**
9244
- * Invitation not found for the given token
8295
+ * Feed not found
9245
8296
  */
9246
8297
  404: ErrorResponse;
9247
8298
  /**
9248
- * Invitation has already been accepted, rejected, or revoked
8299
+ * A feed with that name already exists in this team
9249
8300
  */
9250
8301
  409: ErrorResponse;
9251
- /**
9252
- * Invitation has expired
9253
- */
9254
- 410: ErrorResponse;
9255
- /**
9256
- * Internal server error
9257
- */
9258
- 500: ErrorResponse;
9259
8302
  };
9260
- export type GetInvitationByTokenError = GetInvitationByTokenErrors[keyof GetInvitationByTokenErrors];
9261
- export type GetInvitationByTokenResponses = {
8303
+ export type UpdateFeedError = UpdateFeedErrors[keyof UpdateFeedErrors];
8304
+ export type UpdateFeedResponses = {
9262
8305
  /**
9263
- * Invitation details retrieved successfully
8306
+ * Feed updated successfully
9264
8307
  */
9265
- 200: InvitationDetailsResponse;
8308
+ 200: Feed;
9266
8309
  };
9267
- export type GetInvitationByTokenResponse = GetInvitationByTokenResponses[keyof GetInvitationByTokenResponses];
9268
- export type ListAgentsData = {
8310
+ export type UpdateFeedResponse = UpdateFeedResponses[keyof UpdateFeedResponses];
8311
+ export type ListFeedItemsByFeedData = {
9269
8312
  body?: never;
9270
8313
  path: {
9271
8314
  /**
9272
8315
  * Team identifier
9273
8316
  */
9274
- team_id: string;
8317
+ team_id: string;
8318
+ /**
8319
+ * Feed identifier
8320
+ */
8321
+ feed_id: string;
9275
8322
  };
9276
8323
  query?: {
9277
8324
  /**
9278
- * Filter by agent status
8325
+ * Filter by project ID
9279
8326
  */
9280
- status?: 'active' | 'paused' | 'error';
8327
+ project_id?: string;
9281
8328
  /**
9282
- * Search in agent name and description
8329
+ * Filter by AI assistant name
9283
8330
  */
9284
- search?: string;
8331
+ ai_assistant_name?: string;
9285
8332
  /**
9286
- * Sort field
8333
+ * Search in feed item title and content (case-insensitive substring)
9287
8334
  */
9288
- sort_by?: 'name' | 'status' | 'updated_at' | 'created_at' | 'last_run' | 'success_rate';
8335
+ search?: string;
9289
8336
  /**
9290
- * Sort order
8337
+ * Filter by archived status: 'true' (archived only), 'false' (active only, default), 'all'
9291
8338
  */
9292
- sort_order?: 'asc' | 'desc';
8339
+ archived?: 'true' | 'false' | 'all';
9293
8340
  /**
9294
- * Page number
8341
+ * Page number (default 1)
9295
8342
  */
9296
8343
  page?: number;
9297
8344
  /**
9298
- * Items per page
8345
+ * Items per page (default 20, max 100)
9299
8346
  */
9300
8347
  limit?: number;
9301
8348
  };
9302
- url: '/api/v1/{team_id}/agents';
8349
+ url: '/api/v1/{team_id}/feeds/{feed_id}/items';
9303
8350
  };
9304
- export type ListAgentsErrors = {
8351
+ export type ListFeedItemsByFeedErrors = {
9305
8352
  /**
9306
- * Invalid sort_by value or invalid team_id
8353
+ * Invalid feed_id format
9307
8354
  */
9308
8355
  400: ErrorResponse;
9309
8356
  /**
9310
8357
  * Unauthorized
9311
8358
  */
9312
8359
  401: ErrorResponse;
9313
- /**
9314
- * Payment required — active subscription required
9315
- */
9316
- 402: ErrorResponse;
9317
8360
  /**
9318
8361
  * Forbidden — not a team member
9319
8362
  */
9320
8363
  403: ErrorResponse;
9321
- /**
9322
- * Internal server error
9323
- */
9324
- 500: ErrorResponse;
9325
8364
  };
9326
- export type ListAgentsError = ListAgentsErrors[keyof ListAgentsErrors];
9327
- export type ListAgentsResponses = {
8365
+ export type ListFeedItemsByFeedError = ListFeedItemsByFeedErrors[keyof ListFeedItemsByFeedErrors];
8366
+ export type ListFeedItemsByFeedResponses = {
9328
8367
  /**
9329
- * Agents retrieved successfully
8368
+ * Feed items retrieved successfully
9330
8369
  */
9331
- 200: AgentListResponse;
8370
+ 200: FeedItemListResponse;
9332
8371
  };
9333
- export type ListAgentsResponse = ListAgentsResponses[keyof ListAgentsResponses];
9334
- export type CreateAgentData = {
9335
- body: CreateAgentRequest;
8372
+ export type ListFeedItemsByFeedResponse = ListFeedItemsByFeedResponses[keyof ListFeedItemsByFeedResponses];
8373
+ export type CreateFeedItemData = {
8374
+ body: CreateFeedItemRequest;
9336
8375
  path: {
9337
8376
  /**
9338
8377
  * Team identifier
9339
8378
  */
9340
8379
  team_id: string;
8380
+ /**
8381
+ * Feed identifier
8382
+ */
8383
+ feed_id: string;
9341
8384
  };
9342
8385
  query?: never;
9343
- url: '/api/v1/{team_id}/agents';
8386
+ url: '/api/v1/{team_id}/feeds/{feed_id}/items';
9344
8387
  };
9345
- export type CreateAgentErrors = {
8388
+ export type CreateFeedItemErrors = {
9346
8389
  /**
9347
- * Invalid request body, validation error, or invalid/unfetchable agent card (4xx from the card host)
8390
+ * Invalid request data or validation error
9348
8391
  */
9349
8392
  400: ErrorResponse;
9350
8393
  /**
@@ -9352,48 +8395,94 @@ export type CreateAgentErrors = {
9352
8395
  */
9353
8396
  401: ErrorResponse;
9354
8397
  /**
9355
- * Payment required active subscription required
9356
- */
9357
- 402: ErrorResponse;
9358
- /**
9359
- * Forbidden — not a team member, or agent limit reached for the subscription plan
8398
+ * Forbiddennot a team member or project belongs to a different team
9360
8399
  */
9361
8400
  403: ErrorResponse;
8401
+ };
8402
+ export type CreateFeedItemError = CreateFeedItemErrors[keyof CreateFeedItemErrors];
8403
+ export type CreateFeedItemResponses = {
9362
8404
  /**
9363
- * An agent with that name already exists for this user
8405
+ * Feed item created successfully
9364
8406
  */
9365
- 409: ErrorResponse;
8407
+ 201: FeedItem;
8408
+ };
8409
+ export type CreateFeedItemResponse = CreateFeedItemResponses[keyof CreateFeedItemResponses];
8410
+ export type ListFeedItemsData = {
8411
+ body?: never;
8412
+ path: {
8413
+ /**
8414
+ * Team identifier
8415
+ */
8416
+ team_id: string;
8417
+ };
8418
+ query?: {
8419
+ /**
8420
+ * Filter by feed ID
8421
+ */
8422
+ feed_id?: string;
8423
+ /**
8424
+ * Filter by project ID
8425
+ */
8426
+ project_id?: string;
8427
+ /**
8428
+ * Filter by AI assistant name
8429
+ */
8430
+ ai_assistant_name?: string;
8431
+ /**
8432
+ * Search in feed item title and content (case-insensitive substring)
8433
+ */
8434
+ search?: string;
8435
+ /**
8436
+ * Filter by archived status: 'true' (archived only), 'false' (active only, default), 'all'
8437
+ */
8438
+ archived?: 'true' | 'false' | 'all';
8439
+ /**
8440
+ * Page number (default 1)
8441
+ */
8442
+ page?: number;
8443
+ /**
8444
+ * Items per page (default 20, max 100)
8445
+ */
8446
+ limit?: number;
8447
+ };
8448
+ url: '/api/v1/{team_id}/feed-items';
8449
+ };
8450
+ export type ListFeedItemsErrors = {
9366
8451
  /**
9367
- * Internal server error
8452
+ * Unauthorized
9368
8453
  */
9369
- 500: ErrorResponse;
8454
+ 401: ErrorResponse;
9370
8455
  /**
9371
- * Agent card host unreachable or returned a server error
8456
+ * Forbidden not a team member
9372
8457
  */
9373
- 502: ErrorResponse;
8458
+ 403: ErrorResponse;
9374
8459
  };
9375
- export type CreateAgentError = CreateAgentErrors[keyof CreateAgentErrors];
9376
- export type CreateAgentResponses = {
8460
+ export type ListFeedItemsError = ListFeedItemsErrors[keyof ListFeedItemsErrors];
8461
+ export type ListFeedItemsResponses = {
9377
8462
  /**
9378
- * Agent created successfully
8463
+ * Feed items retrieved successfully
9379
8464
  */
9380
- 201: Agent;
8465
+ 200: FeedItemListResponse;
9381
8466
  };
9382
- export type CreateAgentResponse = CreateAgentResponses[keyof CreateAgentResponses];
9383
- export type PreviewAgentCardData = {
9384
- body: PreviewAgentCardRequest;
8467
+ export type ListFeedItemsResponse = ListFeedItemsResponses[keyof ListFeedItemsResponses];
8468
+ export type DeleteFeedItemData = {
8469
+ body?: never;
9385
8470
  path: {
9386
8471
  /**
9387
8472
  * Team identifier
9388
8473
  */
9389
8474
  team_id: string;
8475
+ /**
8476
+ * Feed item identifier
8477
+ */
8478
+ item_id: string;
9390
8479
  };
9391
8480
  query?: never;
9392
- url: '/api/v1/{team_id}/agents/preview-card';
8481
+ url: '/api/v1/{team_id}/feed-items/{item_id}';
9393
8482
  };
9394
- export type PreviewAgentCardErrors = {
8483
+ export type DeleteFeedItemErrors = {
9395
8484
  /**
9396
- * Invalid request body, missing card_url, or invalid/unfetchable agent card (4xx from the card host)
8485
+ * Invalid item_id format
9397
8486
  */
9398
8487
  400: ErrorResponse;
9399
8488
  /**
@@ -9401,68 +8490,64 @@ export type PreviewAgentCardErrors = {
9401
8490
  */
9402
8491
  401: ErrorResponse;
9403
8492
  /**
9404
- * Payment required active subscription required
9405
- */
9406
- 402: ErrorResponse;
9407
- /**
9408
- * Forbidden — not a team member
8493
+ * Forbiddencaller is not a team member, or is not the item's poster, owner, or admin
9409
8494
  */
9410
8495
  403: ErrorResponse;
9411
8496
  /**
9412
- * Agent card host unreachable or returned a server error
8497
+ * Feed item not found
9413
8498
  */
9414
- 502: ErrorResponse;
8499
+ 404: ErrorResponse;
9415
8500
  };
9416
- export type PreviewAgentCardError = PreviewAgentCardErrors[keyof PreviewAgentCardErrors];
9417
- export type PreviewAgentCardResponses = {
8501
+ export type DeleteFeedItemError = DeleteFeedItemErrors[keyof DeleteFeedItemErrors];
8502
+ export type DeleteFeedItemResponses = {
9418
8503
  /**
9419
- * Agent card fetched successfully
8504
+ * Feed item deleted successfully
9420
8505
  */
9421
- 200: AgentCard;
8506
+ 204: void;
9422
8507
  };
9423
- export type PreviewAgentCardResponse = PreviewAgentCardResponses[keyof PreviewAgentCardResponses];
9424
- export type GetAgentStatsData = {
8508
+ export type DeleteFeedItemResponse = DeleteFeedItemResponses[keyof DeleteFeedItemResponses];
8509
+ export type GetFeedItemData = {
9425
8510
  body?: never;
9426
8511
  path: {
9427
8512
  /**
9428
8513
  * Team identifier
9429
8514
  */
9430
8515
  team_id: string;
8516
+ /**
8517
+ * Feed item identifier
8518
+ */
8519
+ item_id: string;
9431
8520
  };
9432
8521
  query?: never;
9433
- url: '/api/v1/{team_id}/agents/stats';
8522
+ url: '/api/v1/{team_id}/feed-items/{item_id}';
9434
8523
  };
9435
- export type GetAgentStatsErrors = {
8524
+ export type GetFeedItemErrors = {
9436
8525
  /**
9437
- * Invalid team_id
8526
+ * Invalid item_id format, or team_id is not a valid UUID
9438
8527
  */
9439
8528
  400: ErrorResponse;
9440
8529
  /**
9441
8530
  * Unauthorized
9442
8531
  */
9443
8532
  401: ErrorResponse;
9444
- /**
9445
- * Payment required — active subscription required
9446
- */
9447
- 402: ErrorResponse;
9448
8533
  /**
9449
8534
  * Forbidden — not a team member
9450
8535
  */
9451
8536
  403: ErrorResponse;
9452
8537
  /**
9453
- * Internal server error
8538
+ * Feed item not found
9454
8539
  */
9455
- 500: ErrorResponse;
8540
+ 404: ErrorResponse;
9456
8541
  };
9457
- export type GetAgentStatsError = GetAgentStatsErrors[keyof GetAgentStatsErrors];
9458
- export type GetAgentStatsResponses = {
8542
+ export type GetFeedItemError = GetFeedItemErrors[keyof GetFeedItemErrors];
8543
+ export type GetFeedItemResponses = {
9459
8544
  /**
9460
- * Agent statistics retrieved successfully
8545
+ * Feed item retrieved successfully
9461
8546
  */
9462
- 200: AgentStatsResponse;
8547
+ 200: FeedItem;
9463
8548
  };
9464
- export type GetAgentStatsResponse = GetAgentStatsResponses[keyof GetAgentStatsResponses];
9465
- export type DeleteAgentData = {
8549
+ export type GetFeedItemResponse = GetFeedItemResponses[keyof GetFeedItemResponses];
8550
+ export type ArchiveFeedItemData = {
9466
8551
  body?: never;
9467
8552
  path: {
9468
8553
  /**
@@ -9470,48 +8555,40 @@ export type DeleteAgentData = {
9470
8555
  */
9471
8556
  team_id: string;
9472
8557
  /**
9473
- * Agent identifier
8558
+ * Feed item identifier
9474
8559
  */
9475
- id: string;
8560
+ item_id: string;
9476
8561
  };
9477
8562
  query?: never;
9478
- url: '/api/v1/{team_id}/agents/{id}';
8563
+ url: '/api/v1/{team_id}/feed-items/{item_id}/archive';
9479
8564
  };
9480
- export type DeleteAgentErrors = {
8565
+ export type ArchiveFeedItemErrors = {
9481
8566
  /**
9482
- * Invalid team_id
8567
+ * Invalid item_id format
9483
8568
  */
9484
8569
  400: ErrorResponse;
9485
8570
  /**
9486
8571
  * Unauthorized
9487
8572
  */
9488
8573
  401: ErrorResponse;
9489
- /**
9490
- * Payment required — active subscription required
9491
- */
9492
- 402: ErrorResponse;
9493
8574
  /**
9494
8575
  * Forbidden — not a team member
9495
8576
  */
9496
8577
  403: ErrorResponse;
9497
8578
  /**
9498
- * Agent not found
8579
+ * Feed item not found
9499
8580
  */
9500
8581
  404: ErrorResponse;
9501
- /**
9502
- * Internal server error
9503
- */
9504
- 500: ErrorResponse;
9505
8582
  };
9506
- export type DeleteAgentError = DeleteAgentErrors[keyof DeleteAgentErrors];
9507
- export type DeleteAgentResponses = {
8583
+ export type ArchiveFeedItemError = ArchiveFeedItemErrors[keyof ArchiveFeedItemErrors];
8584
+ export type ArchiveFeedItemResponses = {
9508
8585
  /**
9509
- * Agent deleted successfully
8586
+ * Feed item archived successfully
9510
8587
  */
9511
8588
  204: void;
9512
8589
  };
9513
- export type DeleteAgentResponse = DeleteAgentResponses[keyof DeleteAgentResponses];
9514
- export type GetAgentData = {
8590
+ export type ArchiveFeedItemResponse = ArchiveFeedItemResponses[keyof ArchiveFeedItemResponses];
8591
+ export type UnarchiveFeedItemData = {
9515
8592
  body?: never;
9516
8593
  path: {
9517
8594
  /**
@@ -9519,118 +8596,119 @@ export type GetAgentData = {
9519
8596
  */
9520
8597
  team_id: string;
9521
8598
  /**
9522
- * Agent identifier
8599
+ * Feed item identifier
9523
8600
  */
9524
- id: string;
8601
+ item_id: string;
9525
8602
  };
9526
8603
  query?: never;
9527
- url: '/api/v1/{team_id}/agents/{id}';
8604
+ url: '/api/v1/{team_id}/feed-items/{item_id}/unarchive';
9528
8605
  };
9529
- export type GetAgentErrors = {
8606
+ export type UnarchiveFeedItemErrors = {
9530
8607
  /**
9531
- * Invalid team_id
8608
+ * Invalid item_id format
9532
8609
  */
9533
8610
  400: ErrorResponse;
9534
8611
  /**
9535
8612
  * Unauthorized
9536
8613
  */
9537
8614
  401: ErrorResponse;
9538
- /**
9539
- * Payment required — active subscription required
9540
- */
9541
- 402: ErrorResponse;
9542
8615
  /**
9543
8616
  * Forbidden — not a team member
9544
8617
  */
9545
8618
  403: ErrorResponse;
9546
8619
  /**
9547
- * Agent not found
8620
+ * Feed item not found
9548
8621
  */
9549
8622
  404: ErrorResponse;
9550
- /**
9551
- * Internal server error
9552
- */
9553
- 500: ErrorResponse;
9554
8623
  };
9555
- export type GetAgentError = GetAgentErrors[keyof GetAgentErrors];
9556
- export type GetAgentResponses = {
8624
+ export type UnarchiveFeedItemError = UnarchiveFeedItemErrors[keyof UnarchiveFeedItemErrors];
8625
+ export type UnarchiveFeedItemResponses = {
9557
8626
  /**
9558
- * Agent retrieved successfully
8627
+ * Feed item unarchived successfully
9559
8628
  */
9560
- 200: Agent;
8629
+ 204: void;
9561
8630
  };
9562
- export type GetAgentResponse = GetAgentResponses[keyof GetAgentResponses];
9563
- export type UpdateAgentData = {
9564
- body: UpdateAgentRequest;
8631
+ export type UnarchiveFeedItemResponse = UnarchiveFeedItemResponses[keyof UnarchiveFeedItemResponses];
8632
+ export type GetInvitationByTokenData = {
8633
+ body?: never;
9565
8634
  path: {
9566
8635
  /**
9567
- * Team identifier
9568
- */
9569
- team_id: string;
9570
- /**
9571
- * Agent identifier
8636
+ * Opaque invitation token from the invitation email link
9572
8637
  */
9573
- id: string;
8638
+ token: string;
9574
8639
  };
9575
8640
  query?: never;
9576
- url: '/api/v1/{team_id}/agents/{id}';
8641
+ url: '/api/v1/invitations/{token}';
9577
8642
  };
9578
- export type UpdateAgentErrors = {
9579
- /**
9580
- * Invalid request body, validation error
9581
- */
9582
- 400: ErrorResponse;
8643
+ export type GetInvitationByTokenErrors = {
9583
8644
  /**
9584
- * Unauthorized
8645
+ * Authentication required
9585
8646
  */
9586
8647
  401: ErrorResponse;
9587
8648
  /**
9588
- * Payment required active subscription required
9589
- */
9590
- 402: ErrorResponse;
9591
- /**
9592
- * Forbidden — not a team member
9593
- */
9594
- 403: ErrorResponse;
9595
- /**
9596
- * Agent not found
8649
+ * Invitation not found for the given token
9597
8650
  */
9598
8651
  404: ErrorResponse;
9599
8652
  /**
9600
- * An agent with that name already exists for this user
8653
+ * Invitation has already been accepted, rejected, or revoked
9601
8654
  */
9602
8655
  409: ErrorResponse;
8656
+ /**
8657
+ * Invitation has expired
8658
+ */
8659
+ 410: ErrorResponse;
9603
8660
  /**
9604
8661
  * Internal server error
9605
8662
  */
9606
8663
  500: ErrorResponse;
9607
8664
  };
9608
- export type UpdateAgentError = UpdateAgentErrors[keyof UpdateAgentErrors];
9609
- export type UpdateAgentResponses = {
8665
+ export type GetInvitationByTokenError = GetInvitationByTokenErrors[keyof GetInvitationByTokenErrors];
8666
+ export type GetInvitationByTokenResponses = {
9610
8667
  /**
9611
- * Agent updated successfully
8668
+ * Invitation details retrieved successfully
9612
8669
  */
9613
- 200: Agent;
8670
+ 200: InvitationDetailsResponse;
9614
8671
  };
9615
- export type UpdateAgentResponse = UpdateAgentResponses[keyof UpdateAgentResponses];
9616
- export type UpdateAgentCredentialsData = {
9617
- body: UpdateAgentCredentialsRequest;
8672
+ export type GetInvitationByTokenResponse = GetInvitationByTokenResponses[keyof GetInvitationByTokenResponses];
8673
+ export type ListAgentsData = {
8674
+ body?: never;
9618
8675
  path: {
9619
8676
  /**
9620
8677
  * Team identifier
9621
8678
  */
9622
8679
  team_id: string;
8680
+ };
8681
+ query?: {
9623
8682
  /**
9624
- * Agent identifier
8683
+ * Filter by agent status
9625
8684
  */
9626
- id: string;
8685
+ status?: 'active' | 'paused' | 'error';
8686
+ /**
8687
+ * Search in agent name and description
8688
+ */
8689
+ search?: string;
8690
+ /**
8691
+ * Sort field
8692
+ */
8693
+ sort_by?: 'name' | 'status' | 'updated_at' | 'created_at' | 'last_run' | 'success_rate';
8694
+ /**
8695
+ * Sort order
8696
+ */
8697
+ sort_order?: 'asc' | 'desc';
8698
+ /**
8699
+ * Page number
8700
+ */
8701
+ page?: number;
8702
+ /**
8703
+ * Items per page
8704
+ */
8705
+ limit?: number;
9627
8706
  };
9628
- query?: never;
9629
- url: '/api/v1/{team_id}/agents/{id}/credentials';
8707
+ url: '/api/v1/{team_id}/agents';
9630
8708
  };
9631
- export type UpdateAgentCredentialsErrors = {
8709
+ export type ListAgentsErrors = {
9632
8710
  /**
9633
- * Invalid request body or validation error
8711
+ * Invalid sort_by value or invalid team_id
9634
8712
  */
9635
8713
  400: ErrorResponse;
9636
8714
  /**
@@ -9645,41 +8723,33 @@ export type UpdateAgentCredentialsErrors = {
9645
8723
  * Forbidden — not a team member
9646
8724
  */
9647
8725
  403: ErrorResponse;
9648
- /**
9649
- * Agent not found
9650
- */
9651
- 404: ErrorResponse;
9652
8726
  /**
9653
8727
  * Internal server error
9654
8728
  */
9655
8729
  500: ErrorResponse;
9656
8730
  };
9657
- export type UpdateAgentCredentialsError = UpdateAgentCredentialsErrors[keyof UpdateAgentCredentialsErrors];
9658
- export type UpdateAgentCredentialsResponses = {
8731
+ export type ListAgentsError = ListAgentsErrors[keyof ListAgentsErrors];
8732
+ export type ListAgentsResponses = {
9659
8733
  /**
9660
- * Credentials updated successfully
8734
+ * Agents retrieved successfully
9661
8735
  */
9662
- 204: void;
8736
+ 200: AgentListResponse;
9663
8737
  };
9664
- export type UpdateAgentCredentialsResponse = UpdateAgentCredentialsResponses[keyof UpdateAgentCredentialsResponses];
9665
- export type ExecuteAgentData = {
9666
- body: ExecuteAgentRequest;
8738
+ export type ListAgentsResponse = ListAgentsResponses[keyof ListAgentsResponses];
8739
+ export type CreateAgentData = {
8740
+ body: CreateAgentRequest;
9667
8741
  path: {
9668
8742
  /**
9669
8743
  * Team identifier
9670
8744
  */
9671
8745
  team_id: string;
9672
- /**
9673
- * Agent identifier
9674
- */
9675
- id: string;
9676
8746
  };
9677
8747
  query?: never;
9678
- url: '/api/v1/{team_id}/agents/{id}/execute';
8748
+ url: '/api/v1/{team_id}/agents';
9679
8749
  };
9680
- export type ExecuteAgentErrors = {
8750
+ export type CreateAgentErrors = {
9681
8751
  /**
9682
- * Invalid request body or agent is not active
8752
+ * Invalid request body, validation error, or invalid/unfetchable agent card (4xx from the card host)
9683
8753
  */
9684
8754
  400: ErrorResponse;
9685
8755
  /**
@@ -9691,65 +8761,44 @@ export type ExecuteAgentErrors = {
9691
8761
  */
9692
8762
  402: ErrorResponse;
9693
8763
  /**
9694
- * Forbidden — not a team member
8764
+ * Forbidden — not a team member, or agent limit reached for the subscription plan
9695
8765
  */
9696
8766
  403: ErrorResponse;
9697
8767
  /**
9698
- * Agent not found
8768
+ * An agent with that name already exists for this user
9699
8769
  */
9700
- 404: ErrorResponse;
8770
+ 409: ErrorResponse;
9701
8771
  /**
9702
8772
  * Internal server error
9703
8773
  */
9704
8774
  500: ErrorResponse;
8775
+ /**
8776
+ * Agent card host unreachable or returned a server error
8777
+ */
8778
+ 502: ErrorResponse;
9705
8779
  };
9706
- export type ExecuteAgentError = ExecuteAgentErrors[keyof ExecuteAgentErrors];
9707
- export type ExecuteAgentResponses = {
8780
+ export type CreateAgentError = CreateAgentErrors[keyof CreateAgentErrors];
8781
+ export type CreateAgentResponses = {
9708
8782
  /**
9709
- * Execution created (streaming agents) or completed (non-streaming agents)
8783
+ * Agent created successfully
9710
8784
  */
9711
- 200: AgentExecution;
8785
+ 201: Agent;
9712
8786
  };
9713
- export type ExecuteAgentResponse = ExecuteAgentResponses[keyof ExecuteAgentResponses];
9714
- export type ListAgentExecutionsData = {
9715
- body?: never;
8787
+ export type CreateAgentResponse = CreateAgentResponses[keyof CreateAgentResponses];
8788
+ export type PreviewAgentCardData = {
8789
+ body: PreviewAgentCardRequest;
9716
8790
  path: {
9717
8791
  /**
9718
8792
  * Team identifier
9719
8793
  */
9720
8794
  team_id: string;
9721
- /**
9722
- * Agent identifier
9723
- */
9724
- id: string;
9725
- };
9726
- query?: {
9727
- /**
9728
- * Filter by execution status
9729
- */
9730
- status?: string;
9731
- /**
9732
- * Filter executions started on or after this date
9733
- */
9734
- date_from?: string;
9735
- /**
9736
- * Filter executions started on or before this date
9737
- */
9738
- date_to?: string;
9739
- /**
9740
- * Page number
9741
- */
9742
- page?: number;
9743
- /**
9744
- * Items per page
9745
- */
9746
- limit?: number;
9747
8795
  };
9748
- url: '/api/v1/{team_id}/agents/{id}/executions';
8796
+ query?: never;
8797
+ url: '/api/v1/{team_id}/agents/preview-card';
9749
8798
  };
9750
- export type ListAgentExecutionsErrors = {
8799
+ export type PreviewAgentCardErrors = {
9751
8800
  /**
9752
- * Invalid team_id
8801
+ * Invalid request body, missing card_url, or invalid/unfetchable agent card (4xx from the card host)
9753
8802
  */
9754
8803
  400: ErrorResponse;
9755
8804
  /**
@@ -9765,36 +8814,32 @@ export type ListAgentExecutionsErrors = {
9765
8814
  */
9766
8815
  403: ErrorResponse;
9767
8816
  /**
9768
- * Internal server error
8817
+ * Agent card host unreachable or returned a server error
9769
8818
  */
9770
- 500: ErrorResponse;
8819
+ 502: ErrorResponse;
9771
8820
  };
9772
- export type ListAgentExecutionsError = ListAgentExecutionsErrors[keyof ListAgentExecutionsErrors];
9773
- export type ListAgentExecutionsResponses = {
8821
+ export type PreviewAgentCardError = PreviewAgentCardErrors[keyof PreviewAgentCardErrors];
8822
+ export type PreviewAgentCardResponses = {
9774
8823
  /**
9775
- * Executions retrieved successfully
8824
+ * Agent card fetched successfully
9776
8825
  */
9777
- 200: AgentExecutionListResponse;
8826
+ 200: AgentCard;
9778
8827
  };
9779
- export type ListAgentExecutionsResponse = ListAgentExecutionsResponses[keyof ListAgentExecutionsResponses];
9780
- export type StartAgentExecutionData = {
9781
- body: CreateAgentExecutionRequest;
8828
+ export type PreviewAgentCardResponse = PreviewAgentCardResponses[keyof PreviewAgentCardResponses];
8829
+ export type GetAgentStatsData = {
8830
+ body?: never;
9782
8831
  path: {
9783
8832
  /**
9784
8833
  * Team identifier
9785
8834
  */
9786
8835
  team_id: string;
9787
- /**
9788
- * Agent identifier
9789
- */
9790
- id: string;
9791
8836
  };
9792
8837
  query?: never;
9793
- url: '/api/v1/{team_id}/agents/{id}/executions';
8838
+ url: '/api/v1/{team_id}/agents/stats';
9794
8839
  };
9795
- export type StartAgentExecutionErrors = {
8840
+ export type GetAgentStatsErrors = {
9796
8841
  /**
9797
- * Invalid request body
8842
+ * Invalid team_id
9798
8843
  */
9799
8844
  400: ErrorResponse;
9800
8845
  /**
@@ -9809,24 +8854,20 @@ export type StartAgentExecutionErrors = {
9809
8854
  * Forbidden — not a team member
9810
8855
  */
9811
8856
  403: ErrorResponse;
9812
- /**
9813
- * Agent not found
9814
- */
9815
- 404: ErrorResponse;
9816
8857
  /**
9817
8858
  * Internal server error
9818
8859
  */
9819
8860
  500: ErrorResponse;
9820
8861
  };
9821
- export type StartAgentExecutionError = StartAgentExecutionErrors[keyof StartAgentExecutionErrors];
9822
- export type StartAgentExecutionResponses = {
8862
+ export type GetAgentStatsError = GetAgentStatsErrors[keyof GetAgentStatsErrors];
8863
+ export type GetAgentStatsResponses = {
9823
8864
  /**
9824
- * Execution started successfully
8865
+ * Agent statistics retrieved successfully
9825
8866
  */
9826
- 201: AgentExecution;
8867
+ 200: AgentStatsResponse;
9827
8868
  };
9828
- export type StartAgentExecutionResponse = StartAgentExecutionResponses[keyof StartAgentExecutionResponses];
9829
- export type ListAgentConversationsData = {
8869
+ export type GetAgentStatsResponse = GetAgentStatsResponses[keyof GetAgentStatsResponses];
8870
+ export type DeleteAgentData = {
9830
8871
  body?: never;
9831
8872
  path: {
9832
8873
  /**
@@ -9838,19 +8879,10 @@ export type ListAgentConversationsData = {
9838
8879
  */
9839
8880
  id: string;
9840
8881
  };
9841
- query?: {
9842
- /**
9843
- * Page number
9844
- */
9845
- page?: number;
9846
- /**
9847
- * Items per page
9848
- */
9849
- limit?: number;
9850
- };
9851
- url: '/api/v1/{team_id}/agents/{id}/conversations';
8882
+ query?: never;
8883
+ url: '/api/v1/{team_id}/agents/{id}';
9852
8884
  };
9853
- export type ListAgentConversationsErrors = {
8885
+ export type DeleteAgentErrors = {
9854
8886
  /**
9855
8887
  * Invalid team_id
9856
8888
  */
@@ -9868,7 +8900,7 @@ export type ListAgentConversationsErrors = {
9868
8900
  */
9869
8901
  403: ErrorResponse;
9870
8902
  /**
9871
- * Agent not found in the specified team
8903
+ * Agent not found
9872
8904
  */
9873
8905
  404: ErrorResponse;
9874
8906
  /**
@@ -9876,15 +8908,15 @@ export type ListAgentConversationsErrors = {
9876
8908
  */
9877
8909
  500: ErrorResponse;
9878
8910
  };
9879
- export type ListAgentConversationsError = ListAgentConversationsErrors[keyof ListAgentConversationsErrors];
9880
- export type ListAgentConversationsResponses = {
8911
+ export type DeleteAgentError = DeleteAgentErrors[keyof DeleteAgentErrors];
8912
+ export type DeleteAgentResponses = {
9881
8913
  /**
9882
- * Conversations retrieved successfully
8914
+ * Agent deleted successfully
9883
8915
  */
9884
- 200: ConversationListResponse;
8916
+ 204: void;
9885
8917
  };
9886
- export type ListAgentConversationsResponse = ListAgentConversationsResponses[keyof ListAgentConversationsResponses];
9887
- export type GetAgentExecutionData = {
8918
+ export type DeleteAgentResponse = DeleteAgentResponses[keyof DeleteAgentResponses];
8919
+ export type GetAgentData = {
9888
8920
  body?: never;
9889
8921
  path: {
9890
8922
  /**
@@ -9892,14 +8924,14 @@ export type GetAgentExecutionData = {
9892
8924
  */
9893
8925
  team_id: string;
9894
8926
  /**
9895
- * Execution identifier
8927
+ * Agent identifier
9896
8928
  */
9897
- execution_id: string;
8929
+ id: string;
9898
8930
  };
9899
8931
  query?: never;
9900
- url: '/api/v1/{team_id}/agents/executions/{execution_id}';
8932
+ url: '/api/v1/{team_id}/agents/{id}';
9901
8933
  };
9902
- export type GetAgentExecutionErrors = {
8934
+ export type GetAgentErrors = {
9903
8935
  /**
9904
8936
  * Invalid team_id
9905
8937
  */
@@ -9917,7 +8949,7 @@ export type GetAgentExecutionErrors = {
9917
8949
  */
9918
8950
  403: ErrorResponse;
9919
8951
  /**
9920
- * Execution not found
8952
+ * Agent not found
9921
8953
  */
9922
8954
  404: ErrorResponse;
9923
8955
  /**
@@ -9925,32 +8957,32 @@ export type GetAgentExecutionErrors = {
9925
8957
  */
9926
8958
  500: ErrorResponse;
9927
8959
  };
9928
- export type GetAgentExecutionError = GetAgentExecutionErrors[keyof GetAgentExecutionErrors];
9929
- export type GetAgentExecutionResponses = {
8960
+ export type GetAgentError = GetAgentErrors[keyof GetAgentErrors];
8961
+ export type GetAgentResponses = {
9930
8962
  /**
9931
- * Execution retrieved successfully
8963
+ * Agent retrieved successfully
9932
8964
  */
9933
- 200: AgentExecution;
8965
+ 200: Agent;
9934
8966
  };
9935
- export type GetAgentExecutionResponse = GetAgentExecutionResponses[keyof GetAgentExecutionResponses];
9936
- export type CompleteAgentExecutionData = {
9937
- body: UpdateAgentExecutionRequest;
8967
+ export type GetAgentResponse = GetAgentResponses[keyof GetAgentResponses];
8968
+ export type UpdateAgentData = {
8969
+ body: UpdateAgentRequest;
9938
8970
  path: {
9939
8971
  /**
9940
8972
  * Team identifier
9941
8973
  */
9942
8974
  team_id: string;
9943
8975
  /**
9944
- * Execution identifier
8976
+ * Agent identifier
9945
8977
  */
9946
- execution_id: string;
8978
+ id: string;
9947
8979
  };
9948
8980
  query?: never;
9949
- url: '/api/v1/{team_id}/agents/executions/{execution_id}';
8981
+ url: '/api/v1/{team_id}/agents/{id}';
9950
8982
  };
9951
- export type CompleteAgentExecutionErrors = {
8983
+ export type UpdateAgentErrors = {
9952
8984
  /**
9953
- * Invalid request body or status not one of running, success, error
8985
+ * Invalid request body, validation error
9954
8986
  */
9955
8987
  400: ErrorResponse;
9956
8988
  /**
@@ -9966,40 +8998,44 @@ export type CompleteAgentExecutionErrors = {
9966
8998
  */
9967
8999
  403: ErrorResponse;
9968
9000
  /**
9969
- * Execution not found
9001
+ * Agent not found
9970
9002
  */
9971
9003
  404: ErrorResponse;
9004
+ /**
9005
+ * An agent with that name already exists for this user
9006
+ */
9007
+ 409: ErrorResponse;
9972
9008
  /**
9973
9009
  * Internal server error
9974
9010
  */
9975
9011
  500: ErrorResponse;
9976
9012
  };
9977
- export type CompleteAgentExecutionError = CompleteAgentExecutionErrors[keyof CompleteAgentExecutionErrors];
9978
- export type CompleteAgentExecutionResponses = {
9013
+ export type UpdateAgentError = UpdateAgentErrors[keyof UpdateAgentErrors];
9014
+ export type UpdateAgentResponses = {
9979
9015
  /**
9980
- * Execution updated successfully
9016
+ * Agent updated successfully
9981
9017
  */
9982
- 200: AgentExecution;
9018
+ 200: Agent;
9983
9019
  };
9984
- export type CompleteAgentExecutionResponse = CompleteAgentExecutionResponses[keyof CompleteAgentExecutionResponses];
9985
- export type CancelAgentExecutionData = {
9986
- body?: never;
9020
+ export type UpdateAgentResponse = UpdateAgentResponses[keyof UpdateAgentResponses];
9021
+ export type UpdateAgentCredentialsData = {
9022
+ body: UpdateAgentCredentialsRequest;
9987
9023
  path: {
9988
9024
  /**
9989
9025
  * Team identifier
9990
9026
  */
9991
9027
  team_id: string;
9992
9028
  /**
9993
- * Execution identifier
9029
+ * Agent identifier
9994
9030
  */
9995
- execution_id: string;
9031
+ id: string;
9996
9032
  };
9997
9033
  query?: never;
9998
- url: '/api/v1/{team_id}/agents/executions/{execution_id}/cancel';
9034
+ url: '/api/v1/{team_id}/agents/{id}/credentials';
9999
9035
  };
10000
- export type CancelAgentExecutionErrors = {
9036
+ export type UpdateAgentCredentialsErrors = {
10001
9037
  /**
10002
- * Invalid team_id
9038
+ * Invalid request body or validation error
10003
9039
  */
10004
9040
  400: ErrorResponse;
10005
9041
  /**
@@ -10015,44 +9051,40 @@ export type CancelAgentExecutionErrors = {
10015
9051
  */
10016
9052
  403: ErrorResponse;
10017
9053
  /**
10018
- * Execution not found, or its agent does not belong to the specified team
9054
+ * Agent not found
10019
9055
  */
10020
9056
  404: ErrorResponse;
10021
- /**
10022
- * Execution is already terminal or its task cannot be cancelled
10023
- */
10024
- 409: ErrorResponse;
10025
9057
  /**
10026
9058
  * Internal server error
10027
9059
  */
10028
9060
  500: ErrorResponse;
10029
9061
  };
10030
- export type CancelAgentExecutionError = CancelAgentExecutionErrors[keyof CancelAgentExecutionErrors];
10031
- export type CancelAgentExecutionResponses = {
9062
+ export type UpdateAgentCredentialsError = UpdateAgentCredentialsErrors[keyof UpdateAgentCredentialsErrors];
9063
+ export type UpdateAgentCredentialsResponses = {
10032
9064
  /**
10033
- * Execution cancelled successfully
9065
+ * Credentials updated successfully
10034
9066
  */
10035
- 200: AgentExecution;
9067
+ 204: void;
10036
9068
  };
10037
- export type CancelAgentExecutionResponse = CancelAgentExecutionResponses[keyof CancelAgentExecutionResponses];
10038
- export type GetAgentExecutionStatusData = {
10039
- body?: never;
9069
+ export type UpdateAgentCredentialsResponse = UpdateAgentCredentialsResponses[keyof UpdateAgentCredentialsResponses];
9070
+ export type ExecuteAgentData = {
9071
+ body: ExecuteAgentRequest;
10040
9072
  path: {
10041
9073
  /**
10042
9074
  * Team identifier
10043
9075
  */
10044
9076
  team_id: string;
10045
9077
  /**
10046
- * Execution identifier
9078
+ * Agent identifier
10047
9079
  */
10048
9080
  id: string;
10049
9081
  };
10050
9082
  query?: never;
10051
- url: '/api/v1/{team_id}/agents/executions/{id}/status';
9083
+ url: '/api/v1/{team_id}/agents/{id}/execute';
10052
9084
  };
10053
- export type GetAgentExecutionStatusErrors = {
9085
+ export type ExecuteAgentErrors = {
10054
9086
  /**
10055
- * Invalid team_id
9087
+ * Invalid request body or agent is not active
10056
9088
  */
10057
9089
  400: ErrorResponse;
10058
9090
  /**
@@ -10068,7 +9100,7 @@ export type GetAgentExecutionStatusErrors = {
10068
9100
  */
10069
9101
  403: ErrorResponse;
10070
9102
  /**
10071
- * Execution not found, or its agent does not belong to the specified team
9103
+ * Agent not found
10072
9104
  */
10073
9105
  404: ErrorResponse;
10074
9106
  /**
@@ -10076,15 +9108,15 @@ export type GetAgentExecutionStatusErrors = {
10076
9108
  */
10077
9109
  500: ErrorResponse;
10078
9110
  };
10079
- export type GetAgentExecutionStatusError = GetAgentExecutionStatusErrors[keyof GetAgentExecutionStatusErrors];
10080
- export type GetAgentExecutionStatusResponses = {
9111
+ export type ExecuteAgentError = ExecuteAgentErrors[keyof ExecuteAgentErrors];
9112
+ export type ExecuteAgentResponses = {
10081
9113
  /**
10082
- * Execution status retrieved successfully
9114
+ * Execution created (streaming agents) or completed (non-streaming agents)
10083
9115
  */
10084
9116
  200: AgentExecution;
10085
9117
  };
10086
- export type GetAgentExecutionStatusResponse = GetAgentExecutionStatusResponses[keyof GetAgentExecutionStatusResponses];
10087
- export type GetAgentExecutionEventsData = {
9118
+ export type ExecuteAgentResponse = ExecuteAgentResponses[keyof ExecuteAgentResponses];
9119
+ export type ListAgentExecutionsData = {
10088
9120
  body?: never;
10089
9121
  path: {
10090
9122
  /**
@@ -10092,27 +9124,35 @@ export type GetAgentExecutionEventsData = {
10092
9124
  */
10093
9125
  team_id: string;
10094
9126
  /**
10095
- * Execution identifier
9127
+ * Agent identifier
10096
9128
  */
10097
9129
  id: string;
10098
9130
  };
10099
9131
  query?: {
10100
9132
  /**
10101
- * Return events with a sequence number greater than this value (enables cursor-based polling)
9133
+ * Filter by execution status
10102
9134
  */
10103
- since?: number;
9135
+ status?: string;
10104
9136
  /**
10105
- * Page number (page-based mode only)
9137
+ * Filter executions started on or after this date
9138
+ */
9139
+ date_from?: string;
9140
+ /**
9141
+ * Filter executions started on or before this date
9142
+ */
9143
+ date_to?: string;
9144
+ /**
9145
+ * Page number
10106
9146
  */
10107
9147
  page?: number;
10108
9148
  /**
10109
- * Items per page (page-based mode only)
9149
+ * Items per page
10110
9150
  */
10111
9151
  limit?: number;
10112
9152
  };
10113
- url: '/api/v1/{team_id}/agents/executions/{id}/events';
9153
+ url: '/api/v1/{team_id}/agents/{id}/executions';
10114
9154
  };
10115
- export type GetAgentExecutionEventsErrors = {
9155
+ export type ListAgentExecutionsErrors = {
10116
9156
  /**
10117
9157
  * Invalid team_id
10118
9158
  */
@@ -10129,50 +9169,37 @@ export type GetAgentExecutionEventsErrors = {
10129
9169
  * Forbidden — not a team member
10130
9170
  */
10131
9171
  403: ErrorResponse;
10132
- /**
10133
- * Execution not found, or its agent does not belong to the specified team
10134
- */
10135
- 404: ErrorResponse;
10136
9172
  /**
10137
9173
  * Internal server error
10138
9174
  */
10139
9175
  500: ErrorResponse;
10140
9176
  };
10141
- export type GetAgentExecutionEventsError = GetAgentExecutionEventsErrors[keyof GetAgentExecutionEventsErrors];
10142
- export type GetAgentExecutionEventsResponses = {
9177
+ export type ListAgentExecutionsError = ListAgentExecutionsErrors[keyof ListAgentExecutionsErrors];
9178
+ export type ListAgentExecutionsResponses = {
10143
9179
  /**
10144
- * Events retrieved successfully (shape depends on whether `since` was provided)
9180
+ * Executions retrieved successfully
10145
9181
  */
10146
- 200: AgentExecutionEventsPollResponse | AgentExecutionEventsPageResponse;
9182
+ 200: AgentExecutionListResponse;
10147
9183
  };
10148
- export type GetAgentExecutionEventsResponse = GetAgentExecutionEventsResponses[keyof GetAgentExecutionEventsResponses];
10149
- export type ListConversationExecutionsData = {
10150
- body?: never;
9184
+ export type ListAgentExecutionsResponse = ListAgentExecutionsResponses[keyof ListAgentExecutionsResponses];
9185
+ export type StartAgentExecutionData = {
9186
+ body: CreateAgentExecutionRequest;
10151
9187
  path: {
10152
9188
  /**
10153
9189
  * Team identifier
10154
9190
  */
10155
9191
  team_id: string;
10156
9192
  /**
10157
- * Conversation identifier
10158
- */
10159
- conversation_id: string;
10160
- };
10161
- query?: {
10162
- /**
10163
- * Maximum number of executions to return
10164
- */
10165
- limit?: number;
10166
- /**
10167
- * Return executions started before this RFC 3339 timestamp
9193
+ * Agent identifier
10168
9194
  */
10169
- before?: string;
9195
+ id: string;
10170
9196
  };
10171
- url: '/api/v1/{team_id}/agents/conversations/{conversation_id}/executions';
9197
+ query?: never;
9198
+ url: '/api/v1/{team_id}/agents/{id}/executions';
10172
9199
  };
10173
- export type ListConversationExecutionsErrors = {
9200
+ export type StartAgentExecutionErrors = {
10174
9201
  /**
10175
- * Invalid team_id
9202
+ * Invalid request body
10176
9203
  */
10177
9204
  400: ErrorResponse;
10178
9205
  /**
@@ -10188,7 +9215,7 @@ export type ListConversationExecutionsErrors = {
10188
9215
  */
10189
9216
  403: ErrorResponse;
10190
9217
  /**
10191
- * Conversation's agent does not belong to the specified team
9218
+ * Agent not found
10192
9219
  */
10193
9220
  404: ErrorResponse;
10194
9221
  /**
@@ -10196,446 +9223,392 @@ export type ListConversationExecutionsErrors = {
10196
9223
  */
10197
9224
  500: ErrorResponse;
10198
9225
  };
10199
- export type ListConversationExecutionsError = ListConversationExecutionsErrors[keyof ListConversationExecutionsErrors];
10200
- export type ListConversationExecutionsResponses = {
9226
+ export type StartAgentExecutionError = StartAgentExecutionErrors[keyof StartAgentExecutionErrors];
9227
+ export type StartAgentExecutionResponses = {
10201
9228
  /**
10202
- * Conversation executions retrieved successfully
9229
+ * Execution started successfully
10203
9230
  */
10204
- 200: ConversationExecutionsResponse;
9231
+ 201: AgentExecution;
10205
9232
  };
10206
- export type ListConversationExecutionsResponse = ListConversationExecutionsResponses[keyof ListConversationExecutionsResponses];
10207
- export type ListClaudeCodeHooksData = {
9233
+ export type StartAgentExecutionResponse = StartAgentExecutionResponses[keyof StartAgentExecutionResponses];
9234
+ export type ListAgentConversationsData = {
10208
9235
  body?: never;
10209
- path?: never;
10210
- query?: {
10211
- /**
10212
- * Page number (default 1; values < 1 fall back to 1)
10213
- */
10214
- page?: number;
10215
- /**
10216
- * Items per page (default 10, capped at 100)
10217
- */
10218
- limit?: number;
10219
- /**
10220
- * Filter by session ID
10221
- */
10222
- session_id?: string;
9236
+ path: {
10223
9237
  /**
10224
- * Filter by hook event name
9238
+ * Team identifier
10225
9239
  */
10226
- hook_event_name?: string;
9240
+ team_id: string;
10227
9241
  /**
10228
- * Filter by tool name
9242
+ * Agent identifier
10229
9243
  */
10230
- tool_name?: string;
9244
+ id: string;
10231
9245
  };
10232
- url: '/api/v1/ai-tools/claude-code/hooks';
10233
- };
10234
- export type ListClaudeCodeHooksErrors = {
10235
- /**
10236
- * Unauthorized
10237
- */
10238
- 401: ErrorResponse;
10239
- /**
10240
- * Internal server error (legacy hook error shape)
10241
- */
10242
- 500: HookErrorResponse;
10243
- };
10244
- export type ListClaudeCodeHooksError = ListClaudeCodeHooksErrors[keyof ListClaudeCodeHooksErrors];
10245
- export type ListClaudeCodeHooksResponses = {
10246
- /**
10247
- * Hook payloads retrieved successfully
10248
- */
10249
- 200: HookListResponse;
10250
- };
10251
- export type ListClaudeCodeHooksResponse = ListClaudeCodeHooksResponses[keyof ListClaudeCodeHooksResponses];
10252
- export type ListClaudeCodeSessionsData = {
10253
- body?: never;
10254
- path?: never;
10255
9246
  query?: {
10256
9247
  /**
10257
- * Page number (default 1; values < 1 fall back to 1)
9248
+ * Page number
10258
9249
  */
10259
9250
  page?: number;
10260
9251
  /**
10261
- * Items per page (default 10, capped at 100)
9252
+ * Items per page
10262
9253
  */
10263
9254
  limit?: number;
10264
9255
  };
10265
- url: '/api/v1/ai-tools/claude-code/sessions';
10266
- };
10267
- export type ListClaudeCodeSessionsErrors = {
10268
- /**
10269
- * Unauthorized
10270
- */
10271
- 401: ErrorResponse;
10272
- /**
10273
- * Internal server error (legacy hook error shape)
10274
- */
10275
- 500: HookErrorResponse;
9256
+ url: '/api/v1/{team_id}/agents/{id}/conversations';
10276
9257
  };
10277
- export type ListClaudeCodeSessionsError = ListClaudeCodeSessionsErrors[keyof ListClaudeCodeSessionsErrors];
10278
- export type ListClaudeCodeSessionsResponses = {
9258
+ export type ListAgentConversationsErrors = {
10279
9259
  /**
10280
- * Sessions retrieved successfully
9260
+ * Invalid team_id
10281
9261
  */
10282
- 200: SessionsListResponse;
10283
- };
10284
- export type ListClaudeCodeSessionsResponse = ListClaudeCodeSessionsResponses[keyof ListClaudeCodeSessionsResponses];
10285
- export type GetClaudeCodeSessionCountsData = {
10286
- body?: never;
10287
- path?: never;
10288
- query?: {
10289
- /**
10290
- * Time range for the counts. Accepted values: `7d` (or `7`), `14d` (or `14`), `30d` (or `30`), `90d` (or `90`, `3m`). Unknown values fall back to `7d`.
10291
- */
10292
- range?: string;
10293
- };
10294
- url: '/api/v1/ai-tools/claude-code/session-counts';
10295
- };
10296
- export type GetClaudeCodeSessionCountsErrors = {
9262
+ 400: ErrorResponse;
10297
9263
  /**
10298
9264
  * Unauthorized
10299
9265
  */
10300
9266
  401: ErrorResponse;
10301
9267
  /**
10302
- * Internal server error (legacy hook error shape)
9268
+ * Payment required active subscription required
10303
9269
  */
10304
- 500: HookErrorResponse;
10305
- };
10306
- export type GetClaudeCodeSessionCountsError = GetClaudeCodeSessionCountsErrors[keyof GetClaudeCodeSessionCountsErrors];
10307
- export type GetClaudeCodeSessionCountsResponses = {
9270
+ 402: ErrorResponse;
10308
9271
  /**
10309
- * Session counts retrieved successfully
9272
+ * Forbidden not a team member
10310
9273
  */
10311
- 200: SessionCountsApiResponse;
10312
- };
10313
- export type GetClaudeCodeSessionCountsResponse = GetClaudeCodeSessionCountsResponses[keyof GetClaudeCodeSessionCountsResponses];
10314
- export type GetClaudeCodeOverviewStatsData = {
10315
- body?: never;
10316
- path?: never;
10317
- query?: never;
10318
- url: '/api/v1/ai-tools/claude-code/overview-stats';
10319
- };
10320
- export type GetClaudeCodeOverviewStatsErrors = {
9274
+ 403: ErrorResponse;
10321
9275
  /**
10322
- * Unauthorized
9276
+ * Agent not found in the specified team
10323
9277
  */
10324
- 401: ErrorResponse;
9278
+ 404: ErrorResponse;
10325
9279
  /**
10326
- * Internal server error (plain-text body, not JSON)
9280
+ * Internal server error
10327
9281
  */
10328
- 500: string;
9282
+ 500: ErrorResponse;
10329
9283
  };
10330
- export type GetClaudeCodeOverviewStatsError = GetClaudeCodeOverviewStatsErrors[keyof GetClaudeCodeOverviewStatsErrors];
10331
- export type GetClaudeCodeOverviewStatsResponses = {
9284
+ export type ListAgentConversationsError = ListAgentConversationsErrors[keyof ListAgentConversationsErrors];
9285
+ export type ListAgentConversationsResponses = {
10332
9286
  /**
10333
- * Overview stats retrieved successfully
9287
+ * Conversations retrieved successfully
10334
9288
  */
10335
- 200: OverviewStatsApiResponse;
9289
+ 200: ConversationListResponse;
10336
9290
  };
10337
- export type GetClaudeCodeOverviewStatsResponse = GetClaudeCodeOverviewStatsResponses[keyof GetClaudeCodeOverviewStatsResponses];
10338
- export type ListClaudeCodeRecentActivitiesData = {
9291
+ export type ListAgentConversationsResponse = ListAgentConversationsResponses[keyof ListAgentConversationsResponses];
9292
+ export type GetAgentExecutionData = {
10339
9293
  body?: never;
10340
- path?: never;
10341
- query?: {
10342
- /**
10343
- * Page number (default 1; values < 1 fall back to 1)
10344
- */
10345
- page?: number;
10346
- /**
10347
- * Items per page (default 20 for this endpoint, capped at 100)
10348
- */
10349
- limit?: number;
10350
- /**
10351
- * Filter by session ID
10352
- */
10353
- session_id?: string;
10354
- /**
10355
- * Filter by tool name
10356
- */
10357
- tool_name?: string;
10358
- /**
10359
- * Filter by hook event name
10360
- */
10361
- hook_event_name?: string;
9294
+ path: {
10362
9295
  /**
10363
- * Filter activities created on or after this date
9296
+ * Team identifier
10364
9297
  */
10365
- date_from?: string;
9298
+ team_id: string;
10366
9299
  /**
10367
- * Filter activities created on or before this date
9300
+ * Execution identifier
10368
9301
  */
10369
- date_to?: string;
9302
+ execution_id: string;
10370
9303
  };
10371
- url: '/api/v1/ai-tools/claude-code/recent-activities';
9304
+ query?: never;
9305
+ url: '/api/v1/{team_id}/agents/executions/{execution_id}';
10372
9306
  };
10373
- export type ListClaudeCodeRecentActivitiesErrors = {
9307
+ export type GetAgentExecutionErrors = {
9308
+ /**
9309
+ * Invalid team_id
9310
+ */
9311
+ 400: ErrorResponse;
10374
9312
  /**
10375
9313
  * Unauthorized
10376
9314
  */
10377
9315
  401: ErrorResponse;
10378
9316
  /**
10379
- * Internal server error (legacy hook error shape)
9317
+ * Payment required active subscription required
9318
+ */
9319
+ 402: ErrorResponse;
9320
+ /**
9321
+ * Forbidden — not a team member
9322
+ */
9323
+ 403: ErrorResponse;
9324
+ /**
9325
+ * Execution not found
9326
+ */
9327
+ 404: ErrorResponse;
9328
+ /**
9329
+ * Internal server error
10380
9330
  */
10381
- 500: HookErrorResponse;
9331
+ 500: ErrorResponse;
10382
9332
  };
10383
- export type ListClaudeCodeRecentActivitiesError = ListClaudeCodeRecentActivitiesErrors[keyof ListClaudeCodeRecentActivitiesErrors];
10384
- export type ListClaudeCodeRecentActivitiesResponses = {
9333
+ export type GetAgentExecutionError = GetAgentExecutionErrors[keyof GetAgentExecutionErrors];
9334
+ export type GetAgentExecutionResponses = {
10385
9335
  /**
10386
- * Recent activities retrieved successfully
9336
+ * Execution retrieved successfully
10387
9337
  */
10388
- 200: RecentActivitiesApiResponse;
9338
+ 200: AgentExecution;
10389
9339
  };
10390
- export type ListClaudeCodeRecentActivitiesResponse = ListClaudeCodeRecentActivitiesResponses[keyof ListClaudeCodeRecentActivitiesResponses];
10391
- export type ListCursorIdeHooksData = {
10392
- body?: never;
10393
- path?: never;
10394
- query?: {
10395
- /**
10396
- * Page number (default 1; values < 1 fall back to 1)
10397
- */
10398
- page?: number;
10399
- /**
10400
- * Items per page (default 10, capped at 100)
10401
- */
10402
- limit?: number;
10403
- /**
10404
- * Filter by session ID
10405
- */
10406
- session_id?: string;
9340
+ export type GetAgentExecutionResponse = GetAgentExecutionResponses[keyof GetAgentExecutionResponses];
9341
+ export type CompleteAgentExecutionData = {
9342
+ body: UpdateAgentExecutionRequest;
9343
+ path: {
10407
9344
  /**
10408
- * Filter by hook event name
9345
+ * Team identifier
10409
9346
  */
10410
- hook_event_name?: string;
9347
+ team_id: string;
10411
9348
  /**
10412
- * Filter by tool name
9349
+ * Execution identifier
10413
9350
  */
10414
- tool_name?: string;
9351
+ execution_id: string;
10415
9352
  };
10416
- url: '/api/v1/ai-tools/cursor-ide/hooks';
9353
+ query?: never;
9354
+ url: '/api/v1/{team_id}/agents/executions/{execution_id}';
10417
9355
  };
10418
- export type ListCursorIdeHooksErrors = {
9356
+ export type CompleteAgentExecutionErrors = {
9357
+ /**
9358
+ * Invalid request body or status not one of running, success, error
9359
+ */
9360
+ 400: ErrorResponse;
10419
9361
  /**
10420
9362
  * Unauthorized
10421
9363
  */
10422
9364
  401: ErrorResponse;
10423
9365
  /**
10424
- * Internal server error (legacy hook error shape)
9366
+ * Payment required active subscription required
9367
+ */
9368
+ 402: ErrorResponse;
9369
+ /**
9370
+ * Forbidden — not a team member
9371
+ */
9372
+ 403: ErrorResponse;
9373
+ /**
9374
+ * Execution not found
9375
+ */
9376
+ 404: ErrorResponse;
9377
+ /**
9378
+ * Internal server error
10425
9379
  */
10426
- 500: HookErrorResponse;
9380
+ 500: ErrorResponse;
10427
9381
  };
10428
- export type ListCursorIdeHooksError = ListCursorIdeHooksErrors[keyof ListCursorIdeHooksErrors];
10429
- export type ListCursorIdeHooksResponses = {
9382
+ export type CompleteAgentExecutionError = CompleteAgentExecutionErrors[keyof CompleteAgentExecutionErrors];
9383
+ export type CompleteAgentExecutionResponses = {
10430
9384
  /**
10431
- * Hook payloads retrieved successfully
9385
+ * Execution updated successfully
10432
9386
  */
10433
- 200: CursorIdeHookListResponse;
9387
+ 200: AgentExecution;
10434
9388
  };
10435
- export type ListCursorIdeHooksResponse = ListCursorIdeHooksResponses[keyof ListCursorIdeHooksResponses];
10436
- export type ListCursorIdeSessionsData = {
9389
+ export type CompleteAgentExecutionResponse = CompleteAgentExecutionResponses[keyof CompleteAgentExecutionResponses];
9390
+ export type CancelAgentExecutionData = {
10437
9391
  body?: never;
10438
- path?: never;
10439
- query?: {
9392
+ path: {
10440
9393
  /**
10441
- * Page number (default 1; values < 1 fall back to 1)
9394
+ * Team identifier
10442
9395
  */
10443
- page?: number;
9396
+ team_id: string;
10444
9397
  /**
10445
- * Items per page (default 10, capped at 100)
9398
+ * Execution identifier
10446
9399
  */
10447
- limit?: number;
9400
+ execution_id: string;
10448
9401
  };
10449
- url: '/api/v1/ai-tools/cursor-ide/sessions';
9402
+ query?: never;
9403
+ url: '/api/v1/{team_id}/agents/executions/{execution_id}/cancel';
10450
9404
  };
10451
- export type ListCursorIdeSessionsErrors = {
9405
+ export type CancelAgentExecutionErrors = {
9406
+ /**
9407
+ * Invalid team_id
9408
+ */
9409
+ 400: ErrorResponse;
10452
9410
  /**
10453
9411
  * Unauthorized
10454
9412
  */
10455
9413
  401: ErrorResponse;
10456
9414
  /**
10457
- * Internal server error (legacy hook error shape)
9415
+ * Payment required active subscription required
9416
+ */
9417
+ 402: ErrorResponse;
9418
+ /**
9419
+ * Forbidden — not a team member
9420
+ */
9421
+ 403: ErrorResponse;
9422
+ /**
9423
+ * Execution not found, or its agent does not belong to the specified team
9424
+ */
9425
+ 404: ErrorResponse;
9426
+ /**
9427
+ * Execution is already terminal or its task cannot be cancelled
9428
+ */
9429
+ 409: ErrorResponse;
9430
+ /**
9431
+ * Internal server error
10458
9432
  */
10459
- 500: HookErrorResponse;
9433
+ 500: ErrorResponse;
10460
9434
  };
10461
- export type ListCursorIdeSessionsError = ListCursorIdeSessionsErrors[keyof ListCursorIdeSessionsErrors];
10462
- export type ListCursorIdeSessionsResponses = {
9435
+ export type CancelAgentExecutionError = CancelAgentExecutionErrors[keyof CancelAgentExecutionErrors];
9436
+ export type CancelAgentExecutionResponses = {
10463
9437
  /**
10464
- * Sessions retrieved successfully
9438
+ * Execution cancelled successfully
10465
9439
  */
10466
- 200: CursorSessionsListResponse;
9440
+ 200: AgentExecution;
10467
9441
  };
10468
- export type ListCursorIdeSessionsResponse = ListCursorIdeSessionsResponses[keyof ListCursorIdeSessionsResponses];
10469
- export type GetCursorIdeSessionCountsData = {
9442
+ export type CancelAgentExecutionResponse = CancelAgentExecutionResponses[keyof CancelAgentExecutionResponses];
9443
+ export type GetAgentExecutionStatusData = {
10470
9444
  body?: never;
10471
- path?: never;
10472
- query?: {
9445
+ path: {
9446
+ /**
9447
+ * Team identifier
9448
+ */
9449
+ team_id: string;
10473
9450
  /**
10474
- * Time range for the counts. Accepted values: `7d` (or `7`), `14d` (or `14`), `30d` (or `30`), `90d` (or `90`, `3m`). Unknown values fall back to `7d`.
9451
+ * Execution identifier
10475
9452
  */
10476
- range?: string;
9453
+ id: string;
10477
9454
  };
10478
- url: '/api/v1/ai-tools/cursor-ide/session-counts';
9455
+ query?: never;
9456
+ url: '/api/v1/{team_id}/agents/executions/{id}/status';
10479
9457
  };
10480
- export type GetCursorIdeSessionCountsErrors = {
9458
+ export type GetAgentExecutionStatusErrors = {
9459
+ /**
9460
+ * Invalid team_id
9461
+ */
9462
+ 400: ErrorResponse;
10481
9463
  /**
10482
9464
  * Unauthorized
10483
9465
  */
10484
9466
  401: ErrorResponse;
10485
9467
  /**
10486
- * Internal server error (legacy hook error shape)
9468
+ * Payment required active subscription required
10487
9469
  */
10488
- 500: HookErrorResponse;
10489
- };
10490
- export type GetCursorIdeSessionCountsError = GetCursorIdeSessionCountsErrors[keyof GetCursorIdeSessionCountsErrors];
10491
- export type GetCursorIdeSessionCountsResponses = {
9470
+ 402: ErrorResponse;
10492
9471
  /**
10493
- * Session counts retrieved successfully
9472
+ * Forbidden not a team member
10494
9473
  */
10495
- 200: SessionCountsApiResponse;
10496
- };
10497
- export type GetCursorIdeSessionCountsResponse = GetCursorIdeSessionCountsResponses[keyof GetCursorIdeSessionCountsResponses];
10498
- export type GetCursorIdeOverviewStatsData = {
10499
- body?: never;
10500
- path?: never;
10501
- query?: never;
10502
- url: '/api/v1/ai-tools/cursor-ide/overview-stats';
10503
- };
10504
- export type GetCursorIdeOverviewStatsErrors = {
9474
+ 403: ErrorResponse;
10505
9475
  /**
10506
- * Unauthorized
9476
+ * Execution not found, or its agent does not belong to the specified team
10507
9477
  */
10508
- 401: ErrorResponse;
9478
+ 404: ErrorResponse;
10509
9479
  /**
10510
- * Internal server error (plain-text body, not JSON)
9480
+ * Internal server error
10511
9481
  */
10512
- 500: string;
9482
+ 500: ErrorResponse;
10513
9483
  };
10514
- export type GetCursorIdeOverviewStatsError = GetCursorIdeOverviewStatsErrors[keyof GetCursorIdeOverviewStatsErrors];
10515
- export type GetCursorIdeOverviewStatsResponses = {
9484
+ export type GetAgentExecutionStatusError = GetAgentExecutionStatusErrors[keyof GetAgentExecutionStatusErrors];
9485
+ export type GetAgentExecutionStatusResponses = {
10516
9486
  /**
10517
- * Overview stats retrieved successfully
9487
+ * Execution status retrieved successfully
10518
9488
  */
10519
- 200: CursorOverviewStatsApiResponse;
9489
+ 200: AgentExecution;
10520
9490
  };
10521
- export type GetCursorIdeOverviewStatsResponse = GetCursorIdeOverviewStatsResponses[keyof GetCursorIdeOverviewStatsResponses];
10522
- export type ListCursorIdeRecentActivitiesData = {
9491
+ export type GetAgentExecutionStatusResponse = GetAgentExecutionStatusResponses[keyof GetAgentExecutionStatusResponses];
9492
+ export type GetAgentExecutionEventsData = {
10523
9493
  body?: never;
10524
- path?: never;
10525
- query?: {
10526
- /**
10527
- * Page number (default 1; values < 1 fall back to 1)
10528
- */
10529
- page?: number;
10530
- /**
10531
- * Items per page (default 20 for this endpoint, capped at 100)
10532
- */
10533
- limit?: number;
9494
+ path: {
10534
9495
  /**
10535
- * Filter by session ID
9496
+ * Team identifier
10536
9497
  */
10537
- session_id?: string;
9498
+ team_id: string;
10538
9499
  /**
10539
- * Filter by tool name
9500
+ * Execution identifier
10540
9501
  */
10541
- tool_name?: string;
9502
+ id: string;
9503
+ };
9504
+ query?: {
10542
9505
  /**
10543
- * Filter by hook event name
9506
+ * Return events with a sequence number greater than this value (enables cursor-based polling)
10544
9507
  */
10545
- hook_event_name?: string;
9508
+ since?: number;
10546
9509
  /**
10547
- * Filter activities created on or after this date
9510
+ * Page number (page-based mode only)
10548
9511
  */
10549
- date_from?: string;
9512
+ page?: number;
10550
9513
  /**
10551
- * Filter activities created on or before this date
9514
+ * Items per page (page-based mode only)
10552
9515
  */
10553
- date_to?: string;
9516
+ limit?: number;
10554
9517
  };
10555
- url: '/api/v1/ai-tools/cursor-ide/recent-activities';
9518
+ url: '/api/v1/{team_id}/agents/executions/{id}/events';
10556
9519
  };
10557
- export type ListCursorIdeRecentActivitiesErrors = {
10558
- /**
10559
- * Unauthorized
10560
- */
10561
- 401: ErrorResponse;
9520
+ export type GetAgentExecutionEventsErrors = {
10562
9521
  /**
10563
- * Internal server error (legacy hook error shape)
9522
+ * Invalid team_id
10564
9523
  */
10565
- 500: HookErrorResponse;
10566
- };
10567
- export type ListCursorIdeRecentActivitiesError = ListCursorIdeRecentActivitiesErrors[keyof ListCursorIdeRecentActivitiesErrors];
10568
- export type ListCursorIdeRecentActivitiesResponses = {
9524
+ 400: ErrorResponse;
10569
9525
  /**
10570
- * Recent activities retrieved successfully
9526
+ * Unauthorized
10571
9527
  */
10572
- 200: CursorRecentActivitiesApiResponse;
10573
- };
10574
- export type ListCursorIdeRecentActivitiesResponse = ListCursorIdeRecentActivitiesResponses[keyof ListCursorIdeRecentActivitiesResponses];
10575
- export type IngestClaudeCodeHookData = {
10576
- body: IncomingHookPayload;
10577
- path?: never;
10578
- query?: never;
10579
- url: '/api/v1/claude-code/hooks';
10580
- };
10581
- export type IngestClaudeCodeHookErrors = {
9528
+ 401: ErrorResponse;
10582
9529
  /**
10583
- * Invalid JSON payload or missing required field (session_id, hook_event_name)
9530
+ * Payment required active subscription required
10584
9531
  */
10585
- 400: HookErrorResponse;
9532
+ 402: ErrorResponse;
10586
9533
  /**
10587
- * Unauthorized
9534
+ * Forbidden — not a team member
10588
9535
  */
10589
- 401: ErrorResponse;
9536
+ 403: ErrorResponse;
10590
9537
  /**
10591
- * AI session or AI tools resource limit reached for the subscription plan (includes `details`)
9538
+ * Execution not found, or its agent does not belong to the specified team
10592
9539
  */
10593
- 403: HookErrorResponse;
9540
+ 404: ErrorResponse;
10594
9541
  /**
10595
- * Internal server error (legacy hook error shape)
9542
+ * Internal server error
10596
9543
  */
10597
- 500: HookErrorResponse;
9544
+ 500: ErrorResponse;
10598
9545
  };
10599
- export type IngestClaudeCodeHookError = IngestClaudeCodeHookErrors[keyof IngestClaudeCodeHookErrors];
10600
- export type IngestClaudeCodeHookResponses = {
9546
+ export type GetAgentExecutionEventsError = GetAgentExecutionEventsErrors[keyof GetAgentExecutionEventsErrors];
9547
+ export type GetAgentExecutionEventsResponses = {
10601
9548
  /**
10602
- * Hook payload stored successfully
9549
+ * Events retrieved successfully (shape depends on whether `since` was provided)
10603
9550
  */
10604
- 201: HookCreatedResponse;
9551
+ 200: AgentExecutionEventsPollResponse | AgentExecutionEventsPageResponse;
10605
9552
  };
10606
- export type IngestClaudeCodeHookResponse = IngestClaudeCodeHookResponses[keyof IngestClaudeCodeHookResponses];
10607
- export type IngestCursorIdeHookData = {
10608
- body: IncomingCursorHookPayload;
10609
- path?: never;
10610
- query?: never;
10611
- url: '/api/v1/cursor-ide/hooks';
9553
+ export type GetAgentExecutionEventsResponse = GetAgentExecutionEventsResponses[keyof GetAgentExecutionEventsResponses];
9554
+ export type ListConversationExecutionsData = {
9555
+ body?: never;
9556
+ path: {
9557
+ /**
9558
+ * Team identifier
9559
+ */
9560
+ team_id: string;
9561
+ /**
9562
+ * Conversation identifier
9563
+ */
9564
+ conversation_id: string;
9565
+ };
9566
+ query?: {
9567
+ /**
9568
+ * Maximum number of executions to return
9569
+ */
9570
+ limit?: number;
9571
+ /**
9572
+ * Return executions started before this RFC 3339 timestamp
9573
+ */
9574
+ before?: string;
9575
+ };
9576
+ url: '/api/v1/{team_id}/agents/conversations/{conversation_id}/executions';
10612
9577
  };
10613
- export type IngestCursorIdeHookErrors = {
9578
+ export type ListConversationExecutionsErrors = {
10614
9579
  /**
10615
- * Invalid JSON payload or missing required field (session_id/conversation_id, hook_event_name)
9580
+ * Invalid team_id
10616
9581
  */
10617
- 400: HookErrorResponse;
9582
+ 400: ErrorResponse;
10618
9583
  /**
10619
9584
  * Unauthorized
10620
9585
  */
10621
9586
  401: ErrorResponse;
10622
9587
  /**
10623
- * AI session or AI tools resource limit reached for the subscription plan (includes `details`)
9588
+ * Payment required active subscription required
9589
+ */
9590
+ 402: ErrorResponse;
9591
+ /**
9592
+ * Forbidden — not a team member
9593
+ */
9594
+ 403: ErrorResponse;
9595
+ /**
9596
+ * Conversation's agent does not belong to the specified team
10624
9597
  */
10625
- 403: HookErrorResponse;
9598
+ 404: ErrorResponse;
10626
9599
  /**
10627
- * Internal server error (legacy hook error shape)
9600
+ * Internal server error
10628
9601
  */
10629
- 500: HookErrorResponse;
9602
+ 500: ErrorResponse;
10630
9603
  };
10631
- export type IngestCursorIdeHookError = IngestCursorIdeHookErrors[keyof IngestCursorIdeHookErrors];
10632
- export type IngestCursorIdeHookResponses = {
9604
+ export type ListConversationExecutionsError = ListConversationExecutionsErrors[keyof ListConversationExecutionsErrors];
9605
+ export type ListConversationExecutionsResponses = {
10633
9606
  /**
10634
- * Hook payload stored successfully
9607
+ * Conversation executions retrieved successfully
10635
9608
  */
10636
- 201: HookCreatedResponse;
9609
+ 200: ConversationExecutionsResponse;
10637
9610
  };
10638
- export type IngestCursorIdeHookResponse = IngestCursorIdeHookResponses[keyof IngestCursorIdeHookResponses];
9611
+ export type ListConversationExecutionsResponse = ListConversationExecutionsResponses[keyof ListConversationExecutionsResponses];
10639
9612
  export type ListTeamsData = {
10640
9613
  body?: never;
10641
9614
  path?: never;