An AWS DynamoDB client wrapped to provide consistent logging and other services.
npm install @veterancrowd/wrapped-dynamodb-client[//]: # ' DO NOT EDIT THIS NOTICE '
[//]: # ' This code and all related intellectual property is owned by '
[//]: # ' Veteran Crowd Rewards, LLC. It is not to be disclosed, copied '
[//]: # ' or used without written permission. '
[//]: # ' * '
Kind: static class of wrapped-dynamodb-client
* .WrappedDynamoDbClient
* [new exports.WrappedDynamoDbClient([options])](#new_module_wrapped-dynamodb-client.WrappedDynamoDbClient_new)
* _item_
* .deleteItem(tableName, key) ⇒ Promise.<object>
* .deleteItems(tableName, keys) ⇒ Promise.<number>
* [.getItem(tableName, key, [attributes])](#module_wrapped-dynamodb-client.WrappedDynamoDbClient+getItem) ⇒ Promise.<object>
* .purgeItems(tableName, keys) ⇒ Promise.<number>
* .putItem(tableName, item) ⇒ Promise.<object>
* .putItems(tableName, items) ⇒ Promise.<Array>
* .query(tableName, options) ⇒ Promise.<object>
* .scan(tableName, options) ⇒ Promise.<object>
* .transactDeleteItems(tableName, keys) ⇒ Promise.<Array>
* .transactPutItems(tableName, items) ⇒ Promise.<Array>
* _table_
* [.createTable(tableName, [options])](#module_wrapped-dynamodb-client.WrappedDynamoDbClient+createTable) ⇒ Promise.<object>
* .deleteTable(tableName) ⇒ Promise.<object>
* .describeTable(tableName) ⇒ Promise.<object>
| Param | Type | Description |
| --- | --- | --- |
| [options] | object | Options. |
| [options.logger] | object | Logger instance (default is global console object). Must have info, error & debug methods |
| [options.logInternals] | boolean | Log AWS client internals (default is false). |
| [options.config] | object | DynamoDBClientConfig object. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - WaiterResult object.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| key | object | Item object (only the key is required). |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<number> - Array of responses from chunked batchWrite operations.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| keys | Array.<object> | Array of item objects (only the key is required). |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - - GetItemCommandOutput object.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| key | object | Item object (only the key is required). |
| [attributes] | string \| Array.<string> | Comma-delimited list or string array of attributes to retrieve. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<number> - Total items purged from table.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| keys | Array.<string> | Item keys. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - - PutItemCommandOutput object.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| item | object | Item object. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<Array> - Array of responses from chunked batchWrite operations.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| items | Array.<object> | Array of item objects. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - QueryCommandOutput object.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| options | object | QueryCommandInput object. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - ScanCommandOutput object.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| options | object | ScanCommandInput object. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<Array> - Array of responses from chunked batchWrite operations.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| keys | Array.<object> | Array of item keys. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<Array> - Array of responses from chunked batchWrite operations.
Category: item
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| items | Array.<object> | Array of item objects. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - WaiterResult object.
Category: table
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
| [options] | object | CreateTableCommandInput object. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - - Deletion status
Category: table
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
Kind: instance method of WrappedDynamoDbClient
Returns: Promise.<object> - - TableDescription}
Category: table
| Param | Type | Description |
| --- | --- | --- |
| tableName | string | Table name. |
[//]: # ' DO NOT EDIT THIS NOTICE '
[//]: # ' This code and all related intellectual property is owned by '
[//]: # ' Veteran Crowd Rewards, LLC. It is not to be disclosed, copied '
[//]: # ' or used without written permission. '
[//]: # ' * '
---
See more great templates and other tools on
my GitHub Profile!