Skip to content

Enroll a preregistered WebAuthn factor

Request

Identity Engine
OAuth 2.0 scope:
  • okta.users.manage

Enrolls a preregistered WebAuthn factor. This WebAuthn factor has a longer challenge timeout period to accommodate the fulfillment request process. As part of this operation, Okta generates elliptic curve (EC) key-pairs used to encrypt the factor PIN and enrollment data sent by the fulfillment provider.

Bodyapplication/json

Enrollment initialization request

enrollmentRpIdsArray of strings

List of relying party hostnames to register on the YubiKey

fulfillmentProviderstring

Name of the fulfillment provider for the WebAuthn preregistration factor

Value:"yubico"
userIdstring

ID of an existing Okta user

yubicoTransportKeyJWKobject(ECKeyJWK)

Transport public key in JWK (JSON Web Key) format used to encrypt fulfillment requests to Yubico

curl -i -X POST \
  https://subdomain.okta.com/webauthn-registration/api/v1/enroll \
  -H 'Content-Type: application/json' \
  -d '{
    "enrollmentRpIds": [
      "myorg.okta.com"
    ],
    "fulfillmentProvider": "yubico",
    "userId": "00us2hPODQncCkxef0g3",
    "yubicoTransportKeyJWK": {
      "crv": "P-384",
      "kid": "APCS-Ttrans-C19881-I009",
      "kty": "EC",
      "use": "enc",
      "x": "r6AzcX3OSiJk1yQaBVYiBOtzFS9gNSpMDPvnVvl0CAX7el1ZyzmPG_BZ7u8sqTmF",
      "y": "RxPyGH1Xg74E2f5AQGkkddzsvTNY1R3R7mXTEM5wQtr1Y7C4XHlvITNZfU6G"
    }
  }'

Responses

Success

Bodyapplication/json
credRequestsArray of objects(WebAuthnCredRequest)

List of credential requests for the fulfillment provider

fulfillmentProviderstring

Name of the fulfillment provider for the WebAuthn preregistration factor

Value:"yubico"
pinRequestJwestring

Encrypted JWE of PIN request for the fulfillment provider

userIdstring

ID of an existing Okta user

Response
{ "credRequests": [ { … } ], "fulfillmentProvider": "yubico", "pinRequestJwe": "eyJlcGsa3R5IjoiRUMiLA...", "userId": "00us2hPODQncCkxef0g3" }