# SPA Application loginWithRedirect return boolean instead of Universal Login

**URL:** <https://community.auth0.com/t/spa-application-loginwithredirect-return-boolean-instead-of-universal-login/118362>\
**Category:** Get Help\
**Tags:** new-universal-login-experience, login-experience\
**Created:** [October 11, 2023, 10:08pm UTC](https://community.auth0.com/t/spa-application-loginwithredirect-return-boolean-instead-of-universal-login/118362 "2023-10-11T22:08:56Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![renan\_zelaya](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/renan_zelaya/32/51596_2.png) [@renan\_zelaya](https://community.auth0.com/u/renan_zelaya)\
**Post date:** [October 11, 2023, 10:08pm UTC](https://community.auth0.com/t/spa-application-loginwithredirect-return-boolean-instead-of-universal-login/118362/1 "2023-10-11T22:08:56Z")

</div>

Hi there,

I am currently creating a React SPA that will authenticate users and create access tokens to make requests to an API.

In order to create the SPA, I am using the following Terraform code. When I create this application I tried it and when I call `loginWithRedirect` and it takes me to a page returning `true` instead of the Universal Login page.

I created another SPA traditionally in the Application page and it worked as it should.

I did notice that the url that I was taken was `<tenant_domain>/u/login` and with the TF-created app, it was `<tenant_domain>/login`

```plaintext
resource "auth0_client" "default" {
  name = "MyWebApp"

  allowed_clients = []
  allowed_logout_urls = ["http://localhost:4040"]
  allowed_origins = []
  app_type = "spa"
  callbacks = ["http://localhost:4040/callback"]
  client_aliases = []
  cross_origin_auth = false
  custom_login_page = true
  is_first_party = true
  is_token_endpoint_ip_header_trusted = false
  oidc_conformant = true
  sso_disabled = false
  web_origins = ["http://localhost:4040"]
  grant_types = [
    "authorization_code",
    "implicit",
    "refresh_token",
    "password",
    "http://auth0.com/oauth/grant-type/password-realm",
  ]

  jwt_configuration {
    alg = "RS256"
    lifetime_in_seconds = 3600
    secret_encoded = false
  }

  native_social_login {
    apple {
      enabled = false
    }
    facebook {
      enabled = false
    }
  }

  refresh_token {
    expiration_type = "expiring"
    leeway = 0
    token_lifetime = 2592000
    idle_token_lifetime = 1296000
    infinite_token_lifetime = false
    infinite_idle_token_lifetime = false
    rotation_type = "rotating"
  }
}

resource "auth0_client_credentials" "default" {
  client_id = auth0_client.default.id

  authentication_method = "none"
}

```

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [October 17, 2023, 8:36pm UTC](https://community.auth0.com/t/spa-application-loginwithredirect-return-boolean-instead-of-universal-login/118362/3 "2023-10-17T20:36:16Z")

</div>

Hi @renan_zelaya,

Welcome to the Auth0 Community!

I have a few questions:

- What is the path of the page that is returning “true”?
- Is the callback URL the same for both apps?
- Is it the same codebase?

---

<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:** [November 8, 2023, 4:10pm UTC](https://community.auth0.com/t/spa-application-loginwithredirect-return-boolean-instead-of-universal-login/118362/4 "2023-11-08T16:10:00Z")

</div>

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