@agentforge-io/sdk-server 4.24.0 → 4.25.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.
@@ -21,8 +21,14 @@ export declare class ConnectorsResource {
21
21
  * Drive…). Si el connector está conectado pero no tiene selector
22
22
  * implementado todavía, devuelve `{ items: [], unsupported: true }` en vez
23
23
  * de tirar — no es un error, es un estado a mostrar en la UI.
24
+ *
25
+ * `opts.q` (AGF-SHEETS-SEARCH) busca por nombre en Google Drive / Sheets
26
+ * (los demás connectors lo ignoran). Con un grant de Sheets sin
27
+ * `drive.readonly` el resultado trae `limited: true`.
24
28
  */
25
- listResources(connectorId: string): Promise<ListConnectorResourcesResult>;
29
+ listResources(connectorId: string, opts?: {
30
+ q?: string;
31
+ }): Promise<ListConnectorResourcesResult>;
26
32
  /**
27
33
  * `POST /connectors/oauth/:id/authorize-for-tenant` — arranca el OAuth
28
34
  * authorize del connector para el tenant del ak_live_ (sin sesión de
@@ -37,9 +37,14 @@ class ConnectorsResource {
37
37
  * Drive…). Si el connector está conectado pero no tiene selector
38
38
  * implementado todavía, devuelve `{ items: [], unsupported: true }` en vez
39
39
  * de tirar — no es un error, es un estado a mostrar en la UI.
40
+ *
41
+ * `opts.q` (AGF-SHEETS-SEARCH) busca por nombre en Google Drive / Sheets
42
+ * (los demás connectors lo ignoran). Con un grant de Sheets sin
43
+ * `drive.readonly` el resultado trae `limited: true`.
40
44
  */
41
- async listResources(connectorId) {
42
- return this.client.requestWithApiKey('GET', `/connector-resources/${encodeURIComponent(connectorId)}`);
45
+ async listResources(connectorId, opts) {
46
+ const q = opts?.q?.trim();
47
+ return this.client.requestWithApiKey('GET', `/connector-resources/${encodeURIComponent(connectorId)}${q ? `?q=${encodeURIComponent(q)}` : ''}`);
43
48
  }
44
49
  /**
45
50
  * `POST /connectors/oauth/:id/authorize-for-tenant` — arranca el OAuth
package/dist/types.d.ts CHANGED
@@ -460,6 +460,10 @@ export interface ListConnectorResourcesResult {
460
460
  * `items` igual trae lo que SÍ se pudo listar (ej. los canales); la UI
461
461
  * debe ofrecer un CTA de reconectar en vez de tratarlo como error. */
462
462
  needsReconnectForDms?: true;
463
+ /** AGF-SHEETS-SEARCH: el grant de Google no puede listar todo el Drive (sin
464
+ * `drive.readonly`); `items` solo trae archivos que la app ya recibió (creados
465
+ * por ella o elegidos en el selector de Google). Ofrecer el selector o reconectar. */
466
+ limited?: true;
463
467
  }
464
468
  export interface CreateClickupTaskInput {
465
469
  /** Id de la lista de ClickUp (`ConnectorResourceItem.id` del picker). */
@@ -1248,8 +1252,10 @@ export interface CatalogImportSource {
1248
1252
  url?: string | null;
1249
1253
  columnMapping: CatalogImportColumnMapping;
1250
1254
  /** Per-connector extras, e.g. `{ shop: 'acme.myshopify.com' }`. */
1255
+ /** `linked`: a Google Sheet synced both ways with the catalog (AGF-SHEET-LIVE-SOURCE). */
1251
1256
  config: {
1252
1257
  shop?: string;
1258
+ linked?: boolean;
1253
1259
  };
1254
1260
  currency?: string | null;
1255
1261
  /** Cron string; null = manual only. */
@@ -1275,6 +1281,7 @@ export interface CreateCatalogImportSourceInput {
1275
1281
  columnMapping?: CatalogImportColumnMapping;
1276
1282
  config?: {
1277
1283
  shop?: string;
1284
+ linked?: boolean;
1278
1285
  };
1279
1286
  currency?: string;
1280
1287
  schedule?: string | null;
@@ -1293,6 +1300,7 @@ export interface UpdateCatalogImportSourceInput {
1293
1300
  columnMapping?: CatalogImportColumnMapping;
1294
1301
  config?: {
1295
1302
  shop?: string;
1303
+ linked?: boolean;
1296
1304
  };
1297
1305
  currency?: string | null;
1298
1306
  schedule?: string | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentforge-io/sdk-server",
3
- "version": "4.24.0",
3
+ "version": "4.25.0",
4
4
  "description": "Server-side SDK for backend apps integrating with AgentForge platform. Auth via ChatToken, ak_live_ API key or App secret (sk_live_), with App installations across tenants.",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",