Create a memory
POST/v1/memory_stores/{memory_store_id}/memories
Create a memory
Parameters
Returns
Create a memory
package com.anthropic.example;
import com.anthropic.client.AnthropicClient;
import com.anthropic.client.okhttp.AnthropicOkHttpClient;
import com.anthropic.models.beta.memorystores.memories.BetaManagedAgentsMemory;
import com.anthropic.models.beta.memorystores.memories.MemoryCreateParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
AnthropicClient client = AnthropicOkHttpClient.fromEnv();
MemoryCreateParams params = MemoryCreateParams.builder()
.memoryStoreId("memory_store_id")
.content("content")
.path("xx")
.build();
BetaManagedAgentsMemory betaManagedAgentsMemory = client.beta().memoryStores().memories().create(params);
}
}Response 200
{
"id": "id",
"content_sha256": "content_sha256",
"content_size_bytes": 0,
"created_at": "2019-12-27T18:11:19.117Z",
"memory_store_id": "memory_store_id",
"memory_version_id": "memory_version_id",
"path": "path",
"type": "memory",
"updated_at": "2019-12-27T18:11:19.117Z",
"content": "content"
}Returns Examples
Response 200
{
"id": "id",
"content_sha256": "content_sha256",
"content_size_bytes": 0,
"created_at": "2019-12-27T18:11:19.117Z",
"memory_store_id": "memory_store_id",
"memory_version_id": "memory_version_id",
"path": "path",
"type": "memory",
"updated_at": "2019-12-27T18:11:19.117Z",
"content": "content"
}