# Authorization Extension API Respond 500 Internal Server Error Randomly

**URL:** <https://community.auth0.com/t/authorization-extension-api-respond-500-internal-server-error-randomly/8572>\
**Category:** Get Help\
**Tags:** server-error, 500, authorization-extens\
**Created:** [October 25, 2017, 1:02pm UTC](https://community.auth0.com/t/authorization-extension-api-respond-500-internal-server-error-randomly/8572 "2017-10-25T13:02:26Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ivan.invigor](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@ivan.invigor](https://community.auth0.com/u/ivan.invigor)\
**Post date:** [October 25, 2017, 1:02pm UTC](https://community.auth0.com/t/authorization-extension-api-respond-500-internal-server-error-randomly/8572/1 "2017-10-25T13:02:26Z")

</div>

Hi,  
I’m randomly receiving 500 Internal server Error when using Authorization Extension API in various scenarios with the following error messages.

* * *

500 Internal Server Error

Error: Script generated an unhandled asynchronous exception.

- When adding users to roles
- When loading all permissions, roles

* * *

500 Internal Server Error

Error: socket hang up\n at createhangUpError (\_http\_client.js:213:15)\n at Socket.socketOnEnd (\_http\_cli …

- When try to load all roles (https://{ExtensionURL}/\*\*\*\*\*\*\*/api/roles)

Please let me know if you need further details on API calls triggering these errors. As I found the errors are coming very inconsistently and randomly, I would like to understand the meaning of these errors.

I would also like to understand the stability of Authorization Extension, because it also shows errors occasionally when I open Authorization Extension UI.

```
{
  "code": 500,
  "error": "Script generated an unhandled asynchronous exception.",
  "details": "Error: Blocked event loop",
  "name": "Error",
  "message": "Blocked event loop",
  "stack": "Error: Blocked event loop\n at <anonymous>:1:38\n at nextTickCallbackWith0Args (node.js:489:9)\n at process._tickDomainCallback (node.js:459:13)"
}

```

---

<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:** [March 2, 2018, 5:57am UTC](https://community.auth0.com/t/authorization-extension-api-respond-500-internal-server-error-randomly/8572/2 "2018-03-02T05:57:07Z")

</div>


