@maximem/synap-js-sdk 0.7.1 → 0.8.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.
package/dist/index.d.cts CHANGED
@@ -75,6 +75,11 @@ declare const ENDPOINTS: {
75
75
  readonly path: "/v1/data/delete";
76
76
  readonly idempotent: true;
77
77
  };
78
+ readonly data_restore: {
79
+ readonly method: "POST";
80
+ readonly path: "/v1/data/restore";
81
+ readonly idempotent: true;
82
+ };
78
83
  readonly data_delete_status: {
79
84
  readonly method: "GET";
80
85
  readonly path: "/v1/data/delete/{deletion_id}";
@@ -1095,6 +1100,36 @@ interface ForgetCandidate {
1095
1100
  store?: string;
1096
1101
  }
1097
1102
  type ForgetStatus = 'nothing_matches' | 'preview' | 'deleted' | 'partial';
1103
+ /**
1104
+ * Result of `memories.delete`. Mirrors the dict Python's `memories.delete` returns.
1105
+ * `fully_removed` is false unless the server said true: a store named in
1106
+ * `still_present_in` may still serve the text, so do not tell an end user it is gone.
1107
+ */
1108
+ interface DeleteMemoryResult {
1109
+ memory_id: string;
1110
+ deleted_at: string;
1111
+ fully_removed: boolean;
1112
+ still_present_in: string[];
1113
+ /** The source document stays because other memories still rest on it. */
1114
+ source_text_kept: boolean;
1115
+ /**
1116
+ * `pending_purge` (the default soft delete: hidden now, restorable with
1117
+ * `data.restore([id])` until `purge_after`), `complete` (a permanent delete
1118
+ * finished) or `partial`. `complete` from a server older than soft delete.
1119
+ */
1120
+ status: string;
1121
+ /** When a soft-deleted memory is purged (ISO 8601), or null. */
1122
+ purge_after: string | null;
1123
+ permanent: boolean;
1124
+ }
1125
+ /** Options of `memories.delete`. */
1126
+ interface DeleteMemoryOptions {
1127
+ /**
1128
+ * Remove it now, with no restore period. Needs a management-level key
1129
+ * (delete:permanent, delete:*, management:* or *).
1130
+ */
1131
+ permanent?: boolean;
1132
+ }
1098
1133
  /** Result of `memories.forget`. Mirrors Python's `ForgetResponse`. */
1099
1134
  interface ForgetResult {
1100
1135
  status: ForgetStatus;
@@ -1118,7 +1153,7 @@ interface MemoriesInterface {
1118
1153
  create_from_file(options: CreateFromFileOptions): Promise<CreateMemoryResult>;
1119
1154
  get(memoryId: string): Promise<Json>;
1120
1155
  update(options: UpdateMemoryOptions): Promise<Json>;
1121
- delete(memoryId: string): Promise<Json>;
1156
+ delete(memoryId: string, options?: DeleteMemoryOptions): Promise<DeleteMemoryResult>;
1122
1157
  /**
1123
1158
  * Forget memories by describing them in the user's own words. Use it when
1124
1159
  * you do not hold memory ids; to delete one memory by id, use `delete()`.
@@ -1419,11 +1454,27 @@ interface DeleteDataOptions {
1419
1454
  confirm?: string | null;
1420
1455
  /** Repeat the call while the server says `continue` (default true, max 50 calls). */
1421
1456
  wait?: boolean;
1457
+ /**
1458
+ * Delete in several instances of the client at once: `"all"` or a list of
1459
+ * instance ids. Needs a management key not bound to one instance (a bound key
1460
+ * may only name its own). Omit it to delete in this SDK's instance only.
1461
+ * Mirrors Python's `instances`.
1462
+ */
1463
+ instances?: 'all' | string[] | null;
1464
+ /**
1465
+ * Remove the memories now instead of after the deletion period. Needs a
1466
+ * management-level key (delete:permanent, delete:*, management:* or *).
1467
+ */
1468
+ permanent?: boolean;
1422
1469
  }
1423
1470
  /** Result of `data.delete` / `data.status`. Mirrors Python's `DeleteDataResult`. */
1424
1471
  interface DeleteDataResult {
1425
1472
  deletion_id: string | null;
1426
- /** `complete`, `partial`, `in_progress` or `dry_run`. */
1473
+ /**
1474
+ * `complete`, `pending_purge`, `partial`, `in_progress` or `dry_run`.
1475
+ * `pending_purge`: hidden from every read now, restorable with
1476
+ * `data.restore` until `purge_after`, then removed for good.
1477
+ */
1427
1478
  status: string;
1428
1479
  scope: string | null;
1429
1480
  dry_run: boolean;
@@ -1435,23 +1486,59 @@ interface DeleteDataResult {
1435
1486
  /** True when the server's size cap stopped the call. */
1436
1487
  continue: boolean;
1437
1488
  kept: string[];
1489
+ /**
1490
+ * Stores this delete does not reach at all, in plain words. `complete` means every
1491
+ * store the delete targets was cleared, not that nothing is left in these. Empty
1492
+ * from servers that predate the field.
1493
+ */
1494
+ not_covered: string[];
1438
1495
  note: string | null;
1439
1496
  memories_kept: boolean;
1440
1497
  audit: string | null;
1441
1498
  /** What the SDK cleared on this machine after the server finished. */
1442
1499
  local_cleared: string[];
1500
+ /** Only with `instances`: one result per instance, plus `instance_id`. */
1501
+ instances: Record<string, unknown>[];
1502
+ /** Only with `instances`: instances the time budget did not reach yet. */
1503
+ not_started: string[];
1504
+ /** Only with `instances`: every audit id. */
1505
+ deletion_ids: string[];
1506
+ /** With status `pending_purge`: when the deleted memories are purged (ISO 8601, UTC). */
1507
+ purge_after: string | null;
1508
+ [key: string]: unknown;
1509
+ }
1510
+ /** The most ids one `data.restore` call takes. Same as Python's MAX_RESTORE_IDS. */
1511
+ declare const MAX_RESTORE_IDS = 200;
1512
+ /** Result of `data.restore`. Mirrors Python's `RestoreResult`. */
1513
+ interface RestoreResult {
1514
+ /** Live again; served by the next fetch. */
1515
+ restored_ids: string[];
1516
+ /** Not found in this instance, not deleted, or past the purge date. */
1517
+ not_restorable_ids: string[];
1518
+ /** A store that could not be brought back in line; the memory is restored either way. */
1519
+ still_missing_in: string[];
1520
+ reindexed_ids: string[];
1521
+ fully_restored: boolean;
1443
1522
  [key: string]: unknown;
1444
1523
  }
1524
+ /** What to restore: memory ids, or every memory one `data.delete` hid. */
1525
+ interface RestoreOptions {
1526
+ memory_ids?: string[] | null;
1527
+ memoryIds?: string[] | null;
1528
+ /** The `deletion_id` of a `data.delete` result. Send exactly one of the two. */
1529
+ deletion_id?: string | null;
1530
+ deletionId?: string | null;
1531
+ }
1445
1532
  interface DataInterface {
1446
1533
  /**
1447
- * Delete data for one user, one conversation or one customer. Permanent.
1534
+ * Delete data for one user, one conversation or one customer. Memories are
1535
+ * soft-deleted (restorable until `purge_after`) unless `permanent` is true.
1448
1536
  * scope 'conversation' removes turns, summaries, telemetry and the turn buffer ONLY;
1449
1537
  * memories learned from it are kept (use scope 'user' or memories.delete). Data in
1450
1538
  * another instance is never touched; stores that cannot be scoped by instance are
1451
1539
  * skipped and named in still_present_in.
1452
1540
  *
1453
1541
  * scope 'customer' needs a management key (management:* or *); a runtime key gets 403.
1454
- * LLM call traces are not removed (llm_call_bodies up to 14 days, llm_calls up to 180 days).
1455
1542
  *
1456
1543
  * A store that could not be cleared is in `still_present_in` and
1457
1544
  * `fully_removed` is false; it is a result, not an exception. Errors:
@@ -1461,6 +1548,15 @@ interface DataInterface {
1461
1548
  delete(options: DeleteDataOptions): Promise<DeleteDataResult>;
1462
1549
  /** The audit record of a delete (status, counts, still_present_in). */
1463
1550
  status(deletionId: string): Promise<DeleteDataResult>;
1551
+ /**
1552
+ * Bring deleted memories back, until their purge date (the instance's deletion
1553
+ * period, 0 to 30 days, 30 by default). Pass up to 200 ids, or
1554
+ * `{ deletionId }` for every memory one `data.delete` hid. Needs the same key
1555
+ * permissions as delete and reaches only this instance's memories. Ids that
1556
+ * could not be restored are in `not_restorable_ids`; that is a result, not an
1557
+ * exception.
1558
+ */
1559
+ restore(target: string[] | RestoreOptions): Promise<RestoreResult>;
1464
1560
  }
1465
1561
 
1466
1562
  /** User namespace. Mirrors `UserInterface` in the Python SDK. */
@@ -2216,7 +2312,7 @@ declare class SynapClient {
2216
2312
  deleteMemory(options: {
2217
2313
  memoryId?: string;
2218
2314
  memory_id?: string;
2219
- }): Promise<Json>;
2315
+ }): Promise<DeleteMemoryResult>;
2220
2316
  /**
2221
2317
  * Resolve `client_id` and `instance_id` from the API key.
2222
2318
  *
@@ -2340,7 +2436,7 @@ declare class SynapClient {
2340
2436
  * build when the two disagree, which is the only thing that makes a manual
2341
2437
  * publish safe.
2342
2438
  */
2343
- declare const SDK_VERSION = "0.7.1";
2439
+ declare const SDK_VERSION = "0.8.0";
2344
2440
 
2345
2441
  /**
2346
2442
  * `response_shape: "ranked"`: one list in the order the server ranked it.
@@ -2581,4 +2677,4 @@ interface SynapSdkLike {
2581
2677
  };
2582
2678
  }
2583
2679
 
2584
- export { type AnthropicToolDefinition, AnticipationCacheSnapshot, type AsToolOptions, type AttachmentResult, BM25, type BatchCreateResult, COMPACTION_LEVELS, CONTRACT, type CacheNamespace, type CacheStats, type CompactOptions, type CompactionCallback, type CompactionLevel, type ConfigureOptions, type ContentPart, type ContextMetadata, type ConversationContext, type ConversationNamespace, type CreateDocument, type CreateFromFileOptions, type CreateMemoryOptions, type CreateMemoryResult, type Credentials, type CreditBalance, type CreditBucket, type CreditEstimate, type CreditLedgerEntry, type CreditLedgerPage, type CreditsNamespace, DATA_SCOPES, DEFAULT_BASE_URL, DEFAULT_DOCUMENT_TYPE, DEFAULT_INGEST_MODE, DEFAULT_RETRY_POLICY, DEFAULT_TIMEOUTS, DOCUMENT_TYPES, type DataInterface, type DataScope, type DeleteDataOptions, type DeleteDataResult, type DocumentType, ENDPOINTS, EXCERPT_CATEGORY, type Emotion, type EndpointName, type EndpointSpec, type Episode, type EstimateOptions, FORGET_MODES, type Fact, type FetchOptions, type FileData, type FilePart, type FilePartInit, type FlatMemory, type ForgetCandidate, type ForgetMode, type ForgetOptions, type ForgetResult, type ForgetStatus, type FormatOptions, HttpTransport, type HttpTransportOptions, INGEST_MODES, ITEM_COLLECTIONS, type IngestMode, type IngestTranscriptOptions, type InstanceNamespace, type ItemCollection, type Json, type LedgerOptions, type ListenOptions, MEMORY_TYPES, type MacaGenerateOptions, type MacaJob, type MacaNamespace, type MacaRelationship, type MacaWaitOptions, type MemoriesInterface, type NormalisedContext, OBJECTIVES, type Objective, type OpenAiToolDefinition, type Preference, RESPONSE_SHAPES, type RawContext, type RawContextItem, type RawConversationContext, type RecordMessageOptions, type RecordThinkingOptions, type RedeemResult, type RequestOptions, type ResponseShape, type RetryPolicy, SDK_VERSION, type Scope, ScopeAddress, ScopeLadder, type ScopeLevel, type SendMessageOptions, SynapClient, type SynapClientOptions, SynapError, type SynapLogLevel, type SynapLogger, type SynapSdkLike, THRESHOLDS, type TemporalEvent, type TemporalFields, type TextPart, type TimeoutConfig, type ToolDefinition, type ToolHandler, type ToolScope, type ToolStyle, type TranscriptIngestResult, type TranscriptTurn, type UnifiedContext, type UnifiedFetchOptions, type UpdateMemoryOptions, type UserNamespace, type WaitOptions, type WriteInvalidator, applyResponseShape, filePart, flattenContextItems, formatForPrompt, isOutcomeUnknown, mergeScopeResults, rankItems, resolvePath, shouldRetry, stem, textPart, tokenize, wireRankScore };
2680
+ export { type AnthropicToolDefinition, AnticipationCacheSnapshot, type AsToolOptions, type AttachmentResult, BM25, type BatchCreateResult, COMPACTION_LEVELS, CONTRACT, type CacheNamespace, type CacheStats, type CompactOptions, type CompactionCallback, type CompactionLevel, type ConfigureOptions, type ContentPart, type ContextMetadata, type ConversationContext, type ConversationNamespace, type CreateDocument, type CreateFromFileOptions, type CreateMemoryOptions, type CreateMemoryResult, type Credentials, type CreditBalance, type CreditBucket, type CreditEstimate, type CreditLedgerEntry, type CreditLedgerPage, type CreditsNamespace, DATA_SCOPES, DEFAULT_BASE_URL, DEFAULT_DOCUMENT_TYPE, DEFAULT_INGEST_MODE, DEFAULT_RETRY_POLICY, DEFAULT_TIMEOUTS, DOCUMENT_TYPES, type DataInterface, type DataScope, type DeleteDataOptions, type DeleteDataResult, type DeleteMemoryOptions, type DeleteMemoryResult, type DocumentType, ENDPOINTS, EXCERPT_CATEGORY, type Emotion, type EndpointName, type EndpointSpec, type Episode, type EstimateOptions, FORGET_MODES, type Fact, type FetchOptions, type FileData, type FilePart, type FilePartInit, type FlatMemory, type ForgetCandidate, type ForgetMode, type ForgetOptions, type ForgetResult, type ForgetStatus, type FormatOptions, HttpTransport, type HttpTransportOptions, INGEST_MODES, ITEM_COLLECTIONS, type IngestMode, type IngestTranscriptOptions, type InstanceNamespace, type ItemCollection, type Json, type LedgerOptions, type ListenOptions, MAX_RESTORE_IDS, MEMORY_TYPES, type MacaGenerateOptions, type MacaJob, type MacaNamespace, type MacaRelationship, type MacaWaitOptions, type MemoriesInterface, type NormalisedContext, OBJECTIVES, type Objective, type OpenAiToolDefinition, type Preference, RESPONSE_SHAPES, type RawContext, type RawContextItem, type RawConversationContext, type RecordMessageOptions, type RecordThinkingOptions, type RedeemResult, type RequestOptions, type ResponseShape, type RestoreOptions, type RestoreResult, type RetryPolicy, SDK_VERSION, type Scope, ScopeAddress, ScopeLadder, type ScopeLevel, type SendMessageOptions, SynapClient, type SynapClientOptions, SynapError, type SynapLogLevel, type SynapLogger, type SynapSdkLike, THRESHOLDS, type TemporalEvent, type TemporalFields, type TextPart, type TimeoutConfig, type ToolDefinition, type ToolHandler, type ToolScope, type ToolStyle, type TranscriptIngestResult, type TranscriptTurn, type UnifiedContext, type UnifiedFetchOptions, type UpdateMemoryOptions, type UserNamespace, type WaitOptions, type WriteInvalidator, applyResponseShape, filePart, flattenContextItems, formatForPrompt, isOutcomeUnknown, mergeScopeResults, rankItems, resolvePath, shouldRetry, stem, textPart, tokenize, wireRankScore };
package/dist/index.d.ts CHANGED
@@ -75,6 +75,11 @@ declare const ENDPOINTS: {
75
75
  readonly path: "/v1/data/delete";
76
76
  readonly idempotent: true;
77
77
  };
78
+ readonly data_restore: {
79
+ readonly method: "POST";
80
+ readonly path: "/v1/data/restore";
81
+ readonly idempotent: true;
82
+ };
78
83
  readonly data_delete_status: {
79
84
  readonly method: "GET";
80
85
  readonly path: "/v1/data/delete/{deletion_id}";
@@ -1095,6 +1100,36 @@ interface ForgetCandidate {
1095
1100
  store?: string;
1096
1101
  }
1097
1102
  type ForgetStatus = 'nothing_matches' | 'preview' | 'deleted' | 'partial';
1103
+ /**
1104
+ * Result of `memories.delete`. Mirrors the dict Python's `memories.delete` returns.
1105
+ * `fully_removed` is false unless the server said true: a store named in
1106
+ * `still_present_in` may still serve the text, so do not tell an end user it is gone.
1107
+ */
1108
+ interface DeleteMemoryResult {
1109
+ memory_id: string;
1110
+ deleted_at: string;
1111
+ fully_removed: boolean;
1112
+ still_present_in: string[];
1113
+ /** The source document stays because other memories still rest on it. */
1114
+ source_text_kept: boolean;
1115
+ /**
1116
+ * `pending_purge` (the default soft delete: hidden now, restorable with
1117
+ * `data.restore([id])` until `purge_after`), `complete` (a permanent delete
1118
+ * finished) or `partial`. `complete` from a server older than soft delete.
1119
+ */
1120
+ status: string;
1121
+ /** When a soft-deleted memory is purged (ISO 8601), or null. */
1122
+ purge_after: string | null;
1123
+ permanent: boolean;
1124
+ }
1125
+ /** Options of `memories.delete`. */
1126
+ interface DeleteMemoryOptions {
1127
+ /**
1128
+ * Remove it now, with no restore period. Needs a management-level key
1129
+ * (delete:permanent, delete:*, management:* or *).
1130
+ */
1131
+ permanent?: boolean;
1132
+ }
1098
1133
  /** Result of `memories.forget`. Mirrors Python's `ForgetResponse`. */
1099
1134
  interface ForgetResult {
1100
1135
  status: ForgetStatus;
@@ -1118,7 +1153,7 @@ interface MemoriesInterface {
1118
1153
  create_from_file(options: CreateFromFileOptions): Promise<CreateMemoryResult>;
1119
1154
  get(memoryId: string): Promise<Json>;
1120
1155
  update(options: UpdateMemoryOptions): Promise<Json>;
1121
- delete(memoryId: string): Promise<Json>;
1156
+ delete(memoryId: string, options?: DeleteMemoryOptions): Promise<DeleteMemoryResult>;
1122
1157
  /**
1123
1158
  * Forget memories by describing them in the user's own words. Use it when
1124
1159
  * you do not hold memory ids; to delete one memory by id, use `delete()`.
@@ -1419,11 +1454,27 @@ interface DeleteDataOptions {
1419
1454
  confirm?: string | null;
1420
1455
  /** Repeat the call while the server says `continue` (default true, max 50 calls). */
1421
1456
  wait?: boolean;
1457
+ /**
1458
+ * Delete in several instances of the client at once: `"all"` or a list of
1459
+ * instance ids. Needs a management key not bound to one instance (a bound key
1460
+ * may only name its own). Omit it to delete in this SDK's instance only.
1461
+ * Mirrors Python's `instances`.
1462
+ */
1463
+ instances?: 'all' | string[] | null;
1464
+ /**
1465
+ * Remove the memories now instead of after the deletion period. Needs a
1466
+ * management-level key (delete:permanent, delete:*, management:* or *).
1467
+ */
1468
+ permanent?: boolean;
1422
1469
  }
1423
1470
  /** Result of `data.delete` / `data.status`. Mirrors Python's `DeleteDataResult`. */
1424
1471
  interface DeleteDataResult {
1425
1472
  deletion_id: string | null;
1426
- /** `complete`, `partial`, `in_progress` or `dry_run`. */
1473
+ /**
1474
+ * `complete`, `pending_purge`, `partial`, `in_progress` or `dry_run`.
1475
+ * `pending_purge`: hidden from every read now, restorable with
1476
+ * `data.restore` until `purge_after`, then removed for good.
1477
+ */
1427
1478
  status: string;
1428
1479
  scope: string | null;
1429
1480
  dry_run: boolean;
@@ -1435,23 +1486,59 @@ interface DeleteDataResult {
1435
1486
  /** True when the server's size cap stopped the call. */
1436
1487
  continue: boolean;
1437
1488
  kept: string[];
1489
+ /**
1490
+ * Stores this delete does not reach at all, in plain words. `complete` means every
1491
+ * store the delete targets was cleared, not that nothing is left in these. Empty
1492
+ * from servers that predate the field.
1493
+ */
1494
+ not_covered: string[];
1438
1495
  note: string | null;
1439
1496
  memories_kept: boolean;
1440
1497
  audit: string | null;
1441
1498
  /** What the SDK cleared on this machine after the server finished. */
1442
1499
  local_cleared: string[];
1500
+ /** Only with `instances`: one result per instance, plus `instance_id`. */
1501
+ instances: Record<string, unknown>[];
1502
+ /** Only with `instances`: instances the time budget did not reach yet. */
1503
+ not_started: string[];
1504
+ /** Only with `instances`: every audit id. */
1505
+ deletion_ids: string[];
1506
+ /** With status `pending_purge`: when the deleted memories are purged (ISO 8601, UTC). */
1507
+ purge_after: string | null;
1508
+ [key: string]: unknown;
1509
+ }
1510
+ /** The most ids one `data.restore` call takes. Same as Python's MAX_RESTORE_IDS. */
1511
+ declare const MAX_RESTORE_IDS = 200;
1512
+ /** Result of `data.restore`. Mirrors Python's `RestoreResult`. */
1513
+ interface RestoreResult {
1514
+ /** Live again; served by the next fetch. */
1515
+ restored_ids: string[];
1516
+ /** Not found in this instance, not deleted, or past the purge date. */
1517
+ not_restorable_ids: string[];
1518
+ /** A store that could not be brought back in line; the memory is restored either way. */
1519
+ still_missing_in: string[];
1520
+ reindexed_ids: string[];
1521
+ fully_restored: boolean;
1443
1522
  [key: string]: unknown;
1444
1523
  }
1524
+ /** What to restore: memory ids, or every memory one `data.delete` hid. */
1525
+ interface RestoreOptions {
1526
+ memory_ids?: string[] | null;
1527
+ memoryIds?: string[] | null;
1528
+ /** The `deletion_id` of a `data.delete` result. Send exactly one of the two. */
1529
+ deletion_id?: string | null;
1530
+ deletionId?: string | null;
1531
+ }
1445
1532
  interface DataInterface {
1446
1533
  /**
1447
- * Delete data for one user, one conversation or one customer. Permanent.
1534
+ * Delete data for one user, one conversation or one customer. Memories are
1535
+ * soft-deleted (restorable until `purge_after`) unless `permanent` is true.
1448
1536
  * scope 'conversation' removes turns, summaries, telemetry and the turn buffer ONLY;
1449
1537
  * memories learned from it are kept (use scope 'user' or memories.delete). Data in
1450
1538
  * another instance is never touched; stores that cannot be scoped by instance are
1451
1539
  * skipped and named in still_present_in.
1452
1540
  *
1453
1541
  * scope 'customer' needs a management key (management:* or *); a runtime key gets 403.
1454
- * LLM call traces are not removed (llm_call_bodies up to 14 days, llm_calls up to 180 days).
1455
1542
  *
1456
1543
  * A store that could not be cleared is in `still_present_in` and
1457
1544
  * `fully_removed` is false; it is a result, not an exception. Errors:
@@ -1461,6 +1548,15 @@ interface DataInterface {
1461
1548
  delete(options: DeleteDataOptions): Promise<DeleteDataResult>;
1462
1549
  /** The audit record of a delete (status, counts, still_present_in). */
1463
1550
  status(deletionId: string): Promise<DeleteDataResult>;
1551
+ /**
1552
+ * Bring deleted memories back, until their purge date (the instance's deletion
1553
+ * period, 0 to 30 days, 30 by default). Pass up to 200 ids, or
1554
+ * `{ deletionId }` for every memory one `data.delete` hid. Needs the same key
1555
+ * permissions as delete and reaches only this instance's memories. Ids that
1556
+ * could not be restored are in `not_restorable_ids`; that is a result, not an
1557
+ * exception.
1558
+ */
1559
+ restore(target: string[] | RestoreOptions): Promise<RestoreResult>;
1464
1560
  }
1465
1561
 
1466
1562
  /** User namespace. Mirrors `UserInterface` in the Python SDK. */
@@ -2216,7 +2312,7 @@ declare class SynapClient {
2216
2312
  deleteMemory(options: {
2217
2313
  memoryId?: string;
2218
2314
  memory_id?: string;
2219
- }): Promise<Json>;
2315
+ }): Promise<DeleteMemoryResult>;
2220
2316
  /**
2221
2317
  * Resolve `client_id` and `instance_id` from the API key.
2222
2318
  *
@@ -2340,7 +2436,7 @@ declare class SynapClient {
2340
2436
  * build when the two disagree, which is the only thing that makes a manual
2341
2437
  * publish safe.
2342
2438
  */
2343
- declare const SDK_VERSION = "0.7.1";
2439
+ declare const SDK_VERSION = "0.8.0";
2344
2440
 
2345
2441
  /**
2346
2442
  * `response_shape: "ranked"`: one list in the order the server ranked it.
@@ -2581,4 +2677,4 @@ interface SynapSdkLike {
2581
2677
  };
2582
2678
  }
2583
2679
 
2584
- export { type AnthropicToolDefinition, AnticipationCacheSnapshot, type AsToolOptions, type AttachmentResult, BM25, type BatchCreateResult, COMPACTION_LEVELS, CONTRACT, type CacheNamespace, type CacheStats, type CompactOptions, type CompactionCallback, type CompactionLevel, type ConfigureOptions, type ContentPart, type ContextMetadata, type ConversationContext, type ConversationNamespace, type CreateDocument, type CreateFromFileOptions, type CreateMemoryOptions, type CreateMemoryResult, type Credentials, type CreditBalance, type CreditBucket, type CreditEstimate, type CreditLedgerEntry, type CreditLedgerPage, type CreditsNamespace, DATA_SCOPES, DEFAULT_BASE_URL, DEFAULT_DOCUMENT_TYPE, DEFAULT_INGEST_MODE, DEFAULT_RETRY_POLICY, DEFAULT_TIMEOUTS, DOCUMENT_TYPES, type DataInterface, type DataScope, type DeleteDataOptions, type DeleteDataResult, type DocumentType, ENDPOINTS, EXCERPT_CATEGORY, type Emotion, type EndpointName, type EndpointSpec, type Episode, type EstimateOptions, FORGET_MODES, type Fact, type FetchOptions, type FileData, type FilePart, type FilePartInit, type FlatMemory, type ForgetCandidate, type ForgetMode, type ForgetOptions, type ForgetResult, type ForgetStatus, type FormatOptions, HttpTransport, type HttpTransportOptions, INGEST_MODES, ITEM_COLLECTIONS, type IngestMode, type IngestTranscriptOptions, type InstanceNamespace, type ItemCollection, type Json, type LedgerOptions, type ListenOptions, MEMORY_TYPES, type MacaGenerateOptions, type MacaJob, type MacaNamespace, type MacaRelationship, type MacaWaitOptions, type MemoriesInterface, type NormalisedContext, OBJECTIVES, type Objective, type OpenAiToolDefinition, type Preference, RESPONSE_SHAPES, type RawContext, type RawContextItem, type RawConversationContext, type RecordMessageOptions, type RecordThinkingOptions, type RedeemResult, type RequestOptions, type ResponseShape, type RetryPolicy, SDK_VERSION, type Scope, ScopeAddress, ScopeLadder, type ScopeLevel, type SendMessageOptions, SynapClient, type SynapClientOptions, SynapError, type SynapLogLevel, type SynapLogger, type SynapSdkLike, THRESHOLDS, type TemporalEvent, type TemporalFields, type TextPart, type TimeoutConfig, type ToolDefinition, type ToolHandler, type ToolScope, type ToolStyle, type TranscriptIngestResult, type TranscriptTurn, type UnifiedContext, type UnifiedFetchOptions, type UpdateMemoryOptions, type UserNamespace, type WaitOptions, type WriteInvalidator, applyResponseShape, filePart, flattenContextItems, formatForPrompt, isOutcomeUnknown, mergeScopeResults, rankItems, resolvePath, shouldRetry, stem, textPart, tokenize, wireRankScore };
2680
+ export { type AnthropicToolDefinition, AnticipationCacheSnapshot, type AsToolOptions, type AttachmentResult, BM25, type BatchCreateResult, COMPACTION_LEVELS, CONTRACT, type CacheNamespace, type CacheStats, type CompactOptions, type CompactionCallback, type CompactionLevel, type ConfigureOptions, type ContentPart, type ContextMetadata, type ConversationContext, type ConversationNamespace, type CreateDocument, type CreateFromFileOptions, type CreateMemoryOptions, type CreateMemoryResult, type Credentials, type CreditBalance, type CreditBucket, type CreditEstimate, type CreditLedgerEntry, type CreditLedgerPage, type CreditsNamespace, DATA_SCOPES, DEFAULT_BASE_URL, DEFAULT_DOCUMENT_TYPE, DEFAULT_INGEST_MODE, DEFAULT_RETRY_POLICY, DEFAULT_TIMEOUTS, DOCUMENT_TYPES, type DataInterface, type DataScope, type DeleteDataOptions, type DeleteDataResult, type DeleteMemoryOptions, type DeleteMemoryResult, type DocumentType, ENDPOINTS, EXCERPT_CATEGORY, type Emotion, type EndpointName, type EndpointSpec, type Episode, type EstimateOptions, FORGET_MODES, type Fact, type FetchOptions, type FileData, type FilePart, type FilePartInit, type FlatMemory, type ForgetCandidate, type ForgetMode, type ForgetOptions, type ForgetResult, type ForgetStatus, type FormatOptions, HttpTransport, type HttpTransportOptions, INGEST_MODES, ITEM_COLLECTIONS, type IngestMode, type IngestTranscriptOptions, type InstanceNamespace, type ItemCollection, type Json, type LedgerOptions, type ListenOptions, MAX_RESTORE_IDS, MEMORY_TYPES, type MacaGenerateOptions, type MacaJob, type MacaNamespace, type MacaRelationship, type MacaWaitOptions, type MemoriesInterface, type NormalisedContext, OBJECTIVES, type Objective, type OpenAiToolDefinition, type Preference, RESPONSE_SHAPES, type RawContext, type RawContextItem, type RawConversationContext, type RecordMessageOptions, type RecordThinkingOptions, type RedeemResult, type RequestOptions, type ResponseShape, type RestoreOptions, type RestoreResult, type RetryPolicy, SDK_VERSION, type Scope, ScopeAddress, ScopeLadder, type ScopeLevel, type SendMessageOptions, SynapClient, type SynapClientOptions, SynapError, type SynapLogLevel, type SynapLogger, type SynapSdkLike, THRESHOLDS, type TemporalEvent, type TemporalFields, type TextPart, type TimeoutConfig, type ToolDefinition, type ToolHandler, type ToolScope, type ToolStyle, type TranscriptIngestResult, type TranscriptTurn, type UnifiedContext, type UnifiedFetchOptions, type UpdateMemoryOptions, type UserNamespace, type WaitOptions, type WriteInvalidator, applyResponseShape, filePart, flattenContextItems, formatForPrompt, isOutcomeUnknown, mergeScopeResults, rankItems, resolvePath, shouldRetry, stem, textPart, tokenize, wireRankScore };