text: const AWS = require("aws-sdk");
  const dynamoDB = new AWS.DynamoDB.DocumentClient({
    region: process.env.DYNAMODB_REGION,
  });
  
  exports.handler = (event, context, callback) => {
    const params = {
      TableName: process.env.DYNAMODB_TABLE,
    };
  
    dynamoDB.scan(params, function (err, data) {
      if (err) {
        console.log("Error:", err);
      } else {
        const response = {
          statusCode: 200,
          headers: {
            "Access-Control-Allow-Headers": "*",
            "Access-Control-Allow-Origin": "*",
            "Access-Control-Allow-Methods": "*",
          },
          body: JSON.stringify(data),
        };
        callback(null, response);
      }
    });
  };
  