Why so many auth.me calls to Xano?

I’m trying to troubleshoot an issue some users are having where a page is waiting on a response from Xano and it never comes. In my search for what is causing this, I’ve noticed instances where the auth.me endpoint is called several times when changing pages. In this instance below it was called 4x.

I’m using the Xano auth plugin. Is this normal? Could this be causing some kind of rate-limit issue? I’m on a paid plan with Xano, so there shouldn’t be a rate limit.

Just noticing that on this particular page change, there are 5 endpoints called for data on the new page. 4 of them require authentication. Is this why there were 4 auth/me calls? If so, why isn’t this more efficient?

Hi @ericp :wave:

Were you able to uncover what was causing this?

Just created a Xano + WeWeb from scratch and didn’t see the issue.

My flow looks like this:

  • login with email and password on Login page in WeWeb
  • successful login redirects to user profile page
  • user profile page displays personalized message to the user

In my WeWeb logs, it looks like this:

In my Xano request history, it looks like this:

Is it possible you are triggering several workflows or several login calls on a single form or on a form container and a button inside that form at the same time for example?

Thank you Joyce for looking into this. It appears the issue occurs when an API call to Xano that has user authentication enabled triggers an additional auth.me call from WeWeb. My login flow redirects to a page that has information about the user’s company which is stored in a ‘Company’ table that has user auth enabled. As you can see from the Xano log attached, it’s only occurring in the published app, not inside the WeWeb editor.

I see this on other pages within the app where a logged in user goes to a page that has several api calls to pull data from different tables that are secured and I’ll see additional auth.me calls in the Xano log even though the user is logged in.

And if it helps investigating this on your side, I have disabled automatic fetching of collections and use workflow actions to fetch as-needed. So maybe the manual fetch action isn’t including the auth-token??

Ah ok, got it! Let me ask the tech team if that’s the expected behavior or something we should be optimizing on our side.

1 Like