Created
October 15, 2018 04:02
-
-
Save appwiz/60fdcbeb97b8aaef2b8f5e804dc3261b to your computer and use it in GitHub Desktop.
Voice Commands - API - CreateColorCommand
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "2017-02-28", | |
"operation": "PutItem", | |
"key": { | |
"id": $util.dynamodb.toDynamoDBJson($util.autoId()), | |
"timestamp": $util.dynamodb.toDynamoDBJson($util.time.nowISO8601()), | |
}, | |
"attributeValues": $util.dynamodb.toMapValuesJson($ctx.args.input), | |
"condition": { | |
"expression": "attribute_not_exists(#id) AND attribute_not_exists(#timestamp)", | |
"expressionNames": { | |
"#id": "id", | |
"#timestamp": "timestamp", | |
}, | |
}, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment