Get a passkey challenge
POST
/my/passkey_challenge
const url = 'https://your-board.mudda.today/my/passkey_challenge';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"purpose":"authentication"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://your-board.mudda.today/my/passkey_challenge \ --header 'Content-Type: application/json' \ --data '{ "purpose": "authentication" }'A fresh, signed, expiring WebAuthn challenge for navigator.credentials.get (signing in)
or navigator.credentials.create (registering a passkey). Fetch one just before the
ceremony; signing in with a passkey (POST /session/passkey.json) checks it. Open
without a credential. Answers JSON whatever the path’s format.
Request Body
Section titled “Request Body”Media typeapplication/json
object
purpose
Picks the challenge’s lifetime; anything else is authentication.
string
Example
{ "purpose": "authentication"}Responses
Section titled “Responses”The challenge.
Media typeapplication/json
object
challenge
required
Base64url; decode it to bytes for the WebAuthn call’s challenge.
string
Example
{ "challenge": "ZXlKZmNtRnBiSE1pT25zaVpHRjBZU0k2SWtGdk1qUmhRV013ZFd3eVVVbDBRb…"}The body is missing the object a write needs, or isn’t valid JSON.
Media typeapplication/json
Every failure’s envelope. request_id matches the X-Request-Id header.
object
errors
required
Messages keyed by field; base when no field is to blame.
object
key
additional properties
Array<string>
request_id
string
Example
{ "errors": { "card": [ "is missing" ] }, "request_id": "5f0c1e9a-2b7d-4c1e-9a63-0e4f8d2b1c55"}