Accidental recursion consumed all my M2M tokens instantly

Hi, I’m honestly at a bit of a loss here because somehow my custom action consumed all my M2M tokens immediately causing an interruption for my business. I recently made a change to a custom action, went to test it, and it failed with the following error:

{
  "code": 500,
  "details": "Error: Script execution time exceeded",
  "error": "Script generated an unhandled asynchronous exception.",
  "message": "Script execution time exceeded",
  "name": "Error"
}

Immediately after I received an email saying all my M2M tokens were consumed. I double checked my code and realized that I had a bug that recursively called the oauth/token endpoint causing my function to infinitely request M2M tokens.

Of course I take full responsibility for this but it seems like the only way to restore service is to pay $240 for the professional plan which comes with $5,000 M2M tokens. This is a lot for me as my business is still in its early stages and I plan to grow with Auth0. If I pay for the $35 Essentials plan will those 1,000 M2M tokens be added on top of my existing limit?

Hi @walker7811

Welcome back to the Auth0 Community!

Thank you for posting your question. I’ve checked with our documentation, and upgrading your plan to Essential won’t add 1000 M2M tokens to your existing limit. Still, it would allow you to exceed the quota for the month, so it would probably be the best solution for this month, as the quota will reset in the next month. You can read more about that here → Auth0 Quota Exceeded

Thanks
Dawid

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