Reference · Tools

AWS DynamoDB

Create, read, update, and delete items in AWS DynamoDB tables

Action Data & Storage v1

The AWS DynamoDB node lets you create, read, update, and delete items in any DynamoDB table directly from a workflow. You can query a secondary index with filter expressions to power a serverless product catalog lookup, or scan a table with pagination to process large datasets in batches. It handles DynamoDB's attribute type marshalling automatically, so you work with plain JavaScript values rather than the raw `{S: ...}` / `{N: ...}` format.

Node type
Action
Parameters
25
Outputs
Output, Error
Credentials
AWS DynamoDB

AWS DynamoDB

Create, read, update, and delete items in AWS DynamoDB

Overview

AWS DynamoDB action node for NoSQL key-value and document database operations. Supports create/update (PutItem), get (GetItem), get many (Scan or Query with pagination), and delete (DeleteItem). Uses the AWS SDK v3 DynamoDB Document Client for automatic type marshalling between JavaScript native types and DynamoDB attribute types. Supports condition expressions, projection expressions, filter expressions, expression attribute names/values, secondary index queries, and configurable read consistency.

Category: Data & Storage
Tool Name: aws_dynamodb
Version: 1

Appearance: Icon: lucide-Database | Color: #FF9900

Node Type

Action — processes input items and produces output

Input / Output

DirectionPort(s)
InputInput
OutputOutput, Error

Credentials

This tool requires AWS DynamoDB credentials. See the Credentials Guide for setup instructions.

Resources

ResourceValue
Itemitem

Operations

OperationValueDescription
Create or UpdateupsertCreate a new item, or replace the current one if it already exists (PutItem)
DeletedeleteDelete an item by primary key
GetgetGet a single item by primary key
Get ManygetAllGet many items via Scan or Query

Parameters

Item: Create or Update

ParameterTypeRequiredDefaultDescription
Table NamestringYesThe DynamoDB table name. You can find table names in the AWS DynamoDB console.
Data to SendoptionsNodefineBelowWhether to auto-map input data or define fields manually.
Options: autoMapInputData (use when node input properties match destination column names), defineBelow (set the value for each destination column)
Inputs to IgnorestringNoComma-separated list of input properties to skip. Leave empty to send all properties. (shown when Data to Send is autoMapInputData)
Fields to SendfixedCollectionNo{}The attributes to write, one row per attribute. (shown when Data to Send is defineBelow)
— Field IDstringNoThe attribute name in DynamoDB.
— Field ValuestringNoThe attribute value.
Additional FieldscollectionNo{}Optional settings for the write.
— Condition ExpressionstringNoA condition that must be satisfied for a conditional upsert to succeed. See AWS PutItem API docs.
— Expression Attribute Values (eavUi)fixedCollectionNo{}Substitution tokens for attribute names in an expression. Only needed when Condition Expression is set.
— — AttributestringNoThe token used in the expression, for example :status.
— — TypeoptionsNoSThe DynamoDB attribute type of the value.
Options: N (number), S (string)
— — ValuestringNoThe value substituted for the token.
— Expression Attribute Names (eanUi)fixedCollectionNo{}Substitution tokens for attribute names in an expression.
— — KeystringNoThe token used in the expression, for example #name.
— — ValuestringNoThe real attribute name the token stands for.

Item: Delete

ParameterTypeRequiredDefaultDescription
Table NamestringYesThe DynamoDB table name. You can find table names in the AWS DynamoDB console.
KeysfixedCollectionNo{}Item’s primary key. For a simple primary key, provide only the partition key. For a composite key, provide both partition key and sort key.
— KeystringNoThe key attribute name.
— TypeoptionsNoSThe DynamoDB attribute type of the key.
Options: B (binary), N (number), S (string)
— ValuestringNoThe key value to match.
ReturnoptionsNoNONEWhether to return the item attributes as they appeared before deletion.
Options: ALL_OLD (return the content of the old item), NONE (nothing is returned)
SimplifybooleanNotrueWhether to return a simplified version of the response instead of the raw data. (shown when Return is ALL_OLD)
Additional FieldscollectionNo{}Optional settings for the delete.
— Condition ExpressionstringNoA condition that must be satisfied for a conditional delete to succeed.
— Expression Attribute Names (eanUi)fixedCollectionNo{}Substitution tokens for attribute names in an expression.
— — KeystringNoThe token used in the expression, for example #name.
— — ValuestringNoThe real attribute name the token stands for.
— Expression Attribute Values (expressionAttributeUi)fixedCollectionNo{}Substitution tokens for attribute values in an expression. Only needed when Condition Expression is set.
— — AttributestringNoThe token used in the expression, for example :status.
— — TypeoptionsNoSThe DynamoDB attribute type of the value.
Options: N (number), S (string)
— — ValuestringNoThe value substituted for the token.

Item: Get

