@novo-x/aws-dynamo
TypeScript icon, indicating that this package has built-in type declarations

1.0.8 • Public • Published

AWS DynamoDB Service

Available methods

  • getDocumentsByIndex: retrieves a list of documents by index
  • getDocumentById: retrieves a document by id
  • saveDocument: saves document
  • updateAwsConfig: updates the aws config

Usage examples

yarn add @novo-x/aws-dynamo

import {DynamoDB} from "@novo-x/aws-dynamo"

const MyService = new DynamoDB(/* optional config object */);

MyService.updateAwsConfig({
    // ... AWS config
})

const documentsByIndex = MyService.getDocumentsByIndex(
    'my_index', // indexName
    'my_key', // indexKey
    'index_value', // indexValue,
    'my_table' // tableName
);

const documentById = MyService.getDocumentById(
    'my_key', // keyName
    '123456789', // id
    'my_table' // tableName
)

const saved = MyService.saveDocument(
    {
        name: 'John Doe',
        age: 59
    }, // itemData,
    tableName // tableName
)

Dependencies

aws-sdk

Package Sidebar

Install

npm i @novo-x/aws-dynamo

Weekly Downloads

8

Version

1.0.8

License

ISC

Unpacked Size

77.7 kB

Total Files

6

Last publish

Collaborators

  • lautarobruno
  • agustin-novolabs
  • novo-tincho
  • nicolas.novolabs
  • mati-novolabs
  • alejitowow
  • nahuelprieto