ingest_data¶
Operation¶
ingest_data
async
¶
ingest_data(input: IngestDataInput, plugins: list[Plugin] | None = None) -> IngestDataOutput
Submits content directly for ingestion to generate long-term memory records in a AgentCore Memory resource.
To use this operation, you must have the bedrock-agentcore:IngestData
permission.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
input
|
IngestDataInput
|
An instance of |
required |
plugins
|
list[Plugin] | None
|
A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations. |
None
|
Returns:
| Type | Description |
|---|---|
IngestDataOutput
|
An instance of |
Input¶
IngestDataInput
dataclass
¶
Dataclass for IngestDataInput structure.
Attributes¶
actor_id
class-attribute
instance-attribute
¶
actor_id: str | None = None
The identifier of the actor associated with this content. An actor represents an entity that participates in sessions and generates content.
client_token
class-attribute
instance-attribute
¶
client_token: str | None = None
A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, AgentCore ignores the request, but does not return an error.
content_timestamp
class-attribute
instance-attribute
¶
content_timestamp: datetime | None = None
The timestamp of when the content occurred.
extraction_config
class-attribute
instance-attribute
¶
extraction_config: ExtractionConfig | None = None
The extraction configuration for long-term memory records. Use this parameter to specify namespace variable keys and their values for namespace substitution during extraction.
memory_id
class-attribute
instance-attribute
¶
memory_id: str | None = None
The identifier of the AgentCore Memory resource to ingest content into.
metadata
class-attribute
instance-attribute
¶
metadata: dict[str, MetadataValue] | None = None
The key-value metadata to attach to the content.
session_id
class-attribute
instance-attribute
¶
session_id: str | None = None
The identifier of the session that the content belongs to. If not provided, a session identifier is generated and returned in the response.
source
class-attribute
instance-attribute
¶
source: ContentSource | None = None
The content to ingest. Only inline content is supported.
Output¶
IngestDataOutput
dataclass
¶
Dataclass for IngestDataOutput structure.
Attributes¶
response_metadata
class-attribute
instance-attribute
¶
response_metadata: ResponseMetadata = field(default=EMPTY_RESPONSE_METADATA, repr=False, compare=False)
Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.