ParameterTypeRequiredDefaultDescription
Table NamestringYesThe DynamoDB table name. You can find table names in the AWS DynamoDB console.
KeysfixedCollectionNo{}Item’s primary key. For a simple primary key, provide only the partition key. For a composite key, provide both partition key and sort key.
— KeystringNoThe key attribute name.
— TypeoptionsNoSThe DynamoDB attribute type of the key.
Options: B (binary), N (number), S (string)
— ValuestringNoThe key value to match.
SelectoptionsNoALL_ATTRIBUTESWhich attributes to return.
Options: ALL_ATTRIBUTES, ALL_PROJECTED_ATTRIBUTES, SPECIFIC_ATTRIBUTES (select them in Attributes to Select under Additional Fields)
SimplifybooleanNotrueWhether to return a simplified version of the response instead of the raw data. (shown when Select is ALL_PROJECTED_ATTRIBUTES, ALL_ATTRIBUTES)
Additional FieldscollectionNo{}Optional settings for the read.
— Attributes to SelectstringNoComma-separated list of attributes to retrieve (projection expression).
— Expression Attribute Names (eanUi)fixedCollectionNo{}Substitution tokens for attribute names in an expression.
— — KeystringNoThe token used in the expression, for example #name.
— — ValuestringNoThe real attribute name the token stands for.
— Read TypeoptionsNoeventuallyConsistentReadType of read to perform on the table.
Options: stronglyConsistentRead, eventuallyConsistentRead

Item: Get Many

ParameterTypeRequiredDefaultDescription
Table NamestringYesThe DynamoDB table name. You can find table names in the AWS DynamoDB console.
ScanbooleanNofalseWhether to use Scan (reads all items) or Query (uses key condition). Scan is less efficient but does not require a key condition expression.
Key Condition ExpressionstringYesCondition to determine items to retrieve. Must perform an equality test on a single partition key value, e.g. “partitionKeyName = :partitionkeyval”. (shown when Scan is false)
Filter ExpressionstringNoA filter expression to apply during Scan. Items that do not satisfy this expression are discarded. Leave empty to return all items. (shown when Scan is true)
Expression Attribute ValuesfixedCollectionNo{}Substitution tokens for attribute values in an expression.
— AttributestringNoThe token used in the expression, for example :id.
— TypeoptionsNoSThe DynamoDB attribute type of the value.
Options: N (number), S (string)
— ValuestringNoThe value substituted for the token.
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo50Max number of results to return. Accepts 1–100. (shown when Return All is false)
SelectoptionsNoALL_ATTRIBUTESWhich attributes to return.
Options: ALL_ATTRIBUTES, ALL_PROJECTED_ATTRIBUTES, COUNT, SPECIFIC_ATTRIBUTES (select them in Attributes to Select under Options)
SimplifybooleanNotrueWhether to return a simplified version of the response instead of the raw data. (shown when Select is ALL_PROJECTED_ATTRIBUTES, ALL_ATTRIBUTES, SPECIFIC_ATTRIBUTES)
OptionscollectionNo{}Optional settings for the Scan or Query.
— Index NamestringNoName of the secondary index to query. Can be any local or global secondary index on the table.
— Attributes to SelectstringNoComma-separated list of attributes to retrieve. These can include scalars, sets, or elements of a JSON document.
— Filter ExpressionstringNoConditions applied after the Query but before data is returned. Items that do not satisfy this expression are not returned. (shown when Scan is false)
— Expression Attribute Names (eanUi)fixedCollectionNo{}Substitution tokens for attribute names in an expression.
— — KeystringNoThe token used in the expression, for example #name.
— — ValuestringNoThe real attribute name the token stands for.

All Operations

ParameterTypeRequiredDefaultDescription
Max ConcurrencynumberNo10Maximum number of items to process concurrently. Accepts 1–100.

Output Data

Results are merged onto the input item’s JSON, so the properties you started with remain available alongside the DynamoDB attributes. The Document Client marshals DynamoDB attribute types to native JSON, so values arrive as plain strings, numbers, booleans, lists and maps — not as {"S": "..."} wrappers. Binary data on the input item is forwarded.

OperationOutput
upsertOne item per input item, carrying the attributes that were written.
getOne item per input item, carrying the item’s attributes. A key that matches nothing produces the input item unchanged.
deleteOne item per input item. With Return set to NONE the item carries success: true; with ALL_OLD it carries the attributes as they were immediately before deletion.
getAllFans out — one output item per row returned. A Scan or Query that matches nothing emits one item, which is the input item passed through unchanged.
getAll with Select = COUNTOne item per input item carrying Count and ScannedCount instead of rows.

With Simplify on (the default), attributes with no value are dropped from the result; turn it off to keep the response exactly as DynamoDB returned it.

Reference attributes downstream by name, e.g. {{ $json.userId }} or {{ $json.Count }}.

Usage Examples

  • Get a user record from DynamoDB by primary key
  • Create or update an item in a DynamoDB table
  • Scan all items in a DynamoDB table
  • Query items using a key condition expression
  • Delete an item from DynamoDB by partition key and sort key

Example Configuration

Write the incoming item straight into a table, dropping workflow-only properties:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "upsert",
    "tableName": "users",
    "dataToSend": "autoMapInputData",
    "inputsToIgnore": "_error,_metadata"
  }
}

