JWT malformed from Vue SPA using auth0-spa-js library

Hey there @kristen-s welcome to the community, and thanks for the detailed description of what you’re experiencing :smile:

Looking at our quickstart for calling an API leads me to believe you’d want to add the audience to your Auth0ClientOptions like:

const options: Auth0ClientOptions = {
          domain: <tenant>.us.auth0.com,
          clientId: <clientId>,
          audience: <your_api_identifier>,
          authorizationParams: {
              redirect_uri: http://localhost:<port>/,
          }
      };

You are correct though in that you will need an audience in the context of using it against your Express server:

Keep us posted!

1 Like