Check Auth0 API Status using NodeJS

Hi,
I have an application that logs the user in via Auth0. The user is redirected to a web browser to log in. I want to do a check to verify the service is available before sending the user so the user can be alerted if the service is not available to them for one reason or another. Is there a call to the Auth0 API that can be done without a token to verify that my domain is reachable to the client before sending them to the browser to log in? I’m sure I could ping it but that doesn’t definitely prove the service is available looking for a more detailed response.

Thanks
Scott

Hi @scottcp,

Welcome to the Auth0 Community!

There is an Atom/RSS feed that you can subscribe to for status updates. It’s listed at the bottom of the https://status.auth0.com/ page.

Given the authentication services generally have 99.999%+ uptime, I wouldn’t suggest making a call every time a user authenticates.

Thanks Dan,

I appreciate your help. I was looking more for a JSON response for my specific server. If that’s not possible I suppose I can parse the Atom feed. How up-to-date is the status page? I’m really looking for something to verify that the information is reachable. If there is a routing issue or other type of issue that is not recognized by the status page.

The Status Page is updated once an outage is known, so it wouldn’t address the use case you listed.

I wouldn’t recommend doing what you are describing, regardless.

Thank you for your response, can you describe what the best practice would be for a backup authentication should auth0 become unavailable? As of course at some point is inevitable for it to occur.

1 Like

Most of our customers don’t have a failover auth service in place. Like I mentioned, our services have nearly zero downtime.

If you require more control, you may want to consider a private cloud deployment.

Thank you for your answers, Dan! It seems a bit odd that no one has created and you wouldn’t encourage a backup plan. I’ve never used a service a backup wouldn’t make more robust by adding a failover. It doesn’t seem responsible to not have a backup plan. I’m going to design something using the current API. Regardless of the fact that you might not suggest this, it would most definitely be helpful to know if there is a technical or security reason why you would not suggest this.

I don’t see any advantages of downtime for private cloud deployments.

Just to be clear, that’s not what I said.

I said many of our customers don’t find it necessary due to the near-zero downtime.

From the private cloud one-pager:

Private deployments of Auth0 enable enterprise teams with:

  • Fully isolated pre-production environments
    that update independently from the
    production environment
  • Scheduled updates of the Auth0 platform on
    your timelines with the ability to roll back
    releases if necessary
  • Hardened releases, validated by millions of
    customers in the public cloud before they
    touch your secure environment

I appreciate your time Dan, you are correct, you did say that most of your customers don’t have a failover auth service in place and I apologize misreading that. I’d still like to go with a way to do this that directs our login to a backcup/failover service completely separate from Auth0 for better autonomy of the services. I see there is not a direct way to detect if the service is available, I appreciate your time. Have a great day!

1 Like

Thanks Scott!

Please let us know if you run into anything else. Cheers!

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