Write named attributes only, and refuse to overwrite an existing row:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "upsert",
    "tableName": "users",
    "dataToSend": "defineBelow",
    "fieldsUi": {
      "fieldValues": [
        { "fieldId": "userId", "fieldValue": "{{ $json.id }}" },
        { "fieldId": "email", "fieldValue": "{{ $json.email }}" },
        { "fieldId": "status", "fieldValue": "active" }
      ]
    },
    "additionalFields": {
      "conditionExpression": "attribute_not_exists(userId)"
    }
  }
}

Read one item by composite key, strongly consistent:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "get",
    "tableName": "orders",
    "select": "ALL_ATTRIBUTES",
    "simple": true,
    "keysUi": {
      "keyValues": [
        { "key": "customerId", "type": "S", "value": "{{ $json.customerId }}" },
        { "key": "orderDate", "type": "S", "value": "{{ $json.orderDate }}" }
      ]
    },
    "additionalFields": {
      "readType": "stronglyConsistentRead",
      "projectionExpression": "customerId, orderDate, total"
    }
  }
}

Query a partition and page through every match:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "getAll",
    "tableName": "orders",
    "scan": false,
    "keyConditionExpression": "customerId = :cid",
    "eavUi": {
      "eavValues": [
        { "attribute": ":cid", "type": "S", "value": "{{ $json.customerId }}" }
      ]
    },
    "returnAll": true,
    "select": "ALL_ATTRIBUTES",
    "simple": true
  }
}

Scan a table with a filter, capped at 50 rows:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "getAll",
    "tableName": "users",
    "scan": true,
    "filterExpression": "#st = :active",
    "eavUi": {
      "eavValues": [
        { "attribute": ":active", "type": "S", "value": "active" }
      ]
    },
    "returnAll": false,
    "limit": 50,
    "select": "ALL_ATTRIBUTES",
    "options": {
      "eanUi": {
        "eanValues": [
          { "key": "#st", "value": "status" }
        ]
      }
    }
  }
}

Query a global secondary index and return only the matching count:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "getAll",
    "tableName": "orders",
    "scan": false,
    "keyConditionExpression": "email = :email",
    "eavUi": {
      "eavValues": [
        { "attribute": ":email", "type": "S", "value": "{{ $json.email }}" }
      ]
    },
    "select": "COUNT",
    "options": {
      "indexName": "email-index"
    }
  }
}

Delete by key and keep a copy of what was removed:

{
  "type": "aws_dynamodb",
  "parameters": {
    "resource": "item",
    "operation": "delete",
    "tableName": "users",
    "keysUi": {
      "keyValues": [
        { "key": "userId", "type": "S", "value": "{{ $json.id }}" }
      ]
    },
    "returnValues": "ALL_OLD",
    "simple": true
  }
}

Error Handling

ModeBehavior
stopHalts workflow on first error
continueSkips failed items, passes successful ones through
errorPortRoutes failed items to Error output port

Tips

Create, read, update, and delete items in AWS DynamoDB NoSQL tables using the AWS SDK.

Frequently asked questions

What credential does this node require, and how is it different from a generic AWS credential?

The node uses the AWS DynamoDB credential type (`awsDynamoDbApi`), which is scoped specifically to DynamoDB rather than a broad AWS credential. You'll need an IAM user or role with DynamoDB permissions (e.g. `dynamodb:GetItem`, `dynamodb:PutItem`) and supply the access key, secret, and region through that credential type in BusyBot.

How does the node handle DynamoDB's attribute type format — do I have to write `{S: 'hello'}` myself?

No. The node uses the AWS SDK v3 DynamoDB Document Client, which automatically marshals between JavaScript native types and DynamoDB's internal attribute format. You pass plain strings, numbers, booleans, and objects; the Document Client converts them to and from the `{S: ...}`, `{N: ...}` representation transparently.

What operations are available, and which DynamoDB API calls do they map to?

There are four operations: create/update maps to `PutItem`, get single item maps to `GetItem`, get many items uses `Scan` or `Query` (with pagination support), and delete maps to `DeleteItem`. If you need conditional writes or reads, you can supply condition expressions, filter expressions, and projection expressions through the node's parameters.

The node has two outputs — Output and Error. When does execution go to the Error output instead of failing the workflow?

When DynamoDB returns an error (for example, a `ConditionalCheckFailedException` from a failed condition expression, or a missing table), the node routes that run to the Error output rather than throwing and halting the whole workflow. This lets you branch on failure — for instance, catching a condition check failure to handle an already-existing record differently.

Can I query a DynamoDB Global Secondary Index (GSI) instead of the primary key?

Yes. When using the get-many operation in Query mode, the node supports secondary index queries. You specify the index name alongside your key condition expressions and, optionally, filter expressions and expression attribute names/values to narrow results further.

Build with the AWS DynamoDB node

Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need AWS DynamoDB credentials first.

Open BusyBot

Last updated . Spotted something wrong? Tell us.