> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/supertokens/supertokens-core/llms.txt
> Use this file to discover all available pages before exploring further.

# WebAuthn Credential Management

> Endpoints for managing WebAuthn credentials

## List User Credentials

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://your-domain.com/recipe/webauthn/user/credential/list?recipeUserId=recipe-user-id" \
    -H "Content-Type: application/json"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "status": "OK",
    "credentials": [
      {
        "credentialId": "credential-id-1",
        "publicKey": "base64-public-key",
        "counter": 1,
        "transports": ["usb", "nfc"],
        "createdAt": 1234567890000
      },
      {
        "credentialId": "credential-id-2",
        "publicKey": "base64-public-key",
        "counter": 5,
        "transports": ["internal"],
        "createdAt": 1234567900000
      }
    ]
  }
  ```
</ResponseExample>

<ParamField query="recipeUserId" type="string" required>
  The recipe user ID to list credentials for
</ParamField>

<ResponseField name="status" type="string">
  "OK"
</ResponseField>

<ResponseField name="credentials" type="array">
  Array of credential objects for this user
</ResponseField>

<ResponseField name="credentials[].credentialId" type="string">
  Unique identifier for the credential
</ResponseField>

<ResponseField name="credentials[].publicKey" type="string">
  Base64-encoded public key
</ResponseField>

<ResponseField name="credentials[].counter" type="number">
  Signature counter value (for replay detection)
</ResponseField>

<ResponseField name="credentials[].transports" type="array">
  Supported transport methods (e.g., "usb", "nfc", "ble", "internal")
</ResponseField>

<ResponseField name="credentials[].createdAt" type="number">
  Timestamp when credential was created (milliseconds since epoch)
</ResponseField>

***

## Get Specific Credential

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://your-domain.com/recipe/webauthn/user/credential/?recipeUserId=recipe-user-id&webauthnCredentialId=credential-id" \
    -H "Content-Type: application/json"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "status": "OK",
    "credentialId": "credential-id",
    "publicKey": "base64-public-key",
    "counter": 1,
    "transports": ["usb", "nfc"],
    "createdAt": 1234567890000
  }
  ```
</ResponseExample>

<ParamField query="recipeUserId" type="string" required>
  The recipe user ID
</ParamField>

<ParamField query="webauthnCredentialId" type="string" required>
  The credential ID to retrieve
</ParamField>

<ResponseField name="status" type="string">
  "OK" or "CREDENTIAL\_NOT\_FOUND\_ERROR"
</ResponseField>

<ResponseField name="credentialId" type="string">
  Unique identifier for the credential
</ResponseField>

<ResponseField name="publicKey" type="string">
  Base64-encoded public key
</ResponseField>

<ResponseField name="counter" type="number">
  Signature counter value
</ResponseField>

<ResponseField name="transports" type="array">
  Supported transport methods
</ResponseField>

<ResponseField name="createdAt" type="number">
  Timestamp when credential was created
</ResponseField>

***

## Remove Credential

<RequestExample>
  ```bash cURL theme={null}
  curl -X DELETE "https://your-domain.com/recipe/webauthn/user/credential/remove?recipeUserId=recipe-user-id&webauthnCredentialId=credential-id" \
    -H "Content-Type: application/json"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "status": "OK"
  }
  ```
</ResponseExample>

<ParamField query="recipeUserId" type="string" required>
  The recipe user ID
</ParamField>

<ParamField query="webauthnCredentialId" type="string" required>
  The credential ID to remove
</ParamField>

<ResponseField name="status" type="string">
  "OK" or "CREDENTIAL\_NOT\_FOUND\_ERROR"
</ResponseField>
