WordPress

⚠️

This plugin is under development (ATT-486). The information below describes planned functionality. For immediate integration, use the JavaScript guide to add DID login manually.

What the Plugin Will Do

  • DID-based login — replace or supplement WordPress username/password authentication with cryptographic identity
  • Admin settings panel — configure trusted issuers, resolver endpoint, and login behavior from the WordPress admin dashboard
  • Shortcode — drop [attestto-login] into any page or post to render a DID login button
  • WooCommerce compatible — use DID-based identity for checkout, age verification, and professional credential checks

Planned Shortcode Usage

WordPress
 <!-- Basic login button -->
[attestto-login]

<!-- With redirect after login -->
[attestto-login redirect="/my-account"]

<!-- Require a specific credential type -->
[attestto-login credential="ProfessionalLicense" issuer="did:web:colegio-abogados.cr"] 

Planned Admin Settings

  • Trusted Issuers — list of DIDs whose credentials are accepted
  • Resolver URL — DID resolution endpoint (defaults to https://resolver.attestto.com)
  • Login mode — DID-only, DID + password fallback, or DID as secondary factor
  • Auto-register — create WordPress accounts automatically for new DIDs

Manual Approach (Available Now)

Until the plugin ships, you can add DID login to WordPress using the vanilla JavaScript approach. Add a custom script to your theme's functions.php or use a code-snippets plugin:

PHP
 function attestto_enqueue_scripts() {
  wp_enqueue_script(
    'attestto-adapter',
    'https://cdn.attestto.com/id-wallet-adapter/0.4.1/index.mjs',
    array(),
    '0.4.1',
    true
  );
}
add_action('wp_enqueue_scripts', 'attestto_enqueue_scripts');