@gopherhole/sdk 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -355,6 +355,10 @@ declare class GopherHole extends EventEmitter<EventMap> {
355
355
  * Discover public agents with comprehensive search
356
356
  */
357
357
  discover(options?: DiscoverOptions): Promise<DiscoverResult>;
358
+ /**
359
+ * Discover all agents in your tenant (no limit)
360
+ */
361
+ discoverTenantAgents(): Promise<DiscoverResult>;
358
362
  /**
359
363
  * Search agents with fuzzy matching on description
360
364
  */
@@ -430,10 +434,12 @@ interface DiscoverOptions {
430
434
  contentMode?: string;
431
435
  /** Sort order */
432
436
  sort?: 'rating' | 'popular' | 'recent';
433
- /** Max results (default 20, max 100) */
437
+ /** Max results (default 20, max 100; ignored when scope=tenant) */
434
438
  limit?: number;
435
439
  /** Pagination offset */
436
440
  offset?: number;
441
+ /** Scope: 'tenant' returns only same-tenant agents with no limit */
442
+ scope?: 'tenant';
437
443
  }
438
444
  interface DiscoverResult {
439
445
  agents: PublicAgent[];
package/dist/index.d.ts CHANGED
@@ -355,6 +355,10 @@ declare class GopherHole extends EventEmitter<EventMap> {
355
355
  * Discover public agents with comprehensive search
356
356
  */
357
357
  discover(options?: DiscoverOptions): Promise<DiscoverResult>;
358
+ /**
359
+ * Discover all agents in your tenant (no limit)
360
+ */
361
+ discoverTenantAgents(): Promise<DiscoverResult>;
358
362
  /**
359
363
  * Search agents with fuzzy matching on description
360
364
  */
@@ -430,10 +434,12 @@ interface DiscoverOptions {
430
434
  contentMode?: string;
431
435
  /** Sort order */
432
436
  sort?: 'rating' | 'popular' | 'recent';
433
- /** Max results (default 20, max 100) */
437
+ /** Max results (default 20, max 100; ignored when scope=tenant) */
434
438
  limit?: number;
435
439
  /** Pagination offset */
436
440
  offset?: number;
441
+ /** Scope: 'tenant' returns only same-tenant agents with no limit */
442
+ scope?: 'tenant';
437
443
  }
438
444
  interface DiscoverResult {
439
445
  agents: PublicAgent[];
package/dist/index.js CHANGED
@@ -315,6 +315,7 @@ var GopherHole = class extends import_eventemitter3.EventEmitter {
315
315
  if (options?.sort) params.set("sort", options.sort);
316
316
  if (options?.limit) params.set("limit", String(options.limit));
317
317
  if (options?.offset) params.set("offset", String(options.offset));
318
+ if (options?.scope) params.set("scope", options.scope);
318
319
  const response = await fetch(`${this.apiUrl}/api/discover/agents?${params}`, {
319
320
  headers: {
320
321
  "Authorization": `Bearer ${this.apiKey}`
@@ -322,6 +323,12 @@ var GopherHole = class extends import_eventemitter3.EventEmitter {
322
323
  });
323
324
  return response.json();
324
325
  }
326
+ /**
327
+ * Discover all agents in your tenant (no limit)
328
+ */
329
+ async discoverTenantAgents() {
330
+ return this.discover({ scope: "tenant" });
331
+ }
325
332
  /**
326
333
  * Search agents with fuzzy matching on description
327
334
  */
package/dist/index.mjs CHANGED
@@ -296,6 +296,7 @@ var GopherHole = class extends EventEmitter {
296
296
  if (options?.sort) params.set("sort", options.sort);
297
297
  if (options?.limit) params.set("limit", String(options.limit));
298
298
  if (options?.offset) params.set("offset", String(options.offset));
299
+ if (options?.scope) params.set("scope", options.scope);
299
300
  const response = await fetch(`${this.apiUrl}/api/discover/agents?${params}`, {
300
301
  headers: {
301
302
  "Authorization": `Bearer ${this.apiKey}`
@@ -303,6 +304,12 @@ var GopherHole = class extends EventEmitter {
303
304
  });
304
305
  return response.json();
305
306
  }
307
+ /**
308
+ * Discover all agents in your tenant (no limit)
309
+ */
310
+ async discoverTenantAgents() {
311
+ return this.discover({ scope: "tenant" });
312
+ }
306
313
  /**
307
314
  * Search agents with fuzzy matching on description
308
315
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gopherhole/sdk",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "GopherHole SDK - Connect AI agents via the A2A protocol",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
package/src/index.ts CHANGED
@@ -429,6 +429,7 @@ export class GopherHole extends EventEmitter<EventMap> {
429
429
  if (options?.sort) params.set('sort', options.sort);
430
430
  if (options?.limit) params.set('limit', String(options.limit));
431
431
  if (options?.offset) params.set('offset', String(options.offset));
432
+ if (options?.scope) params.set('scope', options.scope);
432
433
 
433
434
  // Include API key to see same-tenant agents (not just public)
434
435
  const response = await fetch(`${this.apiUrl}/api/discover/agents?${params}`, {
@@ -439,6 +440,13 @@ export class GopherHole extends EventEmitter<EventMap> {
439
440
  return response.json();
440
441
  }
441
442
 
443
+ /**
444
+ * Discover all agents in your tenant (no limit)
445
+ */
446
+ async discoverTenantAgents(): Promise<DiscoverResult> {
447
+ return this.discover({ scope: 'tenant' });
448
+ }
449
+
442
450
  /**
443
451
  * Search agents with fuzzy matching on description
444
452
  */
@@ -603,10 +611,12 @@ export interface DiscoverOptions {
603
611
  contentMode?: string;
604
612
  /** Sort order */
605
613
  sort?: 'rating' | 'popular' | 'recent';
606
- /** Max results (default 20, max 100) */
614
+ /** Max results (default 20, max 100; ignored when scope=tenant) */
607
615
  limit?: number;
608
616
  /** Pagination offset */
609
617
  offset?: number;
618
+ /** Scope: 'tenant' returns only same-tenant agents with no limit */
619
+ scope?: 'tenant';
610
620
  }
611
621
 
612
622
  export interface DiscoverResult {