# /delegation route returning 504 Gateway Time-out

**URL:** <https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025>\
**Category:** Get Help\
**Tags:** delegation, login, auth0\
**Created:** [March 25, 2021, 12:28am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025 "2021-03-25T00:28:53Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![theguy159](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/theguy159/32/13899_2.png) [@theguy159](https://community.auth0.com/u/theguy159)\
**Post date:** [March 25, 2021, 12:28am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025/1 "2021-03-25T00:28:53Z")

</div>

Hi there. We are getting a 504 Gateway timeout when trying to call the /delegation route. Not finding any info on this issue. Please help.

---

<div class="post-metadata">

**Author:** ![staff1](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/staff1/32/12715_2.png) [@staff1](https://community.auth0.com/u/staff1)\
**Post date:** [March 25, 2021, 1:02am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025/2 "2021-03-25T01:02:33Z")

</div>

Related?

I’m getting a 400 error on /delegation that was working 12 hours ago: the error is

```
{
    "error": "invalid_request",
    "error_description": "Missing principal parameter"
}

```

It’s as if my Rule isn’t working, but again, it was working 12 hours ago, per the logs. I’ve also switched to a dead-simple version based on [the tutorial](https://auth0.com/docs/integrations/call-aws-apis-and-resources-with-tokens), and debugged it; it appears to be working fine.

Maybe something is wrong with delegation?

---

<div class="post-metadata">

**Author:** ![cmcnicoll](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/cmcnicoll/32/13332_2.png) [@cmcnicoll](https://community.auth0.com/u/cmcnicoll)\
**Post date:** [March 25, 2021, 3:09am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025/3 "2021-03-25T03:09:18Z")

</div>

We are getting the principal parameter error too. And this error:

`{"error":"invalid_request","error_description":"Missing grant_type parameter"}`

We are using the Legacy Delegation Endpoint.

---

<div class="post-metadata">

**Author:** ![kristoffermatsson](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/kristoffermatsson/32/6009_2.png) [@kristoffermatsson](https://community.auth0.com/u/kristoffermatsson)\
**Post date:** [March 25, 2021, 6:18am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025/4 "2021-03-25T06:18:47Z")

</div>

Yes, a lot of our users are being logged out at the moment ☹ Seems like it started around 8-9PM 24th of Mars.

Edit. It seems to have been solved now. Looks much better in the logs

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [March 25, 2021, 9:51am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025/5 "2021-03-25T09:51:29Z")

</div>

Hey there!

Indeed we had problems with that but the issue is resolved now.

Ref:

> <https://twitter.com/auth0status/status/1374918433670901760>

---

<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:** [April 9, 2021, 9:51am UTC](https://community.auth0.com/t/delegation-route-returning-504-gateway-time-out/60025/6 "2021-04-09T09:51:44Z")

</div>

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