Last updated 2 months ago
Generate authentication options for a user
The username of the user
GET /webauthn/authenticate/generate-options?username=text HTTP/1.1 Host: Accept: */*
Authentication options generated successfully
{ "passkeyAuthenticationOptions": {} }
The username of the user to register
user@example.com
GET /v3/webauthn/register/generate-options?username=text HTTP/1.1 Host: Accept: */*
Registration options generated successfully
{ "challenge": "randomChallengeString", "rp": { "name": "Example RP", "id": "example.com" }, "user": { "id": "userID123", "name": "user@example.com", "displayName": "User" }, "pubKeyCredParams": [ { "alg": -7, "type": "public-key" } ] }
The username of the user to verify
POST /v3/webauthn/register/verify?username=text HTTP/1.1 Host: Content-Type: application/json Accept: */* Content-Length: 162 { "id": "credentialId123", "rawId": "base64EncodedRawId", "response": { "attestationObject": "base64EncodedAttestationObject", "clientDataJSON": "base64EncodedClientData" } }
Registration verified successfully
{ "username": "user@example.com", "wallet": { "scw_address": "0x123...", "multi_scw": [ { "network": 42161, "address": "0x123...", "deployed": true } ] }, "token": "jwt-token-123" }
POST /v3/webauthn/transaction/generate-options HTTP/1.1 Host: Content-Type: application/json Accept: */* Content-Length: 158 { "username": "user@example.com", "transactionDetails": [ { "encodedData": "0x...", "targetContractAddress": "0x...", "value": "1000000000000000000" } ], "network": "42161" }
Transaction options generated successfully
No content
The username of the user verifying the transaction
POST /v3/webauthn/transaction/verify?username=text HTTP/1.1 Host: Content-Type: application/json Accept: */* Content-Length: 2 {}
Transaction verified successfully
Verify the authentication for a user
POST /webauthn/authenticate/verify?username=text HTTP/1.1 Host: Content-Type: application/json Accept: */* Content-Length: 186 { "id": "text", "rawId": "text", "response": { "attestationObject": "text", "clientDataJSON": "text", "signature": "text" }, "authenticatorAttachment": "text", "clientExtensionResults": {}, "type": "text" }
Authentication verified successfully
{ "message": "text" }