HTTP API Toolkit HTTP API Toolkit
HTTP API Toolkit HTTP API Toolkit
DocFX + Singulink = ♥

Search Results for

    Method CreateCredentialAsync

    CreateCredentialAsync(string, CancellationToken)

    Creates a passkey (a WebAuthn attestation).

    Declaration
    public Task<PasskeyCredential> CreateCredentialAsync(string creationOptionsJson, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    string creationOptionsJson

    The creation options from the app's API, as WebAuthn JSON (PublicKeyCredentialCreationOptionsJSON).

    CancellationToken cancellationToken

    A token to cancel the operation. On WebAssembly, cancellation stops waiting but can't close a prompt the browser is already showing.

    Returns
    Type Description
    Task<PasskeyCredential>

    The new credential to post to the app's API, and whether the passkey was created on this device.

    Implements
    IPasskeyAuthenticator.CreateCredentialAsync(string, CancellationToken)
    Exceptions
    Type Condition
    PasskeyAuthenticatorException

    The operation failed or the person cancelled it. Reason says why.

    InvalidOperationException

    This platform uses the passkey page and PageUri is not set, or the app's callback isn't set up.

    OperationCanceledException

    cancellationToken was cancelled.

    © Singulink. All rights reserved.