-
-
Save svngoku/f8ee53f54bcdbe8a01396f493e69f419 to your computer and use it in GitHub Desktop.
A sample user model using Dynamoose, an ORM for AWS DynamoDB with a similar API to Mongoose
This file contains hidden or 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
| const dynamoose = require('dynamoose'); | |
| let configUpdates = { | |
| region: "us-east-1", | |
| accessKeyId: 'key123', | |
| secretAccessKey: 'secret123' | |
| } | |
| dynamoose.AWS.config.update(configUpdates); | |
| let tableName = 'Project.TestEnv.ModelName' | |
| let User = dynamoose.define(tableName, { | |
| firstName: String, | |
| lastName: String, | |
| emailAddress: String | |
| }) | |
| module.exports = User; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment