Cognitive Memory
Every registered cognitive memory instance operation, with source-derived inputs, outputs, access policy, and errors.
This reference covers 9 HTTP operations registered by the Akasha daemon. Call these paths on your instance base URL. See authentication, errors, and coverage before integrating.
| Method | Path | Operation |
|---|---|---|
POST | /v1/memory/cognitive/query | Memory cognitive query |
POST | /v1/memory/cognitive/thought | Memory cognitive thought |
POST | /v1/memory/cognitive/decision | Memory cognitive decision |
POST | /v1/memory/cognitive/interaction | Memory cognitive interaction |
POST | /v1/memory/cognitive/session | Memory cognitive session |
POST | /v1/memory/cognitive/resource | Memory cognitive resource |
POST | /v1/memory/cognitive/usage | Memory cognitive usage |
POST | /v1/memory/cognitive/resources | Memory cognitive resource store |
POST | /v1/memory/cognitive/resources/usage | Memory cognitive resource usage |
POST /v1/memory/cognitive/query
Memory cognitive query
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — CognitiveQueryReq
| Field | Rust type | Required on input | Notes |
|---|---|---|---|
query | serde_json::Value | Yes |
struct CognitiveQueryReq {
query: serde_json::Value,
}JSON field accesses in handler: agent_id, end_time, include_decisions, include_interactions, include_sessions, include_thoughts, min_confidence, start_time. Nested lookups are included; this list alone does not establish requiredness.
Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({
"thoughts": res.thoughts.len(),
"decisions": res.decisions.len(),
"interactions": res.interactions.len(),
"sessions": res.sessions.len()
})Errors and validation
Directly referenced error variants: InvalidRequest. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7740. Registration: akasha-daemon/src/main.rs:4666.
POST /v1/memory/cognitive/thought
Memory cognitive thought
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — CognitiveThoughtReq
| Field | Rust type | Required on input | Notes |
|---|---|---|---|
thought | CognitiveThought | Yes |
struct CognitiveThoughtReq {
thought: CognitiveThought,
}Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"id": id})Errors and validation
Directly referenced error variants: InvalidRequest. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7663. Registration: akasha-daemon/src/main.rs:4667.
POST /v1/memory/cognitive/decision
Memory cognitive decision
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — CognitiveDecisionReq
| Field | Rust type | Required on input | Notes |
|---|---|---|---|
decision | CognitiveDecision | Yes |
struct CognitiveDecisionReq {
decision: CognitiveDecision,
}Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"id": id})Errors and validation
Directly referenced error variants: InvalidRequest. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7682. Registration: akasha-daemon/src/main.rs:4671.
POST /v1/memory/cognitive/interaction
Memory cognitive interaction
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — CognitiveInteractionReq
| Field | Rust type | Required on input | Notes |
|---|---|---|---|
interaction | AgentInteraction | Yes |
struct CognitiveInteractionReq {
interaction: AgentInteraction,
}Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"id": id})Errors and validation
Directly referenced error variants: InvalidRequest. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7701. Registration: akasha-daemon/src/main.rs:4675.
POST /v1/memory/cognitive/session
Memory cognitive session
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — CognitiveSessionReq
| Field | Rust type | Required on input | Notes |
|---|---|---|---|
agent_id | String | Yes | |
goal | String | Yes |
struct CognitiveSessionReq {
agent_id: String,
goal: String,
}Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"session": sess})Errors and validation
Directly referenced error variants: InvalidRequest. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7721. Registration: akasha-daemon/src/main.rs:4679.
POST /v1/memory/cognitive/resource
Memory cognitive resource
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — serde_json::Value
This handler accepts dynamic JSON. The field accesses below are source observations, not a fabricated required-field schema.
Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"ok": true})Errors and validation
Directly referenced error variants: none in the handler body. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7806. Registration: akasha-daemon/src/main.rs:4683.
POST /v1/memory/cognitive/usage
Memory cognitive usage
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — serde_json::Value
This handler accepts dynamic JSON. The field accesses below are source observations, not a fabricated required-field schema.
Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"ok": true})Errors and validation
Directly referenced error variants: none in the handler body. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7815. Registration: akasha-daemon/src/main.rs:4687.
POST /v1/memory/cognitive/resources
Memory cognitive resource store
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — serde_json::Value
This handler accepts dynamic JSON. The field accesses below are source observations, not a fabricated required-field schema.
Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"ok": true})Errors and validation
Directly referenced error variants: none in the handler body. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7824. Registration: akasha-daemon/src/main.rs:4688.
POST /v1/memory/cognitive/resources/usage
Memory cognitive resource usage
| Availability | Source contract |
|---|---|
| Registration | config.enable_memory |
| Runtime service | memory |
| Handler dependencies | See handler source and return expressions. |
Access: Daemon authentication and capability namespace authority; memory-domain permissions apply where mapped.
Request
Json — serde_json::Value
This handler accepts dynamic JSON. The field accesses below are source observations, not a fabricated required-field schema.
Response
Declared return: Result<impl IntoResponse, DaemonError>
The following are the exact JSON construction expressions in the handler. Values such as rows, result, and delegated types are runtime values, not literal example payloads.
serde_json::json!({"ok": true})Errors and validation
Directly referenced error variants: none in the handler body. Middleware and delegated services can return additional errors described in the shared error reference.
Source: akasha-daemon/src/main.rs:7833. Registration: akasha-daemon/src/main.rs:4692.