@z3rno/sdk 0.8.0 → 0.8.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/dist/index.cjs +10 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +85 -3
- package/dist/index.d.ts +85 -3
- package/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -378,7 +378,7 @@ type ForgetResponse = z.infer<typeof ForgetResponse>;
|
|
|
378
378
|
*
|
|
379
379
|
* Audit entries record every operation performed on the agent's memories.
|
|
380
380
|
*/
|
|
381
|
-
declare const AuditEntry: z.ZodObject<{
|
|
381
|
+
declare const AuditEntry: z.ZodEffects<z.ZodObject<{
|
|
382
382
|
/** Auto-incrementing audit entry ID. */
|
|
383
383
|
id: z.ZodNumber;
|
|
384
384
|
/** UUID of the agent, if applicable. */
|
|
@@ -417,6 +417,28 @@ declare const AuditEntry: z.ZodObject<{
|
|
|
417
417
|
user_id?: string | null | undefined;
|
|
418
418
|
details?: Record<string, unknown> | undefined;
|
|
419
419
|
ip_address?: string | null | undefined;
|
|
420
|
+
}>, {
|
|
421
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
422
|
+
timestamp: string;
|
|
423
|
+
id: number;
|
|
424
|
+
created_at: string;
|
|
425
|
+
operation: string;
|
|
426
|
+
details: Record<string, unknown>;
|
|
427
|
+
agent_id?: string | null | undefined;
|
|
428
|
+
memory_type?: string | null | undefined;
|
|
429
|
+
memory_id?: string | null | undefined;
|
|
430
|
+
user_id?: string | null | undefined;
|
|
431
|
+
ip_address?: string | null | undefined;
|
|
432
|
+
}, {
|
|
433
|
+
id: number;
|
|
434
|
+
created_at: string;
|
|
435
|
+
operation: string;
|
|
436
|
+
agent_id?: string | null | undefined;
|
|
437
|
+
memory_type?: string | null | undefined;
|
|
438
|
+
memory_id?: string | null | undefined;
|
|
439
|
+
user_id?: string | null | undefined;
|
|
440
|
+
details?: Record<string, unknown> | undefined;
|
|
441
|
+
ip_address?: string | null | undefined;
|
|
420
442
|
}>;
|
|
421
443
|
/** Parsed type for an audit entry. */
|
|
422
444
|
type AuditEntry = z.infer<typeof AuditEntry>;
|
|
@@ -425,9 +447,9 @@ type AuditEntry = z.infer<typeof AuditEntry>;
|
|
|
425
447
|
*
|
|
426
448
|
* Supports cursor-based pagination via `page` and `page_size`.
|
|
427
449
|
*/
|
|
428
|
-
declare const AuditPageResponse: z.ZodObject<{
|
|
450
|
+
declare const AuditPageResponse: z.ZodEffects<z.ZodObject<{
|
|
429
451
|
/** Audit entries on this page. */
|
|
430
|
-
entries: z.ZodArray<z.ZodObject<{
|
|
452
|
+
entries: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
431
453
|
/** Auto-incrementing audit entry ID. */
|
|
432
454
|
id: z.ZodNumber;
|
|
433
455
|
/** UUID of the agent, if applicable. */
|
|
@@ -466,6 +488,28 @@ declare const AuditPageResponse: z.ZodObject<{
|
|
|
466
488
|
user_id?: string | null | undefined;
|
|
467
489
|
details?: Record<string, unknown> | undefined;
|
|
468
490
|
ip_address?: string | null | undefined;
|
|
491
|
+
}>, {
|
|
492
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
493
|
+
timestamp: string;
|
|
494
|
+
id: number;
|
|
495
|
+
created_at: string;
|
|
496
|
+
operation: string;
|
|
497
|
+
details: Record<string, unknown>;
|
|
498
|
+
agent_id?: string | null | undefined;
|
|
499
|
+
memory_type?: string | null | undefined;
|
|
500
|
+
memory_id?: string | null | undefined;
|
|
501
|
+
user_id?: string | null | undefined;
|
|
502
|
+
ip_address?: string | null | undefined;
|
|
503
|
+
}, {
|
|
504
|
+
id: number;
|
|
505
|
+
created_at: string;
|
|
506
|
+
operation: string;
|
|
507
|
+
agent_id?: string | null | undefined;
|
|
508
|
+
memory_type?: string | null | undefined;
|
|
509
|
+
memory_id?: string | null | undefined;
|
|
510
|
+
user_id?: string | null | undefined;
|
|
511
|
+
details?: Record<string, unknown> | undefined;
|
|
512
|
+
ip_address?: string | null | undefined;
|
|
469
513
|
}>, "many">;
|
|
470
514
|
/** Total number of matching audit entries. */
|
|
471
515
|
total: z.ZodNumber;
|
|
@@ -477,6 +521,44 @@ declare const AuditPageResponse: z.ZodObject<{
|
|
|
477
521
|
has_next: z.ZodBoolean;
|
|
478
522
|
}, "strip", z.ZodTypeAny, {
|
|
479
523
|
entries: {
|
|
524
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
525
|
+
timestamp: string;
|
|
526
|
+
id: number;
|
|
527
|
+
created_at: string;
|
|
528
|
+
operation: string;
|
|
529
|
+
details: Record<string, unknown>;
|
|
530
|
+
agent_id?: string | null | undefined;
|
|
531
|
+
memory_type?: string | null | undefined;
|
|
532
|
+
memory_id?: string | null | undefined;
|
|
533
|
+
user_id?: string | null | undefined;
|
|
534
|
+
ip_address?: string | null | undefined;
|
|
535
|
+
}[];
|
|
536
|
+
total: number;
|
|
537
|
+
page: number;
|
|
538
|
+
page_size: number;
|
|
539
|
+
has_next: boolean;
|
|
540
|
+
}, {
|
|
541
|
+
entries: {
|
|
542
|
+
id: number;
|
|
543
|
+
created_at: string;
|
|
544
|
+
operation: string;
|
|
545
|
+
agent_id?: string | null | undefined;
|
|
546
|
+
memory_type?: string | null | undefined;
|
|
547
|
+
memory_id?: string | null | undefined;
|
|
548
|
+
user_id?: string | null | undefined;
|
|
549
|
+
details?: Record<string, unknown> | undefined;
|
|
550
|
+
ip_address?: string | null | undefined;
|
|
551
|
+
}[];
|
|
552
|
+
total: number;
|
|
553
|
+
page: number;
|
|
554
|
+
page_size: number;
|
|
555
|
+
has_next: boolean;
|
|
556
|
+
}>, {
|
|
557
|
+
/** Alias for `total`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
558
|
+
total_count: number;
|
|
559
|
+
entries: {
|
|
560
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
561
|
+
timestamp: string;
|
|
480
562
|
id: number;
|
|
481
563
|
created_at: string;
|
|
482
564
|
operation: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -378,7 +378,7 @@ type ForgetResponse = z.infer<typeof ForgetResponse>;
|
|
|
378
378
|
*
|
|
379
379
|
* Audit entries record every operation performed on the agent's memories.
|
|
380
380
|
*/
|
|
381
|
-
declare const AuditEntry: z.ZodObject<{
|
|
381
|
+
declare const AuditEntry: z.ZodEffects<z.ZodObject<{
|
|
382
382
|
/** Auto-incrementing audit entry ID. */
|
|
383
383
|
id: z.ZodNumber;
|
|
384
384
|
/** UUID of the agent, if applicable. */
|
|
@@ -417,6 +417,28 @@ declare const AuditEntry: z.ZodObject<{
|
|
|
417
417
|
user_id?: string | null | undefined;
|
|
418
418
|
details?: Record<string, unknown> | undefined;
|
|
419
419
|
ip_address?: string | null | undefined;
|
|
420
|
+
}>, {
|
|
421
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
422
|
+
timestamp: string;
|
|
423
|
+
id: number;
|
|
424
|
+
created_at: string;
|
|
425
|
+
operation: string;
|
|
426
|
+
details: Record<string, unknown>;
|
|
427
|
+
agent_id?: string | null | undefined;
|
|
428
|
+
memory_type?: string | null | undefined;
|
|
429
|
+
memory_id?: string | null | undefined;
|
|
430
|
+
user_id?: string | null | undefined;
|
|
431
|
+
ip_address?: string | null | undefined;
|
|
432
|
+
}, {
|
|
433
|
+
id: number;
|
|
434
|
+
created_at: string;
|
|
435
|
+
operation: string;
|
|
436
|
+
agent_id?: string | null | undefined;
|
|
437
|
+
memory_type?: string | null | undefined;
|
|
438
|
+
memory_id?: string | null | undefined;
|
|
439
|
+
user_id?: string | null | undefined;
|
|
440
|
+
details?: Record<string, unknown> | undefined;
|
|
441
|
+
ip_address?: string | null | undefined;
|
|
420
442
|
}>;
|
|
421
443
|
/** Parsed type for an audit entry. */
|
|
422
444
|
type AuditEntry = z.infer<typeof AuditEntry>;
|
|
@@ -425,9 +447,9 @@ type AuditEntry = z.infer<typeof AuditEntry>;
|
|
|
425
447
|
*
|
|
426
448
|
* Supports cursor-based pagination via `page` and `page_size`.
|
|
427
449
|
*/
|
|
428
|
-
declare const AuditPageResponse: z.ZodObject<{
|
|
450
|
+
declare const AuditPageResponse: z.ZodEffects<z.ZodObject<{
|
|
429
451
|
/** Audit entries on this page. */
|
|
430
|
-
entries: z.ZodArray<z.ZodObject<{
|
|
452
|
+
entries: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
431
453
|
/** Auto-incrementing audit entry ID. */
|
|
432
454
|
id: z.ZodNumber;
|
|
433
455
|
/** UUID of the agent, if applicable. */
|
|
@@ -466,6 +488,28 @@ declare const AuditPageResponse: z.ZodObject<{
|
|
|
466
488
|
user_id?: string | null | undefined;
|
|
467
489
|
details?: Record<string, unknown> | undefined;
|
|
468
490
|
ip_address?: string | null | undefined;
|
|
491
|
+
}>, {
|
|
492
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
493
|
+
timestamp: string;
|
|
494
|
+
id: number;
|
|
495
|
+
created_at: string;
|
|
496
|
+
operation: string;
|
|
497
|
+
details: Record<string, unknown>;
|
|
498
|
+
agent_id?: string | null | undefined;
|
|
499
|
+
memory_type?: string | null | undefined;
|
|
500
|
+
memory_id?: string | null | undefined;
|
|
501
|
+
user_id?: string | null | undefined;
|
|
502
|
+
ip_address?: string | null | undefined;
|
|
503
|
+
}, {
|
|
504
|
+
id: number;
|
|
505
|
+
created_at: string;
|
|
506
|
+
operation: string;
|
|
507
|
+
agent_id?: string | null | undefined;
|
|
508
|
+
memory_type?: string | null | undefined;
|
|
509
|
+
memory_id?: string | null | undefined;
|
|
510
|
+
user_id?: string | null | undefined;
|
|
511
|
+
details?: Record<string, unknown> | undefined;
|
|
512
|
+
ip_address?: string | null | undefined;
|
|
469
513
|
}>, "many">;
|
|
470
514
|
/** Total number of matching audit entries. */
|
|
471
515
|
total: z.ZodNumber;
|
|
@@ -477,6 +521,44 @@ declare const AuditPageResponse: z.ZodObject<{
|
|
|
477
521
|
has_next: z.ZodBoolean;
|
|
478
522
|
}, "strip", z.ZodTypeAny, {
|
|
479
523
|
entries: {
|
|
524
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
525
|
+
timestamp: string;
|
|
526
|
+
id: number;
|
|
527
|
+
created_at: string;
|
|
528
|
+
operation: string;
|
|
529
|
+
details: Record<string, unknown>;
|
|
530
|
+
agent_id?: string | null | undefined;
|
|
531
|
+
memory_type?: string | null | undefined;
|
|
532
|
+
memory_id?: string | null | undefined;
|
|
533
|
+
user_id?: string | null | undefined;
|
|
534
|
+
ip_address?: string | null | undefined;
|
|
535
|
+
}[];
|
|
536
|
+
total: number;
|
|
537
|
+
page: number;
|
|
538
|
+
page_size: number;
|
|
539
|
+
has_next: boolean;
|
|
540
|
+
}, {
|
|
541
|
+
entries: {
|
|
542
|
+
id: number;
|
|
543
|
+
created_at: string;
|
|
544
|
+
operation: string;
|
|
545
|
+
agent_id?: string | null | undefined;
|
|
546
|
+
memory_type?: string | null | undefined;
|
|
547
|
+
memory_id?: string | null | undefined;
|
|
548
|
+
user_id?: string | null | undefined;
|
|
549
|
+
details?: Record<string, unknown> | undefined;
|
|
550
|
+
ip_address?: string | null | undefined;
|
|
551
|
+
}[];
|
|
552
|
+
total: number;
|
|
553
|
+
page: number;
|
|
554
|
+
page_size: number;
|
|
555
|
+
has_next: boolean;
|
|
556
|
+
}>, {
|
|
557
|
+
/** Alias for `total`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
558
|
+
total_count: number;
|
|
559
|
+
entries: {
|
|
560
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
561
|
+
timestamp: string;
|
|
480
562
|
id: number;
|
|
481
563
|
created_at: string;
|
|
482
564
|
operation: string;
|
package/dist/index.js
CHANGED
|
@@ -276,7 +276,11 @@ var AuditEntry = z.object({
|
|
|
276
276
|
ip_address: z.string().nullable().optional(),
|
|
277
277
|
/** ISO 8601 timestamp of the operation. */
|
|
278
278
|
created_at: z.string()
|
|
279
|
-
})
|
|
279
|
+
}).transform((data) => ({
|
|
280
|
+
...data,
|
|
281
|
+
/** Alias for `created_at`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
282
|
+
timestamp: data.created_at
|
|
283
|
+
}));
|
|
280
284
|
var AuditPageResponse = z.object({
|
|
281
285
|
/** Audit entries on this page. */
|
|
282
286
|
entries: z.array(AuditEntry),
|
|
@@ -288,7 +292,11 @@ var AuditPageResponse = z.object({
|
|
|
288
292
|
page_size: z.number(),
|
|
289
293
|
/** Whether more pages are available. */
|
|
290
294
|
has_next: z.boolean()
|
|
291
|
-
})
|
|
295
|
+
}).transform((data) => ({
|
|
296
|
+
...data,
|
|
297
|
+
/** Alias for `total`. Added in v0.8.1 for cross-SDK naming parity. */
|
|
298
|
+
total_count: data.total
|
|
299
|
+
}));
|
|
292
300
|
var BatchStoreResponse = z.object({
|
|
293
301
|
/** Array of stored memory objects. */
|
|
294
302
|
results: z.array(MemoryResponse),
|