@anthropic-ai/sdk 0.90.0 → 0.91.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.
Files changed (112) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/bin/migration-config.json +185 -0
  3. package/internal/types.d.mts +6 -12
  4. package/internal/types.d.mts.map +1 -1
  5. package/internal/types.d.ts +6 -12
  6. package/internal/types.d.ts.map +1 -1
  7. package/package.json +1 -1
  8. package/resources/beta/beta.d.mts +7 -3
  9. package/resources/beta/beta.d.mts.map +1 -1
  10. package/resources/beta/beta.d.ts +7 -3
  11. package/resources/beta/beta.d.ts.map +1 -1
  12. package/resources/beta/beta.js +4 -0
  13. package/resources/beta/beta.js.map +1 -1
  14. package/resources/beta/beta.mjs +4 -0
  15. package/resources/beta/beta.mjs.map +1 -1
  16. package/resources/beta/files.js +5 -5
  17. package/resources/beta/files.js.map +1 -1
  18. package/resources/beta/files.mjs +5 -5
  19. package/resources/beta/files.mjs.map +1 -1
  20. package/resources/beta/index.d.mts +2 -1
  21. package/resources/beta/index.d.mts.map +1 -1
  22. package/resources/beta/index.d.ts +2 -1
  23. package/resources/beta/index.d.ts.map +1 -1
  24. package/resources/beta/index.js +11 -9
  25. package/resources/beta/index.js.map +1 -1
  26. package/resources/beta/index.mjs +1 -0
  27. package/resources/beta/index.mjs.map +1 -1
  28. package/resources/beta/memory-stores/index.d.mts +4 -0
  29. package/resources/beta/memory-stores/index.d.mts.map +1 -0
  30. package/resources/beta/memory-stores/index.d.ts +4 -0
  31. package/resources/beta/memory-stores/index.d.ts.map +1 -0
  32. package/resources/beta/memory-stores/index.js +11 -0
  33. package/resources/beta/memory-stores/index.js.map +1 -0
  34. package/resources/beta/memory-stores/index.mjs +5 -0
  35. package/resources/beta/memory-stores/index.mjs.map +1 -0
  36. package/resources/beta/memory-stores/memories.d.mts +232 -0
  37. package/resources/beta/memory-stores/memories.d.mts.map +1 -0
  38. package/resources/beta/memory-stores/memories.d.ts +232 -0
  39. package/resources/beta/memory-stores/memories.d.ts.map +1 -0
  40. package/resources/beta/memory-stores/memories.js +130 -0
  41. package/resources/beta/memory-stores/memories.js.map +1 -0
  42. package/resources/beta/memory-stores/memories.mjs +126 -0
  43. package/resources/beta/memory-stores/memories.mjs.map +1 -0
  44. package/resources/beta/memory-stores/memory-stores.d.mts +187 -0
  45. package/resources/beta/memory-stores/memory-stores.d.mts.map +1 -0
  46. package/resources/beta/memory-stores/memory-stores.d.ts +187 -0
  47. package/resources/beta/memory-stores/memory-stores.d.ts.map +1 -0
  48. package/resources/beta/memory-stores/memory-stores.js +145 -0
  49. package/resources/beta/memory-stores/memory-stores.js.map +1 -0
  50. package/resources/beta/memory-stores/memory-stores.mjs +140 -0
  51. package/resources/beta/memory-stores/memory-stores.mjs.map +1 -0
  52. package/resources/beta/memory-stores/memory-versions.d.mts +152 -0
  53. package/resources/beta/memory-stores/memory-versions.d.mts.map +1 -0
  54. package/resources/beta/memory-stores/memory-versions.d.ts +152 -0
  55. package/resources/beta/memory-stores/memory-versions.d.ts.map +1 -0
  56. package/resources/beta/memory-stores/memory-versions.js +81 -0
  57. package/resources/beta/memory-stores/memory-versions.js.map +1 -0
  58. package/resources/beta/memory-stores/memory-versions.mjs +77 -0
  59. package/resources/beta/memory-stores/memory-versions.mjs.map +1 -0
  60. package/resources/beta/memory-stores.d.mts +2 -0
  61. package/resources/beta/memory-stores.d.mts.map +1 -0
  62. package/resources/beta/memory-stores.d.ts +2 -0
  63. package/resources/beta/memory-stores.d.ts.map +1 -0
  64. package/resources/beta/memory-stores.js +6 -0
  65. package/resources/beta/memory-stores.js.map +1 -0
  66. package/resources/beta/memory-stores.mjs +3 -0
  67. package/resources/beta/memory-stores.mjs.map +1 -0
  68. package/resources/beta/sessions/index.d.mts +2 -2
  69. package/resources/beta/sessions/index.d.mts.map +1 -1
  70. package/resources/beta/sessions/index.d.ts +2 -2
  71. package/resources/beta/sessions/index.d.ts.map +1 -1
  72. package/resources/beta/sessions/index.js.map +1 -1
  73. package/resources/beta/sessions/index.mjs.map +1 -1
  74. package/resources/beta/sessions/resources.d.mts +42 -4
  75. package/resources/beta/sessions/resources.d.mts.map +1 -1
  76. package/resources/beta/sessions/resources.d.ts +42 -4
  77. package/resources/beta/sessions/resources.d.ts.map +1 -1
  78. package/resources/beta/sessions/sessions.d.mts +24 -4
  79. package/resources/beta/sessions/sessions.d.mts.map +1 -1
  80. package/resources/beta/sessions/sessions.d.ts +24 -4
  81. package/resources/beta/sessions/sessions.d.ts.map +1 -1
  82. package/resources/beta/sessions/sessions.js.map +1 -1
  83. package/resources/beta/sessions/sessions.mjs.map +1 -1
  84. package/resources/completions.d.mts +8 -24
  85. package/resources/completions.d.mts.map +1 -1
  86. package/resources/completions.d.ts +8 -24
  87. package/resources/completions.d.ts.map +1 -1
  88. package/src/internal/types.ts +6 -8
  89. package/src/resources/beta/beta.ts +32 -2
  90. package/src/resources/beta/files.ts +5 -5
  91. package/src/resources/beta/index.ts +13 -0
  92. package/src/resources/beta/memory-stores/index.ts +47 -0
  93. package/src/resources/beta/memory-stores/memories.ts +399 -0
  94. package/src/resources/beta/memory-stores/memory-stores.ts +374 -0
  95. package/src/resources/beta/memory-stores/memory-versions.ts +259 -0
  96. package/src/resources/beta/memory-stores.ts +3 -0
  97. package/src/resources/beta/sessions/index.ts +2 -0
  98. package/src/resources/beta/sessions/resources.ts +52 -3
  99. package/src/resources/beta/sessions/sessions.ts +32 -1
  100. package/src/resources/completions.ts +8 -24
  101. package/src/tools/memory/node.ts +13 -5
  102. package/src/version.ts +1 -1
  103. package/tools/memory/node.d.mts.map +1 -1
  104. package/tools/memory/node.d.ts.map +1 -1
  105. package/tools/memory/node.js +12 -5
  106. package/tools/memory/node.js.map +1 -1
  107. package/tools/memory/node.mjs +12 -5
  108. package/tools/memory/node.mjs.map +1 -1
  109. package/version.d.mts +1 -1
  110. package/version.d.ts +1 -1
  111. package/version.js +1 -1
  112. package/version.mjs +1 -1
