Hi! i managed to enable passkey through the `updat...
# general
e
Hi! i managed to enable passkey through the
updateSettingsFlowBody
but i'm having trouble finding a way to identify if a user has passkey enabled on my own login page, previously we were using the
webauthn
method and in order to check if the user had webauthn enabled we would call
updateLoginFlow
with the webauthn method, if it was enabled a
422
browser_location_change_required error was returned but if it wasn't we would get a
400
error with This account does not exist or has no security key set up. ui message. Now, whether i try to call
updateLoginFlow
with passkey enabled or not i always get a
422
browser_location_change_required error, can anyone help on how i can check if the user has passkey enabled on my own login UI?
s
It seems kinda complex to use the settings flow, you should probably check out https://www.ory.sh/docs/identities/sign-in/identifier-first-authentication
e
yeah i can see the
passkey_login_trigger
node when using identifier_first method with passkey enabled, thanks, btw window.oryPasskeyLogin() and value are empty, shouldn't i get some data from them (publicKey, challenge, rpId etc)?
Copy code
{
  "type": "input",
  "group": "passkey",
  "attributes": {
    "name": "passkey_login_trigger",
    "type": "button",
    "value": "",
    "disabled": false,
    "onclick": "window.oryPasskeyLogin()",
    "onclickTrigger": "oryPasskeyLogin",
    "node_type": "input"
  },
  "messages": [],
  "meta": {
    "label": {
      "id": 1010021,
      "text": "Sign in with passkey",
      "type": "info"
    }
  }
}