-
Notifications
You must be signed in to change notification settings - Fork 298
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(clerk-js): Remove experimental prefixes for Passkey related apis (
#3134) * chore(clerk-js): Remove experimental prefixes for Passkey related apis A few top level experimental still exist in order to ensure that we want break beta testers. Those will be removed soon. * chore(clerk-js): Add stable localization keys for passkeys * chore(clerk-js): Add changeset
- Loading branch information
1 parent
5c90b21
commit 2352149
Showing
51 changed files
with
583 additions
and
110 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
--- | ||
'@clerk/localizations': minor | ||
'@clerk/clerk-js': minor | ||
'@clerk/types': minor | ||
--- | ||
|
||
Move passkey related apis to stable: | ||
|
||
- Register passkey for a user | ||
Usage: `await clerk.user.createPasskey()` | ||
- Authenticate with passkey | ||
Usage: `await clerk.client.signIn.authenticateWithPasskey()` | ||
```ts | ||
try { | ||
await clerk.client.signIn.authenticateWithPasskey(...args); | ||
}catch (e) { | ||
if (isClerkRuntimeError(e)) { | ||
if (err.code === 'passkey_operation_aborted') { | ||
... | ||
} | ||
} | ||
} | ||
``` | ||
- ClerkRuntimeError codes introduced: | ||
- `passkey_not_supported` | ||
- `passkeys_pa_not_supported` | ||
- `passkey_invalid_rpID_or_domain` | ||
- `passkey_already_exists` | ||
- `passkey_operation_aborted` | ||
- `passkey_retrieval_cancelled` | ||
- `passkey_retrieval_failed` | ||
- `passkey_registration_cancelled` | ||
- `passkey_registration_failed` | ||
|
||
- Get the user's passkeys | ||
`clerk.user.passkeys` | ||
- Update the name of a passkey | ||
`clerk.user.passkeys?.[0].update({name:'Company issued passkey'})` | ||
- Delete a passkey | ||
`clerk.user.passkeys?.[0].delete()` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.