@@ -113,36 +113,20 @@ export interface CompletionCreateParamsBase {
113
113
  */
114
114
  stream?: boolean;
115
115
  /**
116
- * Body param: Amount of randomness injected into the response.
117
- *
118
- * Defaults to `1.0`. Ranges from `0.0` to `1.0`. Use `temperature` closer to `0.0`
119
- * for analytical / multiple choice, and closer to `1.0` for creative and
120
- * generative tasks.
121
- *
122
- * Note that even with `temperature` of `0.0`, the results will not be fully
123
- * deterministic.
116
+ * @deprecated Deprecated. Models released after Claude Opus 4.6 do not support
117
+ * setting temperature. A value of 1.0 of will be accepted for backwards
118
+ * compatibility, all other values will be rejected with a 400 error.
124
119
  */
125
120
  temperature?: number;
126
121
  /**
127
- * Body param: Only sample from the top K options for each subsequent token.
128
- *
129
- * Used to remove "long tail" low probability responses.
130
- * [Learn more technical details here](https://towardsdatascience.com/how-to-sample-from-language-models-682bceb97277).
131
- *
132
- * Recommended for advanced use cases only. You usually only need to use
133
- * `temperature`.
122
+ * @deprecated Deprecated. Models released after Claude Opus 4.6 do not accept
123
+ * top_k; any value will be rejected with a 400 error.
134
124
  */
135
125
  top_k?: number;
136
126
  /**
137
- * Body param: Use nucleus sampling.
138
- *
139
- * In nucleus sampling, we compute the cumulative distribution over all the options
140
- * for each subsequent token in decreasing probability order and cut it off once it
141
- * reaches a particular probability specified by `top_p`. You should either alter
142
- * `temperature` or `top_p`, but not both.
143
- *
144
- * Recommended for advanced use cases only. You usually only need to use
145
- * `temperature`.
127
+ * @deprecated Deprecated. Models released after Claude Opus 4.6 do not support
128
+ * setting top_p. A value >= 0.99 will be accepted for backwards compatibility, all
129
+ * other values will be rejected with a 400 error.
146
130
  */
147
131
  top_p?: number;
148
132
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"completions.d.ts","sourceRoot":"","sources":["../src/resources/completions.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,cAAc;OACnB,KAAK,OAAO;OACZ,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,MAAM,EAAE;OAEV,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C;IAE5C,KAAY,kCAAkC,GAAG,cAAc,CAAC,kCAAkC,CAAC;IACnG,KAAY,+BAA+B,GAAG,cAAc,CAAC,+BAA+B,CAAC;CAC9F;AAED,MAAM,WAAW,kCAAmC,SAAQ,0BAA0B;IACpF;;;;;OAKG;IACH,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB;AAED,MAAM,WAAW,+BAAgC,SAAQ,0BAA0B;IACjF;;;;;OAKG;IACH,MAAM,EAAE,IAAI,CAAC;CACd;AAED,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,kCAAkC,IAAI,kCAAkC,EAC7E,KAAK,+BAA+B,IAAI,+BAA+B,GACxE,CAAC;CACH"}
@@ -40,7 +40,6 @@ type OverloadedParameters<T> =
40
40
  : T extends (...args: infer A) => unknown ? A
41
41
  : never;
42
42
 
43
- /* eslint-disable */
44
43
  /**
45
44
  * These imports attempt to get types from a parent package's dependencies.
46
45
  * Unresolved bare specifiers can trigger [automatic type acquisition][1] in some projects, which
@@ -63,19 +62,18 @@ type OverloadedParameters<T> =
63
62
  *
64
63
  * [1]: https://www.typescriptlang.org/tsconfig/#typeAcquisition
65
64
  */
66
- /** @ts-ignore For users with \@types/node */
65
+ /** @ts-ignore For users with \@types/node */ /* prettier-ignore */
67
66
  type UndiciTypesRequestInit = NotAny<import('undici-types').RequestInit> | NotAny<import('undici-types').RequestInit> | NotAny<import('../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../../node_modules/undici-types/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../../../node_modules/undici-types/index.d.ts').RequestInit>;
68
- /** @ts-ignore For users with undici */
67
+ /** @ts-ignore For users with undici */ /* prettier-ignore */
69
68
  type UndiciRequestInit = NotAny<import('undici').RequestInit> | NotAny<import('undici').RequestInit> | NotAny<import('../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../../node_modules/undici/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../../../node_modules/undici/index.d.ts').RequestInit>;
70
- /** @ts-ignore For users with \@types/bun */
69
+ /** @ts-ignore For users with \@types/bun */ /* prettier-ignore */
71
70
  type BunRequestInit = globalThis.FetchRequestInit;
72
- /** @ts-ignore For users with node-fetch@2 */
71
+ /** @ts-ignore For users with node-fetch@2 */ /* prettier-ignore */
73
72
  type NodeFetch2RequestInit = NotAny<import('node-fetch').RequestInit> | NotAny<import('node-fetch').RequestInit> | NotAny<import('../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit> | NotAny<import('../../../../../../../../../../node_modules/@types/node-fetch/index.d.ts').RequestInit>;
74
- /** @ts-ignore For users with node-fetch@3, doesn't need file extension because types are at ./@types/index.d.ts */
73
+ /** @ts-ignore For users with node-fetch@3, doesn't need file extension because types are at ./@types/index.d.ts */ /* prettier-ignore */
75
74
  type NodeFetch3RequestInit = NotAny<import('node-fetch.js').RequestInit> | NotAny<import('node-fetch.js').RequestInit> | NotAny<import('../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../../../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../../../../../../node_modules/node-fetch').RequestInit> | NotAny<import('../../../../../../../../../../node_modules/node-fetch').RequestInit>;
76
- /** @ts-ignore For users who use Deno */
75
+ /** @ts-ignore For users who use Deno */ /* prettier-ignore */
77
76
  type FetchRequestInit = NonNullable<OverloadedParameters<typeof fetch>[1]>;
78
- /* eslint-enable */
79
77
 
80
78
  type RequestInits =
81
79
  | NotAny<UndiciTypesRequestInit>
@@ -99,6 +99,19 @@ import {
99
99
  BetaManagedAgentsSkillParams,
100
100
  BetaManagedAgentsURLMCPServerParams,
101
101
  } from './agents/agents';
102
+ import * as MemoryStoresAPI from './memory-stores/memory-stores';
103
+ import {
104
+ BetaManagedAgentsDeletedMemoryStore,
105
+ BetaManagedAgentsMemoryStore,
106
+ BetaManagedAgentsMemoryStoresPageCursor,
107
+ MemoryStoreArchiveParams,
108
+ MemoryStoreCreateParams,
109
+ MemoryStoreDeleteParams,
110
+ MemoryStoreListParams,
111
+ MemoryStoreRetrieveParams,
112
+ MemoryStoreUpdateParams,
113
+ MemoryStores,
114
+ } from './memory-stores/memory-stores';
102
115
  import * as MessagesAPI from './messages/messages';
103
116
  import {
104
117
  BetaAdvisorMessageIterationUsage,
@@ -317,6 +330,7 @@ import {
317
330
  BetaManagedAgentsDeletedSession,
318
331
  BetaManagedAgentsFileResourceParams,
319
332
  BetaManagedAgentsGitHubRepositoryResourceParams,
333
+ BetaManagedAgentsMemoryStoreResourceParam,
320
334
  BetaManagedAgentsSession,
321
335
  BetaManagedAgentsSessionAgent,
322
336
  BetaManagedAgentsSessionStats,
@@ -364,6 +378,7 @@ export class Beta extends APIResource {
364
378
  environments: EnvironmentsAPI.Environments = new EnvironmentsAPI.Environments(this._client);
365
379
  sessions: SessionsAPI.Sessions = new SessionsAPI.Sessions(this._client);
366
380
  vaults: VaultsAPI.Vaults = new VaultsAPI.Vaults(this._client);
381
+ memoryStores: MemoryStoresAPI.MemoryStores = new MemoryStoresAPI.MemoryStores(this._client);
367
382
  files: FilesAPI.Files = new FilesAPI.Files(this._client);
368
383
  skills: SkillsAPI.Skills = new SkillsAPI.Skills(this._client);
369
384
  userProfiles: UserProfilesAPI.UserProfiles = new UserProfilesAPI.UserProfiles(this._client);
@@ -392,8 +407,8 @@ export type AnthropicBeta =
392
407
  | 'skills-2025-10-02'
393
408
  | 'fast-mode-2026-02-01'
394
409
  | 'output-300k-2026-03-24'
395
- | 'advisor-tool-2026-03-01'
396
- | 'user-profiles-2026-03-24';
410
+ | 'user-profiles-2026-03-24'
411
+ | 'advisor-tool-2026-03-01';
397
412
 
398
413
  export interface BetaAPIError {
399
414
  message: string;
@@ -474,6 +489,7 @@ Beta.Agents = Agents;
474
489
  Beta.Environments = Environments;
475
490
  Beta.Sessions = Sessions;
476
491
  Beta.Vaults = Vaults;
492
+ Beta.MemoryStores = MemoryStores;
477
493
  Beta.Files = Files;
478
494
  Beta.Skills = Skills;
479
495
  Beta.UserProfiles = UserProfiles;
@@ -784,6 +800,7 @@ export declare namespace Beta {
784
800
  type BetaManagedAgentsDeletedSession as BetaManagedAgentsDeletedSession,
785
801
  type BetaManagedAgentsFileResourceParams as BetaManagedAgentsFileResourceParams,
786
802
  type BetaManagedAgentsGitHubRepositoryResourceParams as BetaManagedAgentsGitHubRepositoryResourceParams,
803
+ type BetaManagedAgentsMemoryStoreResourceParam as BetaManagedAgentsMemoryStoreResourceParam,
787
804
  type BetaManagedAgentsSession as BetaManagedAgentsSession,
788
805
  type BetaManagedAgentsSessionAgent as BetaManagedAgentsSessionAgent,
789
806
  type BetaManagedAgentsSessionStats as BetaManagedAgentsSessionStats,
@@ -810,6 +827,19 @@ export declare namespace Beta {
810
827
  type VaultArchiveParams as VaultArchiveParams,
811
828
  };
812
829
 
830
+ export {
831
+ MemoryStores as MemoryStores,
832
+ type BetaManagedAgentsDeletedMemoryStore as BetaManagedAgentsDeletedMemoryStore,
833
+ type BetaManagedAgentsMemoryStore as BetaManagedAgentsMemoryStore,
834
+ type BetaManagedAgentsMemoryStoresPageCursor as BetaManagedAgentsMemoryStoresPageCursor,
835
+ type MemoryStoreCreateParams as MemoryStoreCreateParams,
836
+ type MemoryStoreRetrieveParams as MemoryStoreRetrieveParams,
837
+ type MemoryStoreUpdateParams as MemoryStoreUpdateParams,
838
+ type MemoryStoreListParams as MemoryStoreListParams,
839
+ type MemoryStoreDeleteParams as MemoryStoreDeleteParams,
840
+ type MemoryStoreArchiveParams as MemoryStoreArchiveParams,
841
+ };
842
+
813
843
  export {
814
844
  Files as Files,
815
845
  type BetaFileScope as BetaFileScope,
@@ -28,7 +28,7 @@ export class Files extends APIResource {
28
28
  options?: RequestOptions,
29
29
  ): PagePromise<FileMetadataPage, FileMetadata> {
30
30
  const { betas, ...query } = params ?? {};
31
- return this._client.getAPIList('/v1/files', Page<FileMetadata>, {
31
+ return this._client.getAPIList('/v1/files?beta=true', Page<FileMetadata>, {
32
32
  query,
33
33
  ...options,
34
34
  headers: buildHeaders([
@@ -54,7 +54,7 @@ export class Files extends APIResource {
54
54
  options?: RequestOptions,
55
55
  ): APIPromise<DeletedFile> {
56
56
  const { betas } = params ?? {};
57
- return this._client.delete(path`/v1/files/${fileID}`, {
57
+ return this._client.delete(path`/v1/files/${fileID}?beta=true`, {
58
58
  ...options,
59
59
  headers: buildHeaders([
60
60
  { 'anthropic-beta': [...(betas ?? []), 'files-api-2025-04-14'].toString() },
@@ -82,7 +82,7 @@ export class Files extends APIResource {
82
82
  options?: RequestOptions,
83
83
  ): APIPromise<Response> {
84
84
  const { betas } = params ?? {};
85
- return this._client.get(path`/v1/files/${fileID}/content`, {
85
+ return this._client.get(path`/v1/files/${fileID}/content?beta=true`, {
86
86
  ...options,
87
87
  headers: buildHeaders([
88
88
  {
@@ -110,7 +110,7 @@ export class Files extends APIResource {
110
110
  options?: RequestOptions,
111
111
  ): APIPromise<FileMetadata> {
112
112
  const { betas } = params ?? {};
113
- return this._client.get(path`/v1/files/${fileID}`, {
113
+ return this._client.get(path`/v1/files/${fileID}?beta=true`, {
114
114
  ...options,
115
115
  headers: buildHeaders([
116
116
  { 'anthropic-beta': [...(betas ?? []), 'files-api-2025-04-14'].toString() },
@@ -133,7 +133,7 @@ export class Files extends APIResource {
133
133
  const { betas, ...body } = params;
134
134
 
135
135
  return this._client.post(
136
- '/v1/files',
136
+ '/v1/files?beta=true',
137
137
  multipartFormRequestOptions(
138
138
  {
139
139
  body,
@@ -83,6 +83,18 @@ export {
83
83
  type FileUploadParams,
84
84
  type FileMetadataPage,
85
85
  } from './files';
86
+ export {
87
+ MemoryStores,
88
+ type BetaManagedAgentsDeletedMemoryStore,
89
+ type BetaManagedAgentsMemoryStore,
90
+ type MemoryStoreCreateParams,
91
+ type MemoryStoreRetrieveParams,
92
+ type MemoryStoreUpdateParams,
93
+ type MemoryStoreListParams,
94
+ type MemoryStoreDeleteParams,
95
+ type MemoryStoreArchiveParams,
96
+ type BetaManagedAgentsMemoryStoresPageCursor,
97
+ } from './memory-stores/index';
86
98
  export {
87
99
  Messages,
88
100
  type BetaAdvisorMessageIterationUsage,
@@ -322,6 +334,7 @@ export {
322
334
  type BetaManagedAgentsDeletedSession,
323
335
  type BetaManagedAgentsFileResourceParams,
324
336
  type BetaManagedAgentsGitHubRepositoryResourceParams,
337
+ type BetaManagedAgentsMemoryStoreResourceParam,
325
338
  type BetaManagedAgentsSession,
326
339
  type BetaManagedAgentsSessionAgent,
327
340
  type BetaManagedAgentsSessionStats,
@@ -0,0 +1,47 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export {
4
+ Memories,
5
+ type BetaManagedAgentsConflictError,
6
+ type BetaManagedAgentsContentSha256Precondition,
7
+ type BetaManagedAgentsDeletedMemory,
8
+ type BetaManagedAgentsError,
9
+ type BetaManagedAgentsMemory,
10
+ type BetaManagedAgentsMemoryListItem,
11
+ type BetaManagedAgentsMemoryPathConflictError,
12
+ type BetaManagedAgentsMemoryPreconditionFailedError,
13
+ type BetaManagedAgentsMemoryPrefix,
14
+ type BetaManagedAgentsMemoryView,
15
+ type BetaManagedAgentsPrecondition,
16
+ type MemoryCreateParams,
17
+ type MemoryRetrieveParams,
18
+ type MemoryUpdateParams,
19
+ type MemoryListParams,
20
+ type MemoryDeleteParams,
21
+ type BetaManagedAgentsMemoryListItemsPageCursor,
22
+ } from './memories';
23
+ export {
24
+ MemoryStores,
25
+ type BetaManagedAgentsDeletedMemoryStore,
26
+ type BetaManagedAgentsMemoryStore,
27
+ type MemoryStoreCreateParams,
28
+ type MemoryStoreRetrieveParams,
29
+ type MemoryStoreUpdateParams,
30
+ type MemoryStoreListParams,
31
+ type MemoryStoreDeleteParams,
32
+ type MemoryStoreArchiveParams,
33
+ type BetaManagedAgentsMemoryStoresPageCursor,
34
+ } from './memory-stores';
35
+ export {
36
+ MemoryVersions,
37
+ type BetaManagedAgentsActor,
38
+ type BetaManagedAgentsAPIActor,
39
+ type BetaManagedAgentsMemoryVersion,
40
+ type BetaManagedAgentsMemoryVersionOperation,
41
+ type BetaManagedAgentsSessionActor,
42
+ type BetaManagedAgentsUserActor,
43
+ type MemoryVersionRetrieveParams,
44
+ type MemoryVersionListParams,
45
+ type MemoryVersionRedactParams,
46
+ type BetaManagedAgentsMemoryVersionsPageCursor,
47
+ } from './memory-versions';