@webiny/api-apw-scheduler-so-ddb
Version: 
The DynamoDB storage operations for scheduler action feature in the Webiny APW API.
29 lines (27 loc) • 605 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.createTable = void 0;
var _toolbox = require("@webiny/db-dynamodb/toolbox");
const createTable = ({
  table,
  documentClient
}) => {
  return new _toolbox.Table({
    name: String(table || process.env.DB_TABLE),
    partitionKey: "PK",
    sortKey: "SK",
    DocumentClient: documentClient,
    indexes: {
      GSI1: {
        partitionKey: "GSI1_PK",
        sortKey: "GSI1_SK"
      }
    },
    autoExecute: true,
    autoParse: true
  });
};
exports.createTable = createTable;
//# sourceMappingURL=table.js.map