Error: could not unmarshal the value dynamodb

Answered by Rafal Wilinski
What's Causing This Error
The DynamoDB unmarshal
function can only accept an object (with data the structure of DynamoDB). Therefore, if you try to pass an array of these objects into the unmarshal
function, it will throw an error.
Solution: Here's How To Resolve It
To resolve the error, iterate through the array of DynamoDB objects and "unmarshall" each object individually, as shown below.
const items = [ { uId: { S: '123456789' }, date: { S: '09-06-2022' } } ]; const unmarshalled = items.map((i) => aws.dynamodb.converter.unmarshall(i));
Other Common DynamoDB Errors (with Solutions)
- DynamoDB Key element does not match the schema
- DynamoDB Code Working In Node But Not SAM
- sls dynamodb install not working
- dynamodb validation error detected
- Boto3 DynamoDB KeyError
- DynamoDB Duplicate Key Error
- Float types are not supported. Use decimal types instead.
- DynamoDB failedbatch retry
- One or more parameter values were invalid: some AttributeDefinitions are not used
- DynamoDB Update Not Working
- DynamoDB internal error
- DynamoDB scan filter not working
- could not lookup table in dynamodb
- DynamoDB type item is not supported
Dynobase is a Professional GUI Client for DynamoDB
Try 7-day free trial. No credit card needed.
Product Features
DynamoDB Tools
DynamoDB Info
© 2025 Dynobase