Complete Passkey Registration

Completes passkey registration by verifying the WebAuthn attestation from navigator.credentials.create() against the challenge issued by registration_options. On success, the passkey is saved for the authenticated guest.

The challenge must still be within its 5-minute window — if it has expired, restart from POST /api2/passkey/registration_options.

Authentication: Requires a valid Bearer access token (same signed-in guest that requested the options). client is sent as a query parameter.

For a full integration guide, see Passkey Authentication.

Query Parameters
  • client
    Type: string
    required

    OAuth client ID provided by the business. Required to identify the client application for authentication. The OAuth application must have the Advance Auth scope enabled.

Headers
  • Authorization
    Type: string
    required

    Used to authorize the request with access_token. It should be supplied as Bearer ACCESS_TOKEN_GOES_HERE.

Body
required
application/json

WebAuthn attestation payload returned by navigator.credentials.create() (or platform equivalent).

  • credential
    Type: object
    required

    The PublicKeyCredential returned by navigator.credentials.create(), serialized to JSON.

  • label
    Type: string | null

    Optional human-readable label for this passkey (e.g., a friendly device name), shown to the guest when listing their passkeys later. Defaults to "Passkey" when omitted.

Responses
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
Request Example for post/api2/passkey/registration
curl 'https://SERVER_NAME_GOES_HERE/api2/passkey/registration?client=CLIENT_ID_GOES_HERE' \
  --request POST \
  --header 'Authorization: ' \
  --header 'Content-Type: application/json' \
  --data '{
  "label": "My iPhone",
  "credential": {
    "id": "ID_GOES_HERE",
    "type": "public-key",
    "response": {
      "clientDataJSON": "eyJ0eXBlIjoid2ViYXV0aG4uY3JlYXRlIiwiY2hhbGxlbmdlIjoiTHpscHJLNmZ5QldqbU1IU2kyam9xYlNPTWQ5OW5ac2dJQUtGR2RXVEI4MCIsIm9yaWdpbiI6Imh0dHBzOi8vZXhhbXBsZS5jb20ifQ",
      "attestationObject": "o2NmbXRkbm9uZWdhdHRTdG10oGhhdXRoRGF0YQ"
    }
  }
}'
{
  "data": {
    "message": "Passkey successfully created"
  }
}