Checkout these autogenerated SDK docs detailing classes, methods, and types available.
Request signing
All state-changing requests made to the Dfns API must be cryptographically signed. The SDK handles this automatically when you configure a signer. See backend SDK concepts for details.AsymmetricKeySigner
AsymmetricKeySigner in the @dfns/sdk-keysigner package implements CredentialSigner for server-side use.
| Parameter | Description |
|---|---|
credId | ID of the credential registered with your token. Find it in the Dfns Dashboard under Settings > Service Accounts or Settings > Personal Access Tokens. |
privateKey | PEM-formatted private key associated with the public key you registered when creating your PAT or Service Account. |
DfnsApiClient
DfnsApiClient is the main client for direct signing. It handles the full signing flow internally.
DfnsDelegatedApiClient
DfnsDelegatedApiClient is the client for delegated signing. Use it when users sign from their own device using passkeys.
The difference with DfnsApiClient:
- No
CredentialSignerin the constructor (signing happens externally) - Every state-changing method is split into
initandcompletesteps
BaseAuthApi
BaseAuthApi provides special auth-related methods, including unauthenticated endpoints for login and registration flows.
