cencori 1.6.1 → 1.7.1
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/README.md +54 -0
- package/dist/ai/index.d.mts +1 -1
- package/dist/ai/index.d.ts +1 -1
- package/dist/compute/index.d.mts +1 -1
- package/dist/compute/index.d.ts +1 -1
- package/dist/documents/index.d.mts +1 -1
- package/dist/documents/index.d.ts +1 -1
- package/dist/index.d.mts +561 -3
- package/dist/index.d.ts +561 -3
- package/dist/index.js +685 -179
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +668 -179
- package/dist/index.mjs.map +1 -1
- package/dist/memory/index.d.mts +1 -1
- package/dist/memory/index.d.ts +1 -1
- package/dist/storage/index.d.mts +1 -1
- package/dist/storage/index.d.ts +1 -1
- package/dist/telemetry/index.d.mts +1 -1
- package/dist/telemetry/index.d.ts +1 -1
- package/dist/{types-kh1whvNH.d.mts → types-xSwLRBZw.d.mts} +17 -2
- package/dist/{types-kh1whvNH.d.ts → types-xSwLRBZw.d.ts} +17 -2
- package/dist/vision/index.d.mts +1 -1
- package/dist/vision/index.d.ts +1 -1
- package/dist/voice/index.d.mts +1 -1
- package/dist/voice/index.d.ts +1 -1
- package/dist/web/index.d.mts +3 -3
- package/dist/web/index.d.ts +3 -3
- package/dist/web/index.js +1 -1
- package/dist/web/index.js.map +1 -1
- package/dist/web/index.mjs +1 -1
- package/dist/web/index.mjs.map +1 -1
- package/dist/workflow/index.d.mts +1 -1
- package/dist/workflow/index.d.ts +1 -1
- package/package.json +7 -3
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CencoriConfig, i as RequestOptions } from './types-
|
|
2
|
-
export { j as ChatMessage, a as ChatRequest, b as ChatResponse, o as CodeInterpreterTool, c as CompletionRequest, E as EmbeddingRequest, d as EmbeddingResponse, F as FileSearchTool, l as ResponseInputItem, k as ResponsesOutputItem, R as ResponsesRequest, g as ResponsesResponse, m as ResponsesTool, U as UrlCitation, n as WebSearchTool } from './types-
|
|
1
|
+
import { C as CencoriConfig, i as RequestOptions } from './types-xSwLRBZw.js';
|
|
2
|
+
export { j as ChatMessage, a as ChatRequest, b as ChatResponse, o as CodeInterpreterTool, c as CompletionRequest, E as EmbeddingRequest, d as EmbeddingResponse, F as FileSearchTool, l as ResponseInputItem, k as ResponsesOutputItem, R as ResponsesRequest, g as ResponsesResponse, m as ResponsesTool, U as UrlCitation, n as WebSearchTool } from './types-xSwLRBZw.js';
|
|
3
3
|
import { AINamespace } from './ai/index.js';
|
|
4
4
|
export { StreamChunk } from './ai/index.js';
|
|
5
5
|
import { VisionNamespace } from './vision/index.js';
|
|
@@ -103,6 +103,9 @@ interface Session {
|
|
|
103
103
|
created_at: string;
|
|
104
104
|
updated_at: string;
|
|
105
105
|
agent_id: string | null;
|
|
106
|
+
tenant_id: string | null;
|
|
107
|
+
external_user_id: string | null;
|
|
108
|
+
installation_id: string | null;
|
|
106
109
|
metadata: Record<string, unknown>;
|
|
107
110
|
total_cost: number;
|
|
108
111
|
}
|
|
@@ -117,6 +120,9 @@ interface SessionEvent {
|
|
|
117
120
|
}
|
|
118
121
|
interface CreateSessionParams {
|
|
119
122
|
agent_id?: string;
|
|
123
|
+
tenant_id?: string;
|
|
124
|
+
external_user_id?: string;
|
|
125
|
+
installation_id?: string;
|
|
120
126
|
metadata?: Record<string, unknown>;
|
|
121
127
|
}
|
|
122
128
|
interface TurnParams {
|
|
@@ -156,6 +162,7 @@ interface SessionListParams {
|
|
|
156
162
|
limit?: number;
|
|
157
163
|
status?: 'active' | 'paused' | 'completed' | 'failed';
|
|
158
164
|
agent_id?: string;
|
|
165
|
+
tenant_id?: string;
|
|
159
166
|
}
|
|
160
167
|
declare class SessionsNamespace {
|
|
161
168
|
private config;
|
|
@@ -310,6 +317,539 @@ declare class ChatNamespace {
|
|
|
310
317
|
constructor(config: Required<CencoriConfig>);
|
|
311
318
|
}
|
|
312
319
|
|
|
320
|
+
interface Tenant {
|
|
321
|
+
id: string;
|
|
322
|
+
external_id: string;
|
|
323
|
+
name: string;
|
|
324
|
+
status: string;
|
|
325
|
+
region: string | null;
|
|
326
|
+
metadata: Record<string, unknown>;
|
|
327
|
+
created_at: string;
|
|
328
|
+
updated_at: string;
|
|
329
|
+
}
|
|
330
|
+
declare class TenantsNamespace {
|
|
331
|
+
private config;
|
|
332
|
+
constructor(config: Required<CencoriConfig>);
|
|
333
|
+
create(params: {
|
|
334
|
+
external_id: string;
|
|
335
|
+
name: string;
|
|
336
|
+
region?: string;
|
|
337
|
+
metadata?: Record<string, unknown>;
|
|
338
|
+
}, idempotencyKey?: string): Promise<Tenant>;
|
|
339
|
+
list(params?: {
|
|
340
|
+
limit?: number;
|
|
341
|
+
cursor?: string;
|
|
342
|
+
status?: string;
|
|
343
|
+
}): Promise<{
|
|
344
|
+
data: Tenant[];
|
|
345
|
+
next_cursor: string | null;
|
|
346
|
+
}>;
|
|
347
|
+
get(tenantId: string): Promise<Tenant>;
|
|
348
|
+
update(tenantId: string, params: {
|
|
349
|
+
name?: string;
|
|
350
|
+
metadata?: Record<string, unknown>;
|
|
351
|
+
region?: string | null;
|
|
352
|
+
}): Promise<Tenant>;
|
|
353
|
+
remove(tenantId: string): Promise<{
|
|
354
|
+
id: string;
|
|
355
|
+
status: string;
|
|
356
|
+
deleted?: Record<string, number>;
|
|
357
|
+
}>;
|
|
358
|
+
exportData(tenantId: string): Promise<{
|
|
359
|
+
tenant: Tenant;
|
|
360
|
+
users: unknown[];
|
|
361
|
+
exported_at: string;
|
|
362
|
+
}>;
|
|
363
|
+
upsertUser(tenantId: string, externalUserId: string, params?: {
|
|
364
|
+
display_name?: string;
|
|
365
|
+
roles?: string[];
|
|
366
|
+
groups?: string[];
|
|
367
|
+
metadata?: Record<string, unknown>;
|
|
368
|
+
}): Promise<unknown>;
|
|
369
|
+
getUser(tenantId: string, externalUserId: string): Promise<unknown>;
|
|
370
|
+
patchUser(tenantId: string, externalUserId: string, params: Record<string, unknown>): Promise<unknown>;
|
|
371
|
+
listUsers(tenantId: string): Promise<{
|
|
372
|
+
data: unknown[];
|
|
373
|
+
next_cursor: string | null;
|
|
374
|
+
}>;
|
|
375
|
+
deleteUser(tenantId: string, externalUserId: string, hard?: boolean): Promise<{
|
|
376
|
+
deleted: boolean;
|
|
377
|
+
}>;
|
|
378
|
+
}
|
|
379
|
+
declare class ClientTokensNamespace {
|
|
380
|
+
private config;
|
|
381
|
+
constructor(config: Required<CencoriConfig>);
|
|
382
|
+
mint(params: {
|
|
383
|
+
tenant_id: string;
|
|
384
|
+
external_user_id: string;
|
|
385
|
+
installation_ids?: string[];
|
|
386
|
+
permissions?: string[];
|
|
387
|
+
expires_in?: number;
|
|
388
|
+
session_id?: string;
|
|
389
|
+
}): Promise<{
|
|
390
|
+
token: string;
|
|
391
|
+
expires_at: string;
|
|
392
|
+
}>;
|
|
393
|
+
}
|
|
394
|
+
interface UnifiedModel {
|
|
395
|
+
id: string;
|
|
396
|
+
object: 'model';
|
|
397
|
+
created: number;
|
|
398
|
+
owned_by: string;
|
|
399
|
+
name: string;
|
|
400
|
+
type: string;
|
|
401
|
+
types: string[];
|
|
402
|
+
context_window: number;
|
|
403
|
+
provider: string;
|
|
404
|
+
source: 'cencori' | 'byok' | 'custom';
|
|
405
|
+
connection_id: string | null;
|
|
406
|
+
status: string;
|
|
407
|
+
available: boolean;
|
|
408
|
+
unavailable_reason: string | null;
|
|
409
|
+
}
|
|
410
|
+
declare class ModelsNamespace {
|
|
411
|
+
private config;
|
|
412
|
+
constructor(config: Required<CencoriConfig>);
|
|
413
|
+
list(params?: {
|
|
414
|
+
provider?: string;
|
|
415
|
+
type?: string;
|
|
416
|
+
available?: boolean;
|
|
417
|
+
source?: string;
|
|
418
|
+
connection_id?: string;
|
|
419
|
+
}): Promise<{
|
|
420
|
+
object: string;
|
|
421
|
+
data: UnifiedModel[];
|
|
422
|
+
providers: unknown[];
|
|
423
|
+
}>;
|
|
424
|
+
}
|
|
425
|
+
declare class ProviderConnectionsNamespace {
|
|
426
|
+
private config;
|
|
427
|
+
constructor(config: Required<CencoriConfig>);
|
|
428
|
+
create(params: {
|
|
429
|
+
name: string;
|
|
430
|
+
provider: string;
|
|
431
|
+
api_format?: string;
|
|
432
|
+
base_url?: string;
|
|
433
|
+
api_key?: string;
|
|
434
|
+
}, idempotencyKey?: string): Promise<unknown>;
|
|
435
|
+
list(): Promise<{
|
|
436
|
+
data: unknown[];
|
|
437
|
+
next_cursor: string | null;
|
|
438
|
+
}>;
|
|
439
|
+
get(connectionId: string): Promise<unknown>;
|
|
440
|
+
update(connectionId: string, params: {
|
|
441
|
+
name?: string;
|
|
442
|
+
api_key?: string;
|
|
443
|
+
status?: string;
|
|
444
|
+
base_url?: string;
|
|
445
|
+
}): Promise<unknown>;
|
|
446
|
+
remove(connectionId: string): Promise<{
|
|
447
|
+
deleted: boolean;
|
|
448
|
+
}>;
|
|
449
|
+
validate(params: {
|
|
450
|
+
provider: string;
|
|
451
|
+
base_url?: string;
|
|
452
|
+
api_key?: string;
|
|
453
|
+
api_format?: string;
|
|
454
|
+
}): Promise<{
|
|
455
|
+
valid: boolean;
|
|
456
|
+
}>;
|
|
457
|
+
test(connectionId: string): Promise<unknown>;
|
|
458
|
+
previewSync(connectionId: string): Promise<{
|
|
459
|
+
id: string;
|
|
460
|
+
status: string;
|
|
461
|
+
counts: Record<string, number>;
|
|
462
|
+
}>;
|
|
463
|
+
getSync(connectionId: string, syncId: string): Promise<unknown>;
|
|
464
|
+
applySync(connectionId: string, syncId: string, idempotencyKey?: string): Promise<unknown>;
|
|
465
|
+
}
|
|
466
|
+
declare class AgentVersionsNamespace {
|
|
467
|
+
private config;
|
|
468
|
+
constructor(config: Required<CencoriConfig>);
|
|
469
|
+
create(agentId: string, params: {
|
|
470
|
+
version: string;
|
|
471
|
+
config?: Record<string, unknown>;
|
|
472
|
+
requirements?: Record<string, unknown>;
|
|
473
|
+
visibility?: string;
|
|
474
|
+
}): Promise<unknown>;
|
|
475
|
+
list(agentId: string, status?: string): Promise<{
|
|
476
|
+
data: unknown[];
|
|
477
|
+
next_cursor: string | null;
|
|
478
|
+
}>;
|
|
479
|
+
get(agentId: string, version: string): Promise<unknown>;
|
|
480
|
+
validate(agentId: string, version: string): Promise<unknown>;
|
|
481
|
+
submit(agentId: string, version: string): Promise<unknown>;
|
|
482
|
+
review(agentId: string, version: string, params: {
|
|
483
|
+
decision: 'approve' | 'reject';
|
|
484
|
+
reviewed_by?: string;
|
|
485
|
+
reason?: string;
|
|
486
|
+
visibility?: string;
|
|
487
|
+
}): Promise<unknown>;
|
|
488
|
+
publish(agentId: string, version: string): Promise<unknown>;
|
|
489
|
+
test(agentId: string, version: string, params?: {
|
|
490
|
+
input?: string;
|
|
491
|
+
test_connection_ids?: string[];
|
|
492
|
+
}): Promise<unknown>;
|
|
493
|
+
deprecate(agentId: string, version: string): Promise<unknown>;
|
|
494
|
+
retire(agentId: string, version: string): Promise<unknown>;
|
|
495
|
+
catalog(params?: {
|
|
496
|
+
visibility?: string;
|
|
497
|
+
agent_id?: string;
|
|
498
|
+
}): Promise<{
|
|
499
|
+
data: unknown[];
|
|
500
|
+
next_cursor: string | null;
|
|
501
|
+
}>;
|
|
502
|
+
}
|
|
503
|
+
declare class InstallationsNamespace {
|
|
504
|
+
private config;
|
|
505
|
+
constructor(config: Required<CencoriConfig>);
|
|
506
|
+
create(params: {
|
|
507
|
+
tenant_id: string;
|
|
508
|
+
agent_id: string;
|
|
509
|
+
version?: string;
|
|
510
|
+
update_channel?: string;
|
|
511
|
+
knowledge_base_ids?: string[];
|
|
512
|
+
connection_ids?: string[];
|
|
513
|
+
approval_policy?: Record<string, unknown>;
|
|
514
|
+
}): Promise<unknown>;
|
|
515
|
+
list(tenantId?: string): Promise<{
|
|
516
|
+
data: unknown[];
|
|
517
|
+
next_cursor: string | null;
|
|
518
|
+
}>;
|
|
519
|
+
get(installationId: string): Promise<unknown>;
|
|
520
|
+
update(installationId: string, params: Record<string, unknown>): Promise<unknown>;
|
|
521
|
+
remove(installationId: string): Promise<unknown>;
|
|
522
|
+
upgrade(installationId: string, params?: {
|
|
523
|
+
version?: string;
|
|
524
|
+
}): Promise<unknown>;
|
|
525
|
+
rollback(installationId: string): Promise<unknown>;
|
|
526
|
+
}
|
|
527
|
+
declare class RunsNamespace {
|
|
528
|
+
private config;
|
|
529
|
+
constructor(config: Required<CencoriConfig>);
|
|
530
|
+
create(agentId: string, params: {
|
|
531
|
+
installation_id?: string;
|
|
532
|
+
tenant_id?: string;
|
|
533
|
+
external_user_id?: string;
|
|
534
|
+
mode?: string;
|
|
535
|
+
input?: unknown;
|
|
536
|
+
response_format?: unknown;
|
|
537
|
+
session_id?: string;
|
|
538
|
+
}, idempotencyKey?: string): Promise<unknown>;
|
|
539
|
+
get(runId: string): Promise<unknown>;
|
|
540
|
+
events(runId: string, params?: {
|
|
541
|
+
after?: string;
|
|
542
|
+
limit?: number;
|
|
543
|
+
}): Promise<{
|
|
544
|
+
data: unknown[];
|
|
545
|
+
next_cursor: string | null;
|
|
546
|
+
}>;
|
|
547
|
+
cancel(runId: string): Promise<unknown>;
|
|
548
|
+
delegate(runId: string, params: {
|
|
549
|
+
agent_version_id: string;
|
|
550
|
+
input?: unknown;
|
|
551
|
+
installation_id?: string;
|
|
552
|
+
}, idempotencyKey?: string): Promise<unknown>;
|
|
553
|
+
}
|
|
554
|
+
declare class ActionsNamespace {
|
|
555
|
+
private config;
|
|
556
|
+
constructor(config: Required<CencoriConfig>);
|
|
557
|
+
create(params: {
|
|
558
|
+
tool: string;
|
|
559
|
+
arguments?: Record<string, unknown>;
|
|
560
|
+
run_id?: string;
|
|
561
|
+
session_id?: string;
|
|
562
|
+
tenant_id?: string;
|
|
563
|
+
approval_policy?: Record<string, unknown>;
|
|
564
|
+
}, idempotencyKey?: string): Promise<unknown>;
|
|
565
|
+
get(actionId: string): Promise<unknown>;
|
|
566
|
+
approve(actionId: string, params?: {
|
|
567
|
+
approved_by?: string;
|
|
568
|
+
}): Promise<unknown>;
|
|
569
|
+
reject(actionId: string, params?: {
|
|
570
|
+
rejected_by?: string;
|
|
571
|
+
reason?: string;
|
|
572
|
+
}): Promise<unknown>;
|
|
573
|
+
}
|
|
574
|
+
declare class KnowledgeNamespace {
|
|
575
|
+
private config;
|
|
576
|
+
constructor(config: Required<CencoriConfig>);
|
|
577
|
+
createBase(params: {
|
|
578
|
+
name: string;
|
|
579
|
+
tenant_id?: string;
|
|
580
|
+
scope_type?: string;
|
|
581
|
+
region?: string;
|
|
582
|
+
}): Promise<unknown>;
|
|
583
|
+
listBases(tenantId?: string): Promise<{
|
|
584
|
+
data: unknown[];
|
|
585
|
+
next_cursor: string | null;
|
|
586
|
+
}>;
|
|
587
|
+
getBase(kbId: string): Promise<unknown>;
|
|
588
|
+
updateBase(kbId: string, params: {
|
|
589
|
+
name?: string;
|
|
590
|
+
status?: string;
|
|
591
|
+
retention_policy?: Record<string, unknown>;
|
|
592
|
+
}): Promise<unknown>;
|
|
593
|
+
removeBase(kbId: string): Promise<{
|
|
594
|
+
deleted: boolean;
|
|
595
|
+
}>;
|
|
596
|
+
addInlineSource(kbId: string, text: string, metadata?: Record<string, unknown>): Promise<unknown>;
|
|
597
|
+
listSources(kbId: string): Promise<{
|
|
598
|
+
data: unknown[];
|
|
599
|
+
next_cursor: string | null;
|
|
600
|
+
}>;
|
|
601
|
+
getSource(kbId: string, sourceId: string): Promise<unknown>;
|
|
602
|
+
removeSource(kbId: string, sourceId: string): Promise<{
|
|
603
|
+
deleted: boolean;
|
|
604
|
+
}>;
|
|
605
|
+
syncSource(kbId: string, sourceId: string, text?: string): Promise<unknown>;
|
|
606
|
+
listGrants(kbId: string): Promise<{
|
|
607
|
+
data: unknown[];
|
|
608
|
+
next_cursor: string | null;
|
|
609
|
+
}>;
|
|
610
|
+
revokeGrant(kbId: string, grantId: string): Promise<{
|
|
611
|
+
deleted: boolean;
|
|
612
|
+
}>;
|
|
613
|
+
grant(kbId: string, params: {
|
|
614
|
+
subject_type: string;
|
|
615
|
+
subject_id: string;
|
|
616
|
+
permissions?: string[];
|
|
617
|
+
}): Promise<unknown>;
|
|
618
|
+
search(kbId: string, params: {
|
|
619
|
+
query: string;
|
|
620
|
+
top_k?: number;
|
|
621
|
+
installation_id?: string;
|
|
622
|
+
}): Promise<{
|
|
623
|
+
data: unknown[];
|
|
624
|
+
}>;
|
|
625
|
+
}
|
|
626
|
+
declare class SkillsNamespace {
|
|
627
|
+
private config;
|
|
628
|
+
constructor(config: Required<CencoriConfig>);
|
|
629
|
+
create(params: {
|
|
630
|
+
name: string;
|
|
631
|
+
slug?: string;
|
|
632
|
+
description?: string;
|
|
633
|
+
visibility?: string;
|
|
634
|
+
tenant_id?: string;
|
|
635
|
+
}): Promise<unknown>;
|
|
636
|
+
list(params?: {
|
|
637
|
+
visibility?: string;
|
|
638
|
+
tenant_id?: string;
|
|
639
|
+
}): Promise<{
|
|
640
|
+
data: unknown[];
|
|
641
|
+
next_cursor: string | null;
|
|
642
|
+
}>;
|
|
643
|
+
get(skillId: string): Promise<unknown>;
|
|
644
|
+
update(skillId: string, params: {
|
|
645
|
+
name?: string;
|
|
646
|
+
description?: string;
|
|
647
|
+
visibility?: string;
|
|
648
|
+
status?: string;
|
|
649
|
+
}): Promise<unknown>;
|
|
650
|
+
createVersion(skillId: string, params: {
|
|
651
|
+
version: string;
|
|
652
|
+
content?: string;
|
|
653
|
+
files?: Array<{
|
|
654
|
+
path?: string;
|
|
655
|
+
content?: string;
|
|
656
|
+
}>;
|
|
657
|
+
}): Promise<unknown>;
|
|
658
|
+
listVersions(skillId: string): Promise<{
|
|
659
|
+
data: unknown[];
|
|
660
|
+
next_cursor: string | null;
|
|
661
|
+
}>;
|
|
662
|
+
getVersion(skillId: string, version: string): Promise<unknown>;
|
|
663
|
+
publishVersion(skillId: string, version: string, params?: {
|
|
664
|
+
reviewed_by?: string;
|
|
665
|
+
}): Promise<unknown>;
|
|
666
|
+
deprecateVersion(skillId: string, version: string): Promise<unknown>;
|
|
667
|
+
}
|
|
668
|
+
declare class SkillImportsNamespace {
|
|
669
|
+
private config;
|
|
670
|
+
constructor(config: Required<CencoriConfig>);
|
|
671
|
+
stage(params: {
|
|
672
|
+
url?: string;
|
|
673
|
+
repository?: string;
|
|
674
|
+
text?: string;
|
|
675
|
+
files?: Array<{
|
|
676
|
+
path?: string;
|
|
677
|
+
content?: string;
|
|
678
|
+
}>;
|
|
679
|
+
tenant_id?: string;
|
|
680
|
+
}): Promise<unknown>;
|
|
681
|
+
get(importId: string): Promise<unknown>;
|
|
682
|
+
publish(importId: string, params: {
|
|
683
|
+
name?: string;
|
|
684
|
+
skill_id?: string;
|
|
685
|
+
visibility?: string;
|
|
686
|
+
version?: string;
|
|
687
|
+
reviewed_by?: string;
|
|
688
|
+
}): Promise<unknown>;
|
|
689
|
+
}
|
|
690
|
+
declare class ConnectionsNamespace {
|
|
691
|
+
private config;
|
|
692
|
+
constructor(config: Required<CencoriConfig>);
|
|
693
|
+
listConnectors(): Promise<{
|
|
694
|
+
data: unknown[];
|
|
695
|
+
next_cursor: string | null;
|
|
696
|
+
}>;
|
|
697
|
+
getConnector(connectorId: string): Promise<unknown>;
|
|
698
|
+
create(params: {
|
|
699
|
+
connector?: string;
|
|
700
|
+
owner_type?: string;
|
|
701
|
+
tenant_id?: string;
|
|
702
|
+
external_user_id?: string;
|
|
703
|
+
api_key?: string;
|
|
704
|
+
scopes?: string[];
|
|
705
|
+
}): Promise<unknown>;
|
|
706
|
+
list(tenantId?: string): Promise<{
|
|
707
|
+
data: unknown[];
|
|
708
|
+
next_cursor: string | null;
|
|
709
|
+
}>;
|
|
710
|
+
get(connectionId: string): Promise<unknown>;
|
|
711
|
+
update(connectionId: string, params: {
|
|
712
|
+
scopes?: string[];
|
|
713
|
+
metadata?: Record<string, unknown>;
|
|
714
|
+
}): Promise<unknown>;
|
|
715
|
+
remove(connectionId: string): Promise<unknown>;
|
|
716
|
+
authorize(connectionId: string, params: {
|
|
717
|
+
redirect_uri?: string;
|
|
718
|
+
scopes?: string[];
|
|
719
|
+
}): Promise<{
|
|
720
|
+
authorize_url: string;
|
|
721
|
+
state: string;
|
|
722
|
+
}>;
|
|
723
|
+
test(connectionId: string): Promise<unknown>;
|
|
724
|
+
refresh(connectionId: string): Promise<unknown>;
|
|
725
|
+
registerMcpServer(params: {
|
|
726
|
+
name: string;
|
|
727
|
+
url: string;
|
|
728
|
+
transport?: string;
|
|
729
|
+
tenant_id?: string;
|
|
730
|
+
}): Promise<unknown>;
|
|
731
|
+
mcpTools(serverId: string): Promise<{
|
|
732
|
+
tools: unknown[];
|
|
733
|
+
}>;
|
|
734
|
+
refreshMcpTools(serverId: string): Promise<unknown>;
|
|
735
|
+
}
|
|
736
|
+
declare class McpServersNamespace {
|
|
737
|
+
private config;
|
|
738
|
+
constructor(config: Required<CencoriConfig>);
|
|
739
|
+
list(tenantId?: string): Promise<{
|
|
740
|
+
data: unknown[];
|
|
741
|
+
next_cursor: string | null;
|
|
742
|
+
}>;
|
|
743
|
+
get(serverId: string): Promise<unknown>;
|
|
744
|
+
register(params: {
|
|
745
|
+
name: string;
|
|
746
|
+
url: string;
|
|
747
|
+
transport?: string;
|
|
748
|
+
tenant_id?: string;
|
|
749
|
+
auth_connection_id?: string;
|
|
750
|
+
}): Promise<unknown>;
|
|
751
|
+
update(serverId: string, params: {
|
|
752
|
+
name?: string;
|
|
753
|
+
url?: string;
|
|
754
|
+
status?: string;
|
|
755
|
+
auth_connection_id?: string | null;
|
|
756
|
+
}): Promise<unknown>;
|
|
757
|
+
remove(serverId: string): Promise<{
|
|
758
|
+
id: string;
|
|
759
|
+
status: string;
|
|
760
|
+
}>;
|
|
761
|
+
test(serverId: string): Promise<unknown>;
|
|
762
|
+
tools(serverId: string): Promise<{
|
|
763
|
+
tools: unknown[];
|
|
764
|
+
}>;
|
|
765
|
+
refreshTools(serverId: string): Promise<unknown>;
|
|
766
|
+
}
|
|
767
|
+
declare class WebhooksNamespace {
|
|
768
|
+
private config;
|
|
769
|
+
constructor(config: Required<CencoriConfig>);
|
|
770
|
+
create(params: {
|
|
771
|
+
name: string;
|
|
772
|
+
url: string;
|
|
773
|
+
events?: string[];
|
|
774
|
+
}): Promise<unknown>;
|
|
775
|
+
update(webhookId: string, params: {
|
|
776
|
+
name?: string;
|
|
777
|
+
url?: string;
|
|
778
|
+
events?: string[];
|
|
779
|
+
is_active?: boolean;
|
|
780
|
+
}): Promise<unknown>;
|
|
781
|
+
list(): Promise<{
|
|
782
|
+
data: unknown[];
|
|
783
|
+
next_cursor: string | null;
|
|
784
|
+
}>;
|
|
785
|
+
remove(webhookId: string): Promise<{
|
|
786
|
+
deleted: boolean;
|
|
787
|
+
}>;
|
|
788
|
+
deliveries(): Promise<{
|
|
789
|
+
data: unknown[];
|
|
790
|
+
next_cursor: string | null;
|
|
791
|
+
}>;
|
|
792
|
+
replay(deliveryId: string): Promise<unknown>;
|
|
793
|
+
}
|
|
794
|
+
declare class UsageNamespace {
|
|
795
|
+
private config;
|
|
796
|
+
constructor(config: Required<CencoriConfig>);
|
|
797
|
+
summary(params?: {
|
|
798
|
+
days?: number;
|
|
799
|
+
tenant_id?: string;
|
|
800
|
+
agent_id?: string;
|
|
801
|
+
}): Promise<{
|
|
802
|
+
totals: unknown;
|
|
803
|
+
groups: unknown[];
|
|
804
|
+
}>;
|
|
805
|
+
events(params?: {
|
|
806
|
+
days?: number;
|
|
807
|
+
tenant_id?: string;
|
|
808
|
+
agent_id?: string;
|
|
809
|
+
limit?: number;
|
|
810
|
+
cursor?: string;
|
|
811
|
+
}): Promise<{
|
|
812
|
+
data: unknown[];
|
|
813
|
+
next_cursor: string | null;
|
|
814
|
+
}>;
|
|
815
|
+
exportCsv(params?: {
|
|
816
|
+
days?: number;
|
|
817
|
+
tenant_id?: string;
|
|
818
|
+
agent_id?: string;
|
|
819
|
+
}): Promise<string>;
|
|
820
|
+
}
|
|
821
|
+
declare class EndUsersNamespace {
|
|
822
|
+
private config;
|
|
823
|
+
constructor(config: Required<CencoriConfig>);
|
|
824
|
+
list(limit?: number): Promise<{
|
|
825
|
+
data: unknown[];
|
|
826
|
+
next_cursor: string | null;
|
|
827
|
+
}>;
|
|
828
|
+
upsert(params: {
|
|
829
|
+
external_id: string;
|
|
830
|
+
display_name?: string;
|
|
831
|
+
email?: string;
|
|
832
|
+
rate_plan_id?: string | null;
|
|
833
|
+
is_blocked?: boolean;
|
|
834
|
+
metadata?: Record<string, unknown>;
|
|
835
|
+
}): Promise<unknown>;
|
|
836
|
+
}
|
|
837
|
+
declare class RatePlansNamespace {
|
|
838
|
+
private config;
|
|
839
|
+
constructor(config: Required<CencoriConfig>);
|
|
840
|
+
list(): Promise<{
|
|
841
|
+
data: unknown[];
|
|
842
|
+
next_cursor: string | null;
|
|
843
|
+
}>;
|
|
844
|
+
create(params: {
|
|
845
|
+
name: string;
|
|
846
|
+
slug?: string;
|
|
847
|
+
markup_percentage?: number;
|
|
848
|
+
flat_rate?: number;
|
|
849
|
+
currency?: string;
|
|
850
|
+
}): Promise<unknown>;
|
|
851
|
+
}
|
|
852
|
+
|
|
313
853
|
/**
|
|
314
854
|
* Cencori - Unified AI Infrastructure SDK
|
|
315
855
|
*
|
|
@@ -492,6 +1032,24 @@ declare class Cencori {
|
|
|
492
1032
|
* const results = await cencori.web.search({ query: 'authentication guide' });
|
|
493
1033
|
*/
|
|
494
1034
|
readonly web: WebNamespace;
|
|
1035
|
+
/** Embedded Agents - multi-tenant agent backend (tenants, versions, runs, knowledge). */
|
|
1036
|
+
readonly tenants: TenantsNamespace;
|
|
1037
|
+
readonly clientTokens: ClientTokensNamespace;
|
|
1038
|
+
readonly models: ModelsNamespace;
|
|
1039
|
+
readonly providerConnections: ProviderConnectionsNamespace;
|
|
1040
|
+
readonly agentVersions: AgentVersionsNamespace;
|
|
1041
|
+
readonly installations: InstallationsNamespace;
|
|
1042
|
+
readonly runs: RunsNamespace;
|
|
1043
|
+
readonly actions: ActionsNamespace;
|
|
1044
|
+
readonly knowledge: KnowledgeNamespace;
|
|
1045
|
+
readonly connections: ConnectionsNamespace;
|
|
1046
|
+
readonly mcpServers: McpServersNamespace;
|
|
1047
|
+
readonly skills: SkillsNamespace;
|
|
1048
|
+
readonly skillImports: SkillImportsNamespace;
|
|
1049
|
+
readonly webhooks: WebhooksNamespace;
|
|
1050
|
+
readonly usage: UsageNamespace;
|
|
1051
|
+
readonly endUsers: EndUsersNamespace;
|
|
1052
|
+
readonly ratePlans: RatePlansNamespace;
|
|
495
1053
|
/**
|
|
496
1054
|
* Create a new Cencori client
|
|
497
1055
|
*
|
|
@@ -563,4 +1121,4 @@ declare class SafetyError extends CencoriError {
|
|
|
563
1121
|
*/
|
|
564
1122
|
declare function fetchWithRetry(url: string, options: RequestInit, maxRetries?: number): Promise<Response>;
|
|
565
1123
|
|
|
566
|
-
export { AINamespace, type Agent, type AgentConfig, type AgentKey, type AgentListItem, AgentsNamespace, AuthenticationError, Cencori, CencoriConfig, CencoriError, type ChatCompletionChunk, type ChatCompletionCreateParams, type ChatCompletionResponse, type ChatCompletionStream, type ChatMemoryOptions, ChatNamespace, ComputeNamespace, type CreateAgentKeyParams, type CreateAgentParams, type CreateSessionParams, DocumentsNamespace, MemoryClient, type PaginatedResponse, RateLimitError, RequestOptions, SafetyError, type Session, type SessionEvent, type SessionListParams, SessionsNamespace, StorageNamespace, TelemetryClient, type TurnParams, type UpdateAgentParams, VisionNamespace, VoiceNamespace, WebNamespace, WorkflowNamespace, Cencori as default, fetchWithRetry };
|
|
1124
|
+
export { AINamespace, ActionsNamespace, type Agent, type AgentConfig, type AgentKey, type AgentListItem, AgentVersionsNamespace, AgentsNamespace, AuthenticationError, Cencori, CencoriConfig, CencoriError, type ChatCompletionChunk, type ChatCompletionCreateParams, type ChatCompletionResponse, type ChatCompletionStream, type ChatMemoryOptions, ChatNamespace, ClientTokensNamespace, ComputeNamespace, ConnectionsNamespace, type CreateAgentKeyParams, type CreateAgentParams, type CreateSessionParams, DocumentsNamespace, EndUsersNamespace, InstallationsNamespace, KnowledgeNamespace, McpServersNamespace, MemoryClient, ModelsNamespace, type PaginatedResponse, ProviderConnectionsNamespace, RateLimitError, RatePlansNamespace, RequestOptions, RunsNamespace, SafetyError, type Session, type SessionEvent, type SessionListParams, SessionsNamespace, SkillImportsNamespace, SkillsNamespace, StorageNamespace, TelemetryClient, type Tenant, TenantsNamespace, type TurnParams, type UnifiedModel, type UpdateAgentParams, UsageNamespace, VisionNamespace, VoiceNamespace, WebNamespace, WebhooksNamespace, WorkflowNamespace, Cencori as default, fetchWithRetry };
|