Each item on my dynamoDB looks like the following
{
"status": "pending",
"ccNumber": "0012",
"created": "2018-03-07T16:42:02-04:00",
"id": "14664d28-ef41-4228-99b5-6381a2a69f62",
"amount": "12",
"invoice": "71200",
"customerId": "00000"
}
I'm trying to update a field on this specific record and also adding more items. here's my params variable
const params = {
TableName: this.table,
Key: { id },
UpdateExpression: `set tranStatus = :status, updated = :updated, authTransacId = :authTransacId, avsResponse = :avsResponse, authCode = :authCode`,
ExpressionAttributeValues: {
':status': data.status,
':updated': moment().utcOffset(-4).format(),
':authTransacId': data.transId,
':avsResponse': data.avsResponse,
':authCode': data.authCode
},
ReturnValues: "UPDATED_NEW"
}
I can't seem to find the issue with the new field: updated