Academy
⌘K
Getting Started
  • Platform Overview
  • AWS Marketplace Setup
  • Quickstart Guide
Connections
  • Overview
Workflow Builder
  • Overview
  • Nodes Catalog
Helix AI Assistant
  • Overview
Mapping Engine
  • Overview
Workflow Library
  • Overview
  • HL7
  • FHIR
  • Insurance
  • Agentic
  • Mapping
Security & Infrastructure
  • Architecture
  • HIPAA Compliance
  • Performance & Scalability
← Back to ConnectHealth
Get Started
Back to Nodes
AWS1 input → 2 outputs

DynamoDB Create

payload (object)payload.item (object)payload.tableN… (string)AWSDynamoDB CreateOutput 1payload.success (boolean)payload.tableN… (string)dynamodb.opera… (string)Output 2payload.success (boolean)payload.error (string)payload.errorT… (string)Data flowProperty

Inserts or replaces an item in a DynamoDB table. Used in ConnectHealth to store OAuth tokens, session data, FHIR resource cache, and audit logs.

Inputs

payload object
The item to save. The full msg.payload is used as the item if payload.item is not set.
payload.item object
Explicit item — takes priority over raw msg.payload. Must include all key attributes.
payload.tableName string
Overrides the Table Name set in the node config.

Outputs

Output 1 — Success
payload.success boolean
true when the item was written successfully.
payload.tableName string
The table the item was written to.
Output 2 — Error
payload.errorType string
Human-readable error category (e.g. Table Not Found, Expression Error).
payload.solution string
Suggested fix for the error.

How to Use

  1. Select an AWS config node and enter the Table Name.
  2. Choose Item Source: wire a previous node's output (msg.payload) or paste a static Inline JSON object.
  3. Make sure the item object includes all key attributes — both partition key and sort key if your table has one.
  4. Add a Condition (like Safe insert) if you want to prevent overwriting existing data.
  5. Wire Output 2 to catch AWS errors (wrong table, condition failed, auth failure).

Item Requirements

The item you provide must include the table's full primary key. If your table has both a partition key (id) and a sort key (sk), both attributes must be present in the item object. Missing a key attribute results in a ValidationException.

Warning: Create completely replaces an existing item with the same key. Any attributes not in your new object are silently deleted. Use DynamoDB Update to change only specific fields.

Examples

Store a new Epic OAuth token after a successful authentication, with a safe insert condition:

msg.payload = {
  item: {
    id: "epic-hospital-A",
    sk: "oauth_token",
    accessToken: "eyJhbGci...",
    refreshToken: "dGhpcyBp...",
    expiresAt: 1714000000,
    scope: "patient/*.read",
    storedAt: Date.now()
  }
};
// ConditionMode = "Safe insert"

Best Practices

  • Always include storedAt: Date.now() so you have an audit trail of when the item was written.
  • Use the Safe insert condition when initializing tokens to prevent race conditions.
  • Use DynamoDB Update instead of Create when you want to refresh tokens — Create silently deletes attributes you omit.