# Action modules not working

**URL:** <https://community.auth0.com/t/action-modules-not-working/54631>\
**Category:** Get Help\
**Tags:** actions\
**Created:** [December 10, 2020, 2:43pm UTC](https://community.auth0.com/t/action-modules-not-working/54631 "2020-12-10T14:43:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ChristopherDennis](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/christopherdennis/32/26179_2.png) [@ChristopherDennis](https://community.auth0.com/u/ChristopherDennis)\
**Post date:** [December 10, 2020, 2:43pm UTC](https://community.auth0.com/t/action-modules-not-working/54631/1 "2020-12-10T14:43:50Z")

</div>

We’re trying to create an action that reads records from AWS DynamoDB. We’ve added the aws-sdk module to the action modules and we’re getting an error from const AWS = require(‘aws-sdk@2.2.30’);

```
{
  "payload": {
    "error": {
      "code": "MODULE_NOT_FOUND",
      "message": "Cannot find module 'aws-sdk@2.2.30'\nRequire stack:\n- /data/io/node12/89dc0f34-1b88-4526-b205-b48d15c5729d/webtask.js",
      "name": "Error",
      "stack": "Error: Cannot find module 'aws-sdk@2.2.30'\nRequire stack:\n- /data/io/node12/89dc0f34-1b88-4526-b205-b48d15c5729d/webtask.js\n at Function.Module._resolveFilename (internal/modules/cjs/loader.js:966:15)\n at Function.WebtaskModule._resolveFilename (/data/sandbox/lib/module.js:100:17)\n at WebtaskModule.require (/data/sandbox/lib/module.js:171:37)\n at require (/data/sandbox/lib/module.js:208:17)\n at module.exports (/data/io/node12/89dc0f34-1b88-4526-b205-b48d15c5729d/webtask.js:16:14)\n at /data/io/node12/89dc0f34-1b88-4526-b205-b48d15c5729d/webtask.js:119:17\n at processTicksAndRejections (internal/process/task_queues.js:97:5)"
    },
    "stats": {
      "action_duration_ms": 26,
      "boot_duration_ms": 1365,
      "network_duration_ms": 11
    }
  }
}

```

It works fine from a rule just not from an action.

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [December 10, 2020, 8:35pm UTC](https://community.auth0.com/t/action-modules-not-working/54631/3 "2020-12-10T20:35:55Z")

</div>

Hi @ChristopherDennis

Welcome to the Community.

I just tested it and can confirm the issue with that version. I am seeing the same error. It looks like it is working fine with the most current version, which makes me think it is simply that version that isn’t loading. I’ll pass this along to the team running the beta and will update here with my findings.

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [December 10, 2020, 9:20pm UTC](https://community.auth0.com/t/action-modules-not-working/54631/5 "2020-12-10T21:20:59Z")

</div>

If you remove the `@2.2.30` from the require statement, and add the module in the pane on the left it should work.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [December 30, 2020, 11:08pm UTC](https://community.auth0.com/t/action-modules-not-working/54631/6 "2020-12-30T23:08:40Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
