@renai-labs/sdk 0.1.7 → 0.1.9

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.
@@ -549,6 +549,60 @@ export class Github extends HeyApiClient {
549
549
  });
550
550
  }
551
551
  }
552
+ export class Config extends HeyApiClient {
553
+ /**
554
+ * Remove the org's Google Workspace OAuth app configuration
555
+ */
556
+ delete(options) {
557
+ return (options?.client ?? this.client).delete({ url: "/api/google/config", ...options });
558
+ }
559
+ /**
560
+ * Save the org's Google Workspace OAuth app credentials (BYO)
561
+ */
562
+ save(options) {
563
+ return (options?.client ?? this.client).put({
564
+ url: "/api/google/config",
565
+ ...options,
566
+ headers: {
567
+ "Content-Type": "application/json",
568
+ ...options?.headers,
569
+ },
570
+ });
571
+ }
572
+ }
573
+ export class Google extends HeyApiClient {
574
+ /**
575
+ * Report the org's Google Workspace OAuth app configuration
576
+ */
577
+ status(options) {
578
+ return (options?.client ?? this.client).get({
579
+ url: "/api/google/status",
580
+ ...options,
581
+ });
582
+ }
583
+ /**
584
+ * Disconnect the Google Workspace account stored in the given vault
585
+ */
586
+ disconnect(options) {
587
+ return (options.client ?? this.client).delete({
588
+ url: "/api/google/vaults/{vaultId}/connect",
589
+ ...options,
590
+ });
591
+ }
592
+ /**
593
+ * Begin connecting a Google Workspace account into the given vault
594
+ */
595
+ connect(options) {
596
+ return (options.client ?? this.client).post({
597
+ url: "/api/google/vaults/{vaultId}/connect",
598
+ ...options,
599
+ });
600
+ }
601
+ _config;
602
+ get config() {
603
+ return (this._config ??= new Config({ client: this.client }));
604
+ }
605
+ }
552
606
  export class Oauth extends HeyApiClient {
553
607
  /**
554
608
  * Start OAuth for an MCP (or confirm it is already connected)
@@ -1634,6 +1688,17 @@ export class Skill extends HeyApiClient {
1634
1688
  return (this._version ??= new Version2({ client: this.client }));
1635
1689
  }
1636
1690
  }
1691
+ export class Topology extends HeyApiClient {
1692
+ /**
1693
+ * Get agent-stack topology
1694
+ */
1695
+ get(options) {
1696
+ return (options?.client ?? this.client).get({
1697
+ url: "/api/topology",
1698
+ ...options,
1699
+ });
1700
+ }
1701
+ }
1637
1702
  export class Trigger extends HeyApiClient {
1638
1703
  /**
1639
1704
  * List cron triggers in a project
@@ -2156,6 +2221,10 @@ export class RenClient extends HeyApiClient {
2156
2221
  get github() {
2157
2222
  return (this._github ??= new Github({ client: this.client }));
2158
2223
  }
2224
+ _google;
2225
+ get google() {
2226
+ return (this._google ??= new Google({ client: this.client }));
2227
+ }
2159
2228
  _mcp;
2160
2229
  get mcp() {
2161
2230
  return (this._mcp ??= new Mcp({ client: this.client }));
@@ -2204,6 +2273,10 @@ export class RenClient extends HeyApiClient {
2204
2273
  get skill() {
2205
2274
  return (this._skill ??= new Skill({ client: this.client }));
2206
2275
  }
2276
+ _topology;
2277
+ get topology() {
2278
+ return (this._topology ??= new Topology({ client: this.client }));
2279
+ }
2207
2280
  _trigger;
2208
2281
  get trigger() {
2209
2282
  return (this._trigger ??= new Trigger({ client: this.client }));
@@ -150,6 +150,10 @@ export type BlueprintTemplate = {
150
150
  mcps: Array<BlueprintMcpRef>;
151
151
  replays: Array<BlueprintReplayRef>;
152
152
  };
153
+ export type RequiredCredential = {
154
+ name: string;
155
+ description?: string;
156
+ };
153
157
  export type Repository = {
154
158
  url?: string;
155
159
  source?: string;
@@ -212,17 +216,27 @@ export type CredentialAuth = {
212
216
  id: number;
213
217
  login: string;
214
218
  name: string | null;
219
+ } | {
220
+ service: "google_workspace";
221
+ sub: string;
222
+ email: string;
223
+ name: string | null;
224
+ hd: string | null;
215
225
  } | null;
216
226
  } | {
217
227
  type: "env";
218
228
  value: string;
229
+ } | {
230
+ type: "basic";
231
+ username: string;
232
+ password: string;
219
233
  };
220
234
  export type Credential = {
221
235
  id: string;
222
236
  vaultId: string;
223
237
  name: string;
224
238
  mcpId: string | null;
225
- provider: "github" | null;
239
+ provider: "github" | "google_workspace" | null;
226
240
  label: string | null;
227
241
  keyPreview: string | null;
228
242
  auth: CredentialAuthPublic;
@@ -244,6 +258,9 @@ export type CredentialAuthPublic = {
244
258
  } | null;
245
259
  } | {
246
260
  type: "env";
261
+ } | {
262
+ type: "basic";
263
+ username: string;
247
264
  };
248
265
  export type Vault = {
249
266
  id: string;
@@ -317,6 +334,68 @@ export type CronTrigger = {
317
334
  updatedAt: string;
318
335
  archivedAt: string | null;
319
336
  };
337
+ export type Topology = {
338
+ surfaces: Array<{
339
+ id: string;
340
+ kind: "mcp" | "cron" | "webhook" | "slack" | "github";
341
+ name: string;
342
+ icon?: string;
343
+ tags: Array<string>;
344
+ ports: Array<{
345
+ id: string;
346
+ label: string;
347
+ targetProjectId: string;
348
+ }>;
349
+ vaultIds: Array<string>;
350
+ }>;
351
+ pods: Array<{
352
+ id: string;
353
+ name: string;
354
+ isPrivate: boolean;
355
+ }>;
356
+ projects: Array<{
357
+ id: string;
358
+ podId: string;
359
+ name: string;
360
+ agents: Array<{
361
+ id: string;
362
+ name: string;
363
+ icon?: string;
364
+ model?: string;
365
+ }>;
366
+ skillsCount: number;
367
+ }>;
368
+ vaults: Array<{
369
+ id: string;
370
+ name: string;
371
+ podIds: Array<string>;
372
+ credentials: Array<{
373
+ id: string;
374
+ label: string;
375
+ forSurfaceId?: string;
376
+ provider?: string;
377
+ }>;
378
+ }>;
379
+ stores: Array<{
380
+ id: string;
381
+ kind: "file" | "memory";
382
+ name: string;
383
+ mounts: Array<{
384
+ projectId: string;
385
+ }>;
386
+ }>;
387
+ env: {
388
+ id: string;
389
+ } | null;
390
+ edges: Array<{
391
+ id: string;
392
+ kind: "route" | "state" | "cred";
393
+ sourceId: string;
394
+ sourcePortId?: string;
395
+ targetId: string;
396
+ targetCredId?: string;
397
+ }>;
398
+ };
320
399
  export type SkillVersion = {
321
400
  id: string;
322
401
  skillId: string;
@@ -336,10 +415,6 @@ export type SkillVersion = {
336
415
  requiredCredentials: Array<RequiredCredential>;
337
416
  releaseNotes: string | null;
338
417
  };
339
- export type RequiredCredential = {
340
- name: string;
341
- description?: string;
342
- };
343
418
  export type Skill = {
344
419
  id: string;
345
420
  slug: string;
@@ -388,14 +463,16 @@ export type AuthRequirements = {
388
463
  mcps: Array<AuthRequirementMcp>;
389
464
  envs: Array<AuthRequirementEnv>;
390
465
  };
466
+ export type AuthRequirementEnvSource = {
467
+ kind: "skill" | "mcp";
468
+ id: string;
469
+ name: string;
470
+ };
391
471
  export type AuthRequirementEnv = {
392
472
  name: string;
393
473
  description?: string;
394
474
  satisfied: boolean;
395
- neededBy: Array<{
396
- skillId: string;
397
- skillName: string;
398
- }>;
475
+ neededBy: Array<AuthRequirementEnvSource>;
399
476
  };
400
477
  export type McpAuthConfig = {
401
478
  type: "oauth";
@@ -720,6 +797,10 @@ export type Mcp = {
720
797
  prompts: Array<string>;
721
798
  auth: "none" | "oauth" | "api_key" | "basic";
722
799
  authConfig: McpAuthConfig | null;
800
+ env: {
801
+ [key: string]: string;
802
+ };
803
+ requiredCredentials: Array<RequiredCredential>;
723
804
  orgId: string;
724
805
  userId: string | null;
725
806
  publisherId: string | null;
@@ -735,6 +816,15 @@ export type Mcp = {
735
816
  deprecationMessage: string | null;
736
817
  tags?: Array<string>;
737
818
  };
819
+ export type GoogleWorkspaceOAuthStartResult = {
820
+ url: string;
821
+ };
822
+ export type GoogleWorkspaceStatus = {
823
+ isConfigured: boolean;
824
+ clientId: string | null;
825
+ scopes: Array<string>;
826
+ redirectUri: string;
827
+ };
738
828
  export type GithubStatus = {
739
829
  hasInstallation: boolean;
740
830
  hasUserCredential: boolean;
@@ -914,6 +1004,25 @@ export type AgentVersion = {
914
1004
  model: string | null;
915
1005
  releaseNotes: string | null;
916
1006
  permission: PermissionConfig;
1007
+ skills?: Array<{
1008
+ skillId: string;
1009
+ skillVersionId?: string | null;
1010
+ skill: {
1011
+ id: string;
1012
+ slug: string;
1013
+ name: string;
1014
+ icon: string | null;
1015
+ };
1016
+ }>;
1017
+ mcps?: Array<{
1018
+ mcpId: string;
1019
+ mcp: {
1020
+ id: string;
1021
+ slug: string;
1022
+ name: string;
1023
+ icon: string | null;
1024
+ };
1025
+ }>;
917
1026
  };
918
1027
  export type SearchResult = {
919
1028
  id: string;
@@ -3101,6 +3210,204 @@ export type GithubReposResponses = {
3101
3210
  }>;
3102
3211
  };
3103
3212
  export type GithubReposResponse = GithubReposResponses[keyof GithubReposResponses];
3213
+ export type GoogleStatusData = {
3214
+ body?: never;
3215
+ path?: never;
3216
+ query?: {
3217
+ /**
3218
+ * Pass 'user' to scope the operation to the authenticated user's private namespace. Omit for the org-wide namespace.
3219
+ */
3220
+ scope?: "user";
3221
+ };
3222
+ url: "/api/google/status";
3223
+ };
3224
+ export type GoogleStatusErrors = {
3225
+ /**
3226
+ * Unauthorized
3227
+ */
3228
+ 401: {
3229
+ error: string;
3230
+ };
3231
+ /**
3232
+ * Forbidden
3233
+ */
3234
+ 403: {
3235
+ error: string;
3236
+ };
3237
+ };
3238
+ export type GoogleStatusError = GoogleStatusErrors[keyof GoogleStatusErrors];
3239
+ export type GoogleStatusResponses = {
3240
+ /**
3241
+ * Google Workspace configuration status
3242
+ */
3243
+ 200: GoogleWorkspaceStatus;
3244
+ };
3245
+ export type GoogleStatusResponse = GoogleStatusResponses[keyof GoogleStatusResponses];
3246
+ export type GoogleConfigDeleteData = {
3247
+ body?: never;
3248
+ path?: never;
3249
+ query?: {
3250
+ /**
3251
+ * Pass 'user' to scope the operation to the authenticated user's private namespace. Omit for the org-wide namespace.
3252
+ */
3253
+ scope?: "user";
3254
+ };
3255
+ url: "/api/google/config";
3256
+ };
3257
+ export type GoogleConfigDeleteErrors = {
3258
+ /**
3259
+ * Unauthorized
3260
+ */
3261
+ 401: {
3262
+ error: string;
3263
+ };
3264
+ /**
3265
+ * Forbidden
3266
+ */
3267
+ 403: {
3268
+ error: string;
3269
+ };
3270
+ };
3271
+ export type GoogleConfigDeleteError = GoogleConfigDeleteErrors[keyof GoogleConfigDeleteErrors];
3272
+ export type GoogleConfigDeleteResponses = {
3273
+ /**
3274
+ * Removed
3275
+ */
3276
+ 204: void;
3277
+ };
3278
+ export type GoogleConfigDeleteResponse = GoogleConfigDeleteResponses[keyof GoogleConfigDeleteResponses];
3279
+ export type GoogleConfigSaveData = {
3280
+ body?: {
3281
+ clientId: string;
3282
+ clientSecret: string;
3283
+ scopes?: Array<string>;
3284
+ };
3285
+ path?: never;
3286
+ query?: {
3287
+ /**
3288
+ * Pass 'user' to scope the operation to the authenticated user's private namespace. Omit for the org-wide namespace.
3289
+ */
3290
+ scope?: "user";
3291
+ };
3292
+ url: "/api/google/config";
3293
+ };
3294
+ export type GoogleConfigSaveErrors = {
3295
+ /**
3296
+ * Bad request
3297
+ */
3298
+ 400: {
3299
+ error: string;
3300
+ };
3301
+ /**
3302
+ * Unauthorized
3303
+ */
3304
+ 401: {
3305
+ error: string;
3306
+ };
3307
+ /**
3308
+ * Forbidden
3309
+ */
3310
+ 403: {
3311
+ error: string;
3312
+ };
3313
+ };
3314
+ export type GoogleConfigSaveError = GoogleConfigSaveErrors[keyof GoogleConfigSaveErrors];
3315
+ export type GoogleConfigSaveResponses = {
3316
+ /**
3317
+ * Updated Google Workspace configuration status
3318
+ */
3319
+ 200: GoogleWorkspaceStatus;
3320
+ };
3321
+ export type GoogleConfigSaveResponse = GoogleConfigSaveResponses[keyof GoogleConfigSaveResponses];
3322
+ export type GoogleDisconnectData = {
3323
+ body?: never;
3324
+ path: {
3325
+ vaultId: string;
3326
+ };
3327
+ query?: {
3328
+ /**
3329
+ * Pass 'user' to scope the operation to the authenticated user's private namespace. Omit for the org-wide namespace.
3330
+ */
3331
+ scope?: "user";
3332
+ };
3333
+ url: "/api/google/vaults/{vaultId}/connect";
3334
+ };
3335
+ export type GoogleDisconnectErrors = {
3336
+ /**
3337
+ * Unauthorized
3338
+ */
3339
+ 401: {
3340
+ error: string;
3341
+ };
3342
+ /**
3343
+ * Forbidden
3344
+ */
3345
+ 403: {
3346
+ error: string;
3347
+ };
3348
+ /**
3349
+ * Not found
3350
+ */
3351
+ 404: {
3352
+ error: string;
3353
+ };
3354
+ };
3355
+ export type GoogleDisconnectError = GoogleDisconnectErrors[keyof GoogleDisconnectErrors];
3356
+ export type GoogleDisconnectResponses = {
3357
+ /**
3358
+ * Removed
3359
+ */
3360
+ 204: void;
3361
+ };
3362
+ export type GoogleDisconnectResponse = GoogleDisconnectResponses[keyof GoogleDisconnectResponses];
3363
+ export type GoogleConnectData = {
3364
+ body?: never;
3365
+ path: {
3366
+ vaultId: string;
3367
+ };
3368
+ query?: {
3369
+ /**
3370
+ * Pass 'user' to scope the operation to the authenticated user's private namespace. Omit for the org-wide namespace.
3371
+ */
3372
+ scope?: "user";
3373
+ returnTo?: string;
3374
+ };
3375
+ url: "/api/google/vaults/{vaultId}/connect";
3376
+ };
3377
+ export type GoogleConnectErrors = {
3378
+ /**
3379
+ * Bad request
3380
+ */
3381
+ 400: {
3382
+ error: string;
3383
+ };
3384
+ /**
3385
+ * Unauthorized
3386
+ */
3387
+ 401: {
3388
+ error: string;
3389
+ };
3390
+ /**
3391
+ * Forbidden
3392
+ */
3393
+ 403: {
3394
+ error: string;
3395
+ };
3396
+ /**
3397
+ * Not found
3398
+ */
3399
+ 404: {
3400
+ error: string;
3401
+ };
3402
+ };
3403
+ export type GoogleConnectError = GoogleConnectErrors[keyof GoogleConnectErrors];
3404
+ export type GoogleConnectResponses = {
3405
+ /**
3406
+ * Authorization URL for the user to visit
3407
+ */
3408
+ 200: GoogleWorkspaceOAuthStartResult;
3409
+ };
3410
+ export type GoogleConnectResponse = GoogleConnectResponses[keyof GoogleConnectResponses];
3104
3411
  export type McpListData = {
3105
3412
  body?: never;
3106
3413
  path?: never;
@@ -3140,14 +3447,19 @@ export type McpListResponse = McpListResponses[keyof McpListResponses];
3140
3447
  export type McpCreateData = {
3141
3448
  body?: {
3142
3449
  name: string;
3450
+ slug?: string;
3143
3451
  description?: string;
3144
3452
  icon?: string | null;
3145
- mcpServerUrl: string;
3453
+ mcpServerUrl?: string | null;
3146
3454
  docUrl?: string | null;
3147
3455
  type?: "remote" | "local";
3148
3456
  transport?: "streamable-http" | "sse" | "stdio";
3149
3457
  command?: string | null;
3150
3458
  args?: Array<string>;
3459
+ env?: {
3460
+ [key: string]: string;
3461
+ };
3462
+ requiredCredentials?: Array<RequiredCredential>;
3151
3463
  version?: string | null;
3152
3464
  repository?: Repository | null;
3153
3465
  tools?: Array<string>;
@@ -3332,6 +3644,10 @@ export type McpUpdateData = {
3332
3644
  transport?: "streamable-http" | "sse" | "stdio";
3333
3645
  command?: string | null;
3334
3646
  args?: Array<string>;
3647
+ env?: {
3648
+ [key: string]: string;
3649
+ };
3650
+ requiredCredentials?: Array<RequiredCredential>;
3335
3651
  version?: string | null;
3336
3652
  repository?: Repository | null;
3337
3653
  tools?: Array<string>;
@@ -6641,6 +6957,7 @@ export type SkillListResponses = {
6641
6957
  export type SkillListResponse = SkillListResponses[keyof SkillListResponses];
6642
6958
  export type SkillCreateData = {
6643
6959
  body: {
6960
+ slug?: string;
6644
6961
  name: string;
6645
6962
  description?: string;
6646
6963
  icon?: string;
@@ -7345,6 +7662,40 @@ export type SkillVersionArchiveResponses = {
7345
7662
  200: SkillVersion;
7346
7663
  };
7347
7664
  export type SkillVersionArchiveResponse = SkillVersionArchiveResponses[keyof SkillVersionArchiveResponses];
7665
+ export type TopologyGetData = {
7666
+ body?: never;
7667
+ path?: never;
7668
+ query?: never;
7669
+ url: "/api/topology";
7670
+ };
7671
+ export type TopologyGetErrors = {
7672
+ /**
7673
+ * Bad request
7674
+ */
7675
+ 400: {
7676
+ error: string;
7677
+ };
7678
+ /**
7679
+ * Unauthorized
7680
+ */
7681
+ 401: {
7682
+ error: string;
7683
+ };
7684
+ /**
7685
+ * Forbidden
7686
+ */
7687
+ 403: {
7688
+ error: string;
7689
+ };
7690
+ };
7691
+ export type TopologyGetError = TopologyGetErrors[keyof TopologyGetErrors];
7692
+ export type TopologyGetResponses = {
7693
+ /**
7694
+ * Agent-stack topology
7695
+ */
7696
+ 200: Topology;
7697
+ };
7698
+ export type TopologyGetResponse = TopologyGetResponses[keyof TopologyGetResponses];
7348
7699
  export type TriggerListData = {
7349
7700
  body?: never;
7350
7701
  path?: never;