Overview
Memory operations let you collect and summarize data across multiple steps or loop iterations. Data is stored in named collections that persist throughout the execution.Two operation types
| Type | Description | Use case |
|---|---|---|
append | Add an item to a collection | Accumulate rows, records, captured values |
aggregate | Compute a summary over a collection | Sum totals, count items, find min/max |
Append
Add a captured value to a named collection:| Field | Type | Required | Description |
|---|---|---|---|
type | "append" | Yes | Operation type |
collection | string | Yes | Target collection name |
source | string | No | Capture variable name to append |
Aggregate
Compute a summary value from a collection:| Field | Type | Required | Description |
|---|---|---|---|
type | "aggregate" | Yes | Operation type |
collection | string | Yes | Source collection name |
operation | AggregateOp | Yes | Aggregation operation |
field | string | No | Field to aggregate on |
outputVariable | string | No | Variable to store the result |
Aggregate operations
| Operation | Description | Example result |
|---|---|---|
sum | Sum of numeric values | 1500 |
count | Number of items | 25 |
avg | Average of numeric values | 60.5 |
min | Minimum value | 10 |
max | Maximum value | 200 |
concat | Concatenate string values | "A, B, C" |
unique_count | Count of unique values | 18 |
Complete example
Scrape a product listing across multiple pages and export to CSV:Iterating over collections
Usecollection:name syntax in a forEach loop to iterate over collected items: