# Debugging Auth0 Actions

**URL:** <https://community.auth0.com/t/debugging-auth0-actions/69733>\
**Category:** Get Help\
**Tags:** actions, debug\
**Created:** [September 15, 2021, 4:24pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733 "2021-09-15T16:24:54Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ben\_wozniak](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/ben_wozniak/32/20554_2.png) [@ben\_wozniak](https://community.auth0.com/u/ben_wozniak)\
**Post date:** [September 15, 2021, 4:24pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/1 "2021-09-15T16:24:55Z")

</div>

Hi,

Is there any way to debug Auth0 actions? The Actions documentation states “Nothing is worse than getting an error and not having the ability to track down the problem.” I agree! Unfortunately, Actions does not seem to provide this functionality.

How can I debug my actions to see if, for example, claims are being appended to my id token? Is there any debugger I can attach as there was with Rules? Thank you!

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 15, 2021, 9:33pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/3 "2021-09-15T21:33:53Z")

</div>

Hi @ben_wozniak,

I understand that you’re looking for clarification on debugging Auth0 Actions.

The best way to test whether your Action is working is by navigating to your Custom Action and pressing the **Test** button, and then the **Try** button located on the left column of the IDE.

Doing so will allow you to simulate a call to your login flow and use test parameters and see the test results.

For now, you may find our [Post-login template](https://auth0.com/docs/actions/triggers/post-login#add-user-roles-to-tokens) for adding claims to tokens useful.

Please let me know if you have any other questions. I’d be happy to clarify.

---

<div class="post-metadata">

**Author:** ![ben\_wozniak](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/ben_wozniak/32/20554_2.png) [@ben\_wozniak](https://community.auth0.com/u/ben_wozniak)\
**Post date:** [September 16, 2021, 12:58pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/4 "2021-09-16T12:58:15Z")

</div>

Hi @rueben.tiow ,

Thanks for the response. Unfortunately the Test button does not provide any information about the run, nor does it support debugging. I want to see if the Action successfully adds the claims I am expecting it to. Is there any way to debug an action?

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 16, 2021, 6:53pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/5 "2021-09-16T18:53:41Z")

</div>

Hi @ben_wozniak,

Could you please clarify whether you can see the **Test Results**?

Here is a screenshot of my custom Action that I executed. As shown, there were no errors, and I obtained my desired result. I also had a `console.log` statement at the end just for clarity that my action was completed.

 ![image](https://global.discourse-cdn.com/auth0/original/3X/b/6/b658bc5b9f42b52eb0d765fa19af60a77b294334.png)

 ![image](https://global.discourse-cdn.com/auth0/original/3X/d/4/d4d99cd6a72811a1ebd7c9708cdf69be58f80c7f.png)

---

<div class="post-metadata">

**Author:** ![ben\_wozniak](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/ben_wozniak/32/20554_2.png) [@ben\_wozniak](https://community.auth0.com/u/ben_wozniak)\
**Post date:** [September 16, 2021, 7:06pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/6 "2021-09-16T19:06:58Z")

</div>

Interesting, I was using console logs in the past, but never saw them. I now see the reason why. I had some values on the event I was not setting which was causing my action to short-circuit before it got to my console log, or the error in the script itself. So, I can now see that the logs are visible.

Thank you for the help and the quick response!

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 16, 2021, 7:15pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/7 "2021-09-16T19:15:19Z")

</div>

Hi @ben_wozniak,

That’s great to hear that you figured it out! We’ve all been there.

Please let me know if there’s anything else I can help with.

Have a great rest of your day!

---

<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:** [October 1, 2021, 7:15pm UTC](https://community.auth0.com/t/debugging-auth0-actions/69733/8 "2021-10-01T19:15:41Z")

</div>

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