Last active
October 19, 2017 15:47
-
-
Save notionquest/8f4b52b217a52b59330093750c84d3b7 to your computer and use it in GitHub Desktop.
Describe table present in dynamodb local
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
//Run the below script on http://localhost:8000/shell/ | |
var dynamodb = new AWS.DynamoDB({ | |
region: 'us-east-1', | |
endpoint: "http://localhost:8000" | |
}); | |
var params = { | |
TableName: "Movies" | |
}; | |
function doPrint(response) { | |
if (response.error) ppJson(response.error); // an error occurred | |
else { | |
ppJson(response.data); // successful response | |
} | |
} | |
console.log("Describe table ..."); | |
dynamodb.describeTable(params) | |
.on('complete', doPrint) | |
.send(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment