From c360d9ad5f0e626c5a69f7ef5d5e6bc79e0fa0d7 Mon Sep 17 00:00:00 2001 From: hsiegeln <37154749+hsiegeln@users.noreply.github.com> Date: Mon, 27 Apr 2026 17:59:53 +0200 Subject: [PATCH] fix: override WebAuthn credential type for Logto Account API @simplewebauthn/browser returns type: "public-key" (W3C standard) but Logto's verify endpoint expects type: "WebAuthn". Co-Authored-By: Claude Opus 4.6 (1M context) --- ui/src/api/logto-account-api.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/src/api/logto-account-api.ts b/ui/src/api/logto-account-api.ts index bcf5759..bd49e3d 100644 --- a/ui/src/api/logto-account-api.ts +++ b/ui/src/api/logto-account-api.ts @@ -40,7 +40,7 @@ export async function registerPasskey(getAccountToken: () => Promise): P 'POST', '/verifications/web-authn/registration/verify', token, - { verificationRecordId, payload: credential }, + { verificationRecordId, payload: { ...credential, type: 'WebAuthn' } }, ); if (!verifyRes.ok) { const err = await verifyRes.json().catch(() => ({}));