Loading...
private.me Docs
Get xWallet
PRIVATE.ME · Technical White Paper

Xwallet: Verifiable Credential Infrastructure

The credential engine behind ephemeral identity. Issue, store, present, and revoke verifiable credentials with information-theoretic security. XorIDA-split storage. ~35µs reconstruction. Nine built-in schemas. Selective disclosure at the attribute level. HMAC-chained audit logs. When xID derives an ephemeral identity in ~50 microseconds, xWallet is the engine underneath.

v0.2.0 140 tests passing 8 modules 2,405 LOC ~35µs reconstruct Cross-industry
Section 01

Executive Summary

Xwallet is verifiable credential infrastructure designed for microsecond operations. Every credential flows through a deterministic pipeline: issue, serialize, pad, HMAC-authenticate, XorIDA-split. Reconstruction reverses the pipeline with cryptographic integrity checks at every stage.

Nine built-in credential schemas cover government, education, health, finance, and professional domains. Signing functions are injected — xWallet handles the credential crypto pipeline, not key management. Your application provides the signing function; xWallet provides everything else.

Selective disclosure operates at the attribute level. When a verifier requests specific attributes, xWallet reconstructs only the requested fields. A relying party checking age verification never sees the full credential. The holder controls what is revealed, and the verifier receives a cryptographic proof that the disclosed attributes are authentic.

xWallet's ~35 microsecond credential reconstruction is the foundation of xID's ~50 microsecond ephemeral presentation window. When xID derives a per-verifier ephemeral DID and needs to present a credential, xWallet reconstructs from shares, verifies HMAC integrity, selects requested attributes, and packages the disclosure — all before xID signs with the ephemeral key and purges.

NOW AVAILABLE
@private.me/xwallet is built and tested. 2,405 lines of code across 8 core modules (credential, schema, store, disclosure, revocation, audit, errors, types). 140 tests across 8 test files. Schema registry, credential issuance, XorIDA-split storage, selective disclosure, revocation, and HMAC-chained audit logging.

Enterprise toolkit shipped: @private.me/xwallet-cli — 13-endpoint management server, 3-role RBAC, Docker deployment. ~73 enterprise tests.
Section 02

Developer Experience

Xwallet provides real-time progress tracking and structured error codes to help developers build reliable credential systems.

Progress Callbacks

All credential operations support onProgress callbacks for tracking multi-stage operations — especially useful for XorIDA splitting and reconstruction.

Progress tracking example
const result = await wallet.storeCredential(credential, {
  onProgress: async (event) => {
    switch (event.stage) {
      case 'serializing':
        console.log('Serializing credential...');
        break;
      case 'splitting':
        console.log(`XorIDA split: share ${event.current}/${event.total}`);
        break;
      case 'storing':
        console.log('Writing shares to storage...');
        break;
      case 'complete':
        console.log('Credential stored successfully');
        break;
    }
  }
});

Structured Error Handling

Xwallet uses a Result<T, E> pattern with detailed error structures. Every error includes a machine-readable code, human-readable message, actionable hint, and field attribution.

Error detail structure
interface ErrorDetail {
  code: string;         // e.g., 'INVALID_SCHEMA'
  message: string;      // Human-readable description
  hint?: string;        // Actionable suggestion
  field?: string;       // Field that caused the error
  docs?: string;        // Documentation URL
}

Error Categories

Xwallet organizes error codes across 6 categories:

Category Example Codes When
Schema INVALID_SCHEMA, SCHEMA_NOT_FOUND Schema registration and validation
Credential CREDENTIAL_EXPIRED, INVALID_SIGNATURE Credential issuance and verification
Storage HMAC_VERIFICATION_FAILED, INSUFFICIENT_SHARES XorIDA split/reconstruct operations
Disclosure ATTRIBUTE_NOT_FOUND, INVALID_PRESENTATION Selective disclosure operations
Revocation REVOKED_CREDENTIAL, REGISTRY_CORRUPTED Revocation registry operations
Audit AUDIT_CHAIN_BROKEN, INVALID_EVENT Audit log integrity checks
Section 03

The Problem

Digital credentials are stored in centralized databases protected by encryption keys. A single key compromise exposes millions of records. Existing credential libraries are not designed for the microsecond reconstruct-disclose-purge cycle that unlinkable identity demands.

Three Infrastructure Failures

1. Key-dependent security. Every existing credential wallet encrypts data with a single key. Compromise that key — through theft, side-channel attack, or a future quantum computer — and every credential is exposed. This is the harvest-now-decrypt-later threat: adversaries collect encrypted credential stores today and decrypt them when quantum computers arrive.

2. No tamper-evident audit trail. When a credential is issued, stored, presented, or revoked, there is no cryptographic chain linking these events. Regulated industries (healthcare, finance, government) require proof that credentials were handled correctly. Most credential systems offer server-side logs that are mutable, deletable, and disconnected from the credential crypto.

3. Not designed for microsecond operations. Ephemeral identity requires reconstructing a credential, selecting attributes, and verifying integrity within a ~50 microsecond window. Existing credential libraries are built for millisecond-to-second response times. They cannot serve as the engine for a pipeline that must reconstruct, disclose, and purge before the next presentation.

Infrastructure Comparison

InfrastructureQuantum-Safe Storage?Microsecond Reconstruct?Audit Chain?Selective Disclosure?
JWT LibrariesNo — AES/RSA keysN/A (no split)NoNo
Aries FrameworkNo — key-basedNoPartialYes (AnonCreds)
SpruceIDNo — key-basedNoNoPartial
walt.idNo — key-basedNoNoPartial
XwalletYes — IT-secure~35µsHMAC chainAttribute-level
Section 04

Use Cases

Xwallet enables verifiable credential infrastructure across government, education, healthcare, and finance — with information-theoretic security and microsecond operations.

Government
Digital ID Credentials
National ID, passport, driver's license credentials with selective disclosure. Citizens prove age or residency without revealing full identity. Meets eIDAS 2.0 unlinkability requirements.
ISO 24745 Compliant
Education
Academic Credentials
Diplomas, transcripts, and professional licenses. Students present degree verification to employers without exposing GPA or course details. Universities revoke credentials for misconduct.
Selective Disclosure
Healthcare
Health Certificates
Vaccination records, health insurance, patient credentials. Providers verify vaccination status without accessing full medical history. HMAC-chained audit trail for HIPAA compliance.
HIPAA Audit Trail
Finance
KYC Credentials
Bank-verified identity, credit score proofs, accredited investor status. Financial institutions verify credentials without storing PII. Revocation registry for fraud prevention.
Zero PII Storage
Section 05

Architecture

Credentials flow through a deterministic pipeline: issue, serialize, pad, authenticate, split, and store. Retrieval reverses the pipeline with HMAC verification at every stage.

Credential Pipeline

XWALLET CREDENTIAL PIPELINE ISSUE Sign SERIALIZE Binary PAD PKCS7 HMAC SHA-256 XorIDA SPLIT SHARE 1 + HMAC tag SHARE 2 + HMAC tag SHARE N + HMAC tag RETRIEVE PIPELINE Reconstruct HMAC Verify Unpad Deserialize Verify Sig
Padding: PKCS7 with b=p-1
Before HMAC computation and XorIDA splitting, every serialized credential is padded using PKCS7 with block size b = p − 1 where p is the XorIDA prime parameter. This ensures the padded payload is always a valid input length for the splitting algorithm while preventing length-based metadata leakage across shares.

Implementation: 8 Core Modules

The xWallet implementation is organized into 8 focused modules, each handling a distinct stage of the credential lifecycle:

credential.ts — Issuance & Verification
Issues verifiable credentials with injected signing functions. Validates schemas, populates typed attributes, timestamps issuance, and verifies issuer signatures. Zero key management — signing is your responsibility.
schema.ts — Schema Registry
Nine built-in schemas (government-id, passport, diploma, health-certificate, vaccination-record, professional-license, financial-kyc, insurance-policy, drivers-license). Custom schema creation and registration with typed attribute definitions (string, number, boolean, bytes).
store.ts — XorIDA Split Storage
Serializes credentials into deterministic binary format, pads with PKCS7 (b=p-1), computes HMAC-SHA256, splits via XorIDA into k-of-n shares. Reconstruct reverses: XOR shares, verify HMAC, unpad, deserialize. ~80µs store, ~60µs retrieve.
disclosure.ts — Selective Disclosure
Attribute-level selective disclosure. Only requested attributes are included in presentations. Unrequested attributes never leave the wallet. Verifiers receive proof that disclosed attributes are authentic without seeing the full credential.
revocation.ts — HMAC-Chained Registry
Append-only revocation registry with HMAC-chain tamper detection. Mark credentials as revoked. Verification fails for revoked credentials. Tamper-evident via cryptographic chain integrity.
audit.ts — Tamper-Evident Audit Logs
HMAC-chained audit log for credential lifecycle events (issued, stored, presented, revoked). Each event references the previous HMAC — breaking the chain is detectable. Satisfies regulatory audit requirements (HIPAA, DORA, eIDAS).
errors.ts — Actionable Error Codes
Structured error types with actionable hints. INVALID_SCHEMA, HMAC_VERIFICATION_FAILED, CREDENTIAL_EXPIRED, REVOKED_CREDENTIAL, etc. Each error includes field attribution and recovery guidance.
types.ts — TypeScript Definitions
Complete type definitions for credentials, schemas, presentations, storage handles, and audit events. Strict TypeScript for compile-time safety. Result<T, E> pattern for error handling.

Total: 2,405 lines of code across 8 modules. ~140 tests covering all credential lifecycle operations. All modules use the Result<T, E> pattern — no thrown exceptions. Pure functions with side effects isolated at module boundaries.

Built-in Schemas

Nine credential schemas cover common use cases across industries:

9
Built-in Schemas
4
Attribute Types
Custom
Schema Support
Schema IDIndustryKey Attributes
government-idGovernmentfullName, dateOfBirth, nationality, idNumber
passportGovernmentpassportNumber, nationality, expiry, photo
diplomaEducationdegree, institution, graduationDate, major
health-certificateHealthcarepatientId, provider, issueDate, certificateType
vaccination-recordHealthcarevaccineName, date, dose, provider
professional-licenseProfessionallicenseType, number, issuer, expiry
financial-kycFinanceverified, riskLevel, accreditedInvestor
insurance-policyInsurancepolicyNumber, provider, coverage, expiry
drivers-licenseGovernmentlicenseNumber, class, state, expiry
Section 06

Cross-ACI Integration

Xwallet composes with Xid, Xstore, Xprove, and Xlink to enable complete verifiable credential workflows with ephemeral identity, distributed storage, and verifiable computation.

Xwallet + Xid: Ephemeral Credential Presentation

When an ephemeral presentation occurs, the xWallet retrieve pipeline feeds directly into xID's ephemeral derivation. The combined flow: xWallet reconstruct (~35µs) → HMAC verifyUnpad + deserializeHKDF derive (~5µs) → Ed25519 keygen (~8µs) → Select attributes + sign (~2µs) → Purge (~1µs). Total: ~50µs. The credential never exists in decrypted form for longer than it takes to disclose the requested attributes.

Xwallet + Xstore: Geographic Credential Distribution

Xstore routes XorIDA credential shares to pluggable backends (local, S3, IPFS, HTTP). Share 1 → AWS us-east-1. Share 2 → Azure eu-west-1. Compromising one datacenter reveals nothing. Xwallet reconstruction works across any Xstore backend combination.

Xwallet + Xprove: Verifiable Credential Computation

Xprove generates zero-knowledge proofs that a credential meets specific criteria without revealing the credential itself. Example: prove age > 21 without disclosing birthdate. Xwallet provides the credential input; Xprove provides the cryptographic proof. Verifier receives proof of predicate satisfaction without seeing any credential attribute.

Xwallet + Xlink: Authenticated Credential Exchange

Xlink wraps Xwallet presentations in authenticated envelopes with Ed25519 signatures and hybrid PQ key exchange. Credentials transmitted between systems inherit Xlink's DID-based authentication, replay protection, and scope validation. No separate authentication layer required.

Design Principle
Xwallet is credential infrastructure, not a consumer wallet. It provides the issuance, serialization, storage, presentation, and revocation pipeline. Consumer-facing wallets (like xID) build on Xwallet for UX, import flows, ephemeral identity, and backup. Xwallet is the engine. xID is the car.
Section 07

Complete Credential Flow

End-to-end credential lifecycle: issuance → storage → selective disclosure → verification → revocation. Each step cryptographically linked via HMAC-chained audit trail.

Full credential lifecycle
// 1. Issue credential
const credential = await wallet.issueCredential({
  schemaId: 'government-id',
  subject: did,
  attributes: {
    fullName: 'Jane Smith',
    dateOfBirth: '1990-01-15',
    nationality: 'US',
    idNumber: 'ABC123456'
  },
  signFn: async (data) => ed25519.sign(issuerKey, data)
});

// 2. Store with XorIDA split
const handle = await wallet.storeCredential(credential);

// 3. Create selective disclosure presentation
const presentation = await wallet.createPresentation(handle, {
  requestedAttributes: ['nationality'] // Only reveal nationality
});

// 4. Verifier checks presentation
const valid = await wallet.verifyPresentation(presentation);

// 5. Revoke credential if needed
await wallet.revokeCredential(credential.id);

Every operation is logged to the HMAC-chained audit trail. Query the audit log to retrieve the complete lifecycle history for any credential. Chain integrity verification detects any tampering.

Section 08

Security

Xwallet's security is grounded in information-theoretic credential splitting, HMAC integrity verification at every pipeline stage, and tamper-evident audit chains. No keys required for storage security.

Information-Theoretic Storage

Every credential is XorIDA-split into k-of-n shares. An attacker who compromises fewer than k shares learns nothing about the credential — not computationally hard to break, but mathematically impossible. This is unconditional security: it holds even against adversaries with unbounded computational power.

HMAC Integrity Verification

Every credential share carries an HMAC-SHA256 tag computed over the serialized, padded payload. Before reconstruction, every share's HMAC is verified. If any HMAC fails, reconstruction aborts. Tampered shares are detected before they can corrupt the credential.

Tamper-Evident Audit Chain

Every credential lifecycle event (issued, stored, presented, revoked) is logged with a timestamp and HMAC. Each event's HMAC includes the previous event's HMAC. Breaking the chain is cryptographically detectable. Audit logs satisfy HIPAA, DORA, and eIDAS regulatory requirements.

Selective Disclosure Privacy

Only requested attributes are included in presentations. A verifier requesting age verification never sees the holder's full name, address, or ID number. The presentation includes a cryptographic proof (issuer signature) that the disclosed attributes are authentic, without revealing unrequested data.

Revocation Registry Integrity

The revocation registry is append-only with HMAC-chain tamper detection. Once a credential is revoked, it cannot be un-revoked without breaking the chain. Verifiers check the registry before accepting any presentation.

Section 09

Benchmarks

At typical credential sizes (<1 KB), XorIDA splitting is 2–11x faster than AES-256-GCM. The full retrieve pipeline completes in ~60 microseconds.

XorIDA Split Performance

Payload SizeXorIDA SplitAES-256-GCMSpeedup
64 bytes~14µs~160µs11.4x
256 bytes~35µs~122µs3.5x
1 KB~58µs~140µs2.4x
4 KB~130µs~125µs0.96x (crossover)

Full Pipeline Performance

~80µs
Store Pipeline
~60µs
Retrieve Pipeline
~35µs
XorIDA Reconstruct

Store pipeline breakdown: Serialize (5µs) + Pad (2µs) + HMAC (8µs) + XorIDA split (35µs) + Write shares (30µs) = ~80µs total.
Retrieve pipeline breakdown: Read shares (15µs) + XorIDA reconstruct (35µs) + HMAC verify (8µs) + Unpad (2µs) = ~60µs total.

Section 10

Honest Limitations

Xwallet is credential infrastructure, not a complete consumer wallet. It provides the issuance, storage, presentation, and revocation pipeline. Consumer-facing features are delegated to products like xID.

Not a Consumer Wallet

Xwallet has no user interface, no import flows, no backup mechanisms. It is the engine that powers consumer wallets. Products like xID build UX, import flows, ephemeral identity, and backup on top of Xwallet's infrastructure.

Signing Functions Are Injected

Xwallet does not manage keys. Credential issuance requires a signing function. You are responsible for key generation, storage, and rotation. This is intentional: Xwallet focuses on credential crypto, not key management.

Schema Registry Is Not Global

The nine built-in schemas are local to your Xwallet instance. There is no global registry. If you need a custom schema, you register it locally. Interoperability between wallets requires schema coordination out-of-band.

No Automatic Revocation Checking

Verifiers must explicitly check the revocation registry when verifying presentations. Xwallet does not automatically reject revoked credentials during reconstruction. This is a design choice: reconstruction is a storage operation, not a verification operation.

XorIDA Crossover at ~1-2 KB

At credential sizes above ~1-2 KB, AES-256-GCM becomes faster than XorIDA splitting. For large credentials (e.g., diplomas with embedded high-resolution images), AES may be more performant. Xwallet defaults to XorIDA for information-theoretic security at typical credential sizes.

Advanced Topics

Implementation Details

Deep dives into the Xwallet ACI surface, error taxonomy, enterprise CLI, and codebase statistics. Production deployment guidance for regulated industries.

Advanced 01

Full ACI Surface

Complete API reference for all 8 Xwallet modules. Every function is typed with Result<T, E> for structured error handling.

Credential Module

issueCredential(params: IssueParams): Promise<Result<Credential, Error>>
Issues a new verifiable credential. Validates schema, populates attributes, timestamps, and signs via injected signFn.
verifyCredential(credential: Credential): Promise<Result<boolean, Error>>
Verifies issuer signature and checks expiry. Does not check revocation (use verifyPresentation for that).

Schema Module

registerSchema(schema: SchemaDefinition): Result<void, Error>
Registers a custom schema with typed attribute definitions. Schema ID must be unique.
getSchema(schemaId: string): Result<SchemaDefinition, Error>
Retrieves a schema by ID. Returns built-in or custom schemas.

Store Module

storeCredential(credential: Credential, options?: StoreOptions): Promise<Result<StorageHandle, Error>>
Serializes, pads, HMACs, and XorIDA-splits credential. Returns handle for reconstruction.
retrieveCredential(handle: StorageHandle): Promise<Result<Credential, Error>>
Reconstructs credential from shares. Verifies HMAC integrity before deserializing.

Disclosure Module

createPresentation(handle: StorageHandle, request: PresentationRequest): Promise<Result<Presentation, Error>>
Creates selective disclosure presentation with only requested attributes.
verifyPresentation(presentation: Presentation): Promise<Result<boolean, Error>>
Verifies presentation signature, checks revocation registry, validates requested attributes.

Revocation Module

revokeCredential(credentialId: string): Promise<Result<void, Error>>
Adds credential ID to HMAC-chained revocation registry. Append-only operation.
isRevoked(credentialId: string): Result<boolean, Error>
Checks if credential is in revocation registry. Verifies HMAC chain integrity.

Audit Module

logEvent(event: AuditEvent): Promise<Result<void, Error>>
Appends event to HMAC-chained audit log. Each event references previous HMAC.
getAuditTrail(credentialId: string): Result<AuditEvent[], Error>
Retrieves full audit trail for a credential. Verifies HMAC chain integrity.
Advanced 02

Error Taxonomy

Complete error code reference organized by module. Every error includes actionable hints and field attribution.

Schema Errors (SCH-xxx)

CodeCategoryHint
INVALID_SCHEMASchemaCheck schema definition against built-in schemas
SCHEMA_NOT_FOUNDSchemaRegister schema before issuing credentials
DUPLICATE_SCHEMASchemaSchema ID already registered

Credential Errors (CRD-xxx)

CodeCategoryHint
INVALID_SIGNATURECredentialVerify issuer public key matches credential
CREDENTIAL_EXPIREDCredentialCheck expiresAt timestamp
MISSING_ATTRIBUTECredentialAttribute required by schema is missing

Storage Errors (STO-xxx)

CodeCategoryHint
HMAC_VERIFICATION_FAILEDStorageShare data corrupted or tampered
INSUFFICIENT_SHARESStorageFewer than k shares provided for reconstruction
SERIALIZATION_FAILEDStorageCredential format invalid

Disclosure Errors (DSC-xxx)

CodeCategoryHint
ATTRIBUTE_NOT_FOUNDDisclosureRequested attribute not in credential
INVALID_PRESENTATIONDisclosurePresentation signature invalid

Revocation Errors (REV-xxx)

CodeCategoryHint
REVOKED_CREDENTIALRevocationCredential found in revocation registry
REGISTRY_CORRUPTEDRevocationHMAC chain broken in registry

Audit Errors (AUD-xxx)

CodeCategoryHint
AUDIT_CHAIN_BROKENAuditHMAC chain integrity check failed
INVALID_EVENTAuditEvent type not recognized
Advanced 03

Enterprise CLI

Self-hosted Xwallet management server for enterprise credential issuance, revocation, and audit. Part of the 21-CLI enterprise suite.

xwallet-cli Features

13
Endpoints
3
RBAC Roles
73
Enterprise Tests

Endpoints

POST /credentials/issue
Issues a new credential. Requires issuer role. Returns credential ID and storage handle.
GET /credentials/:id
Retrieves credential by ID. Requires verifier role. Returns full credential with audit trail.
POST /credentials/:id/revoke
Revokes a credential. Requires admin role. Appends to HMAC-chained registry.
GET /credentials/:id/audit
Retrieves full audit trail. Requires auditor role. Verifies HMAC chain integrity.

Docker Deployment

Docker Compose
version: '3.8'
services:
  xwallet-cli:
    image: privateme/xwallet-cli:latest
    ports:
      - "4600:4600"
    environment:
      - XWALLET_PORT=4600
      - XWALLET_RATE_LIMIT=100
      - XWALLET_LOG_LEVEL=info
    volumes:
      - ./data:/data
Advanced 04

Codebase Statistics

Xwallet is 2,405 lines of TypeScript across 8 modules. 140 tests covering all credential lifecycle operations. Zero npm dependencies.

2,405
Lines of Code
8
Core Modules
140
Tests
0
npm Deps

Module Breakdown

ModuleLOCTestsCoverage
credential.ts3802298%
schema.ts28515100%
store.ts5202897%
disclosure.ts3101896%
revocation.ts2451699%
audit.ts2651798%
errors.ts18012100%
types.ts22012100%

Fast Onboarding: 3 Acceleration Levels

From zero-click code patterns to one-click deploy buttons, Xwallet offers three acceleration levels that reduce setup time from ~2 minutes to as low as ~15 seconds. Each level targets a different integration context.

Level 1: Zero-Click Accept (Lazy Wallet Initialization)

For trusted partner integrations, the lazy wallet pattern defers identity initialization until the first credential operation. No explicit init() call required — the wallet automatically generates its identity on first use and auto-accepts incoming connection requests from known partners.

Zero-click lazy initialization
import { Xwallet } from '@private.me/xwallet';

// Wallet generates identity on first operation
const wallet = await Xwallet.lazy({
  name: 'my-credentials',
  // Auto-accepts from XWALLET_INVITE_CODE env var
});

// First operation triggers identity generation automatically
const credential = await wallet.issue({
  type: 'employee-badge',
  attributes: {
    name: 'Alice Smith',
    employeeId: 'E12345',
    department: 'Engineering',
  },
});

if (credential.ok) {
  console.log('Credential issued:', credential.value.id);
}

Setup time: ~80 seconds (identity generation happens transparently during first operation)
Best for: Internal microservices, trusted partner integrations, development/testing

Level 2: One-Line CLI Setup (Invite-Based)

For new partner onboarding, the one-line CLI command accepts an invite code and automatically configures the entire Xwallet identity, schema registry, and connection in a single operation. No manual DID exchange, no configuration files.

One-line invite acceptance
// Partner sends you invite code: XWL-abc123def456
$ npx @private.me/xwallet-cli init --invite XWL-abc123def456

{
  "status": "initialized",
  "walletDid": "did:key:z6MksZP8ChwZYSNgozYq...",
  "name": "my-credentials",
  "schemas": [
    {
      "id": "employee-badge",
      "issuer": "did:key:z6MkIssuerDID...",
      "trusted": true
    }
  ],
  "elapsed_seconds": 2.3
}

Setup time: ~40 seconds (single command, no manual configuration)
Best for: Partner onboarding, external integrations, production deployments

Level 3: Deploy Button (One-Click Infrastructure)

For platform integrations, deploy buttons provide one-click infrastructure provisioning with Xwallet pre-configured. Clicking the button deploys a complete credential service with identity, endpoints, and schema registry already configured.

Deploy button (Vercel example)
<!-- Add to your README.md or integration docs -->
[![Deploy to Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fprivate-me%2Fxwallet-starter&env=XWALLET_INVITE_CODE&envDescription=Paste%20your%20Xwallet%20invite%20code%20here&envLink=https%3A%2F%2Fdocs.private.me%2Fdocs%2Fxwallet)

// Deployed service includes:
// - Auto-generated Xwallet identity
// - Pre-configured schema registry from invite
// - Express middleware with credential endpoints
// - Health check and verification endpoints

Setup time: ~15 seconds (one click, zero configuration)
Best for: SaaS integrations, marketplace apps, rapid prototyping

Setup Time Comparison

Method Setup Time Steps Required Configuration Best For
Manual (Traditional) ~2 minutes 5 (schema + sign + issue + store + verify) Manual DID exchange Full control, learning
Level 1: Zero-Click ~80 seconds 0 (lazy init) Auto-accept partners Trusted integrations
Level 2: One-Line CLI ~40 seconds 1 (accept invite) Invite code only Partner onboarding
Level 3: Deploy Button ~15 seconds 1 (click button) Zero configuration SaaS integrations
ACCELERATION MULTIPLIER
Deploy buttons reduce setup time by 8× compared to manual initialization (15 seconds vs 2 minutes). Combined with the existing 21-33× improvement over traditional verifiable credential setup (42-67 minutes), this creates a total acceleration of 168-268× for platform integrations.

Getting Started: Fastest Path

The recommended onboarding path depends on your integration context:

  1. New to Xwallet? Start with a Deploy Button to see Xwallet running in production in ~15 seconds. Deploy the starter template, then explore the code.
  2. Onboarding a partner? Send them a One-Line CLI invite code. They paste one command and are connected in ~40 seconds.
  3. Internal microservices? Use Zero-Click Accept with lazy initialization. No setup time, identity generation happens transparently on first use.
  4. Want full control? Follow the standard 2-minute setup flow with explicit schema registration and signing functions.
Fastest path: Deploy button first, explore code second
// 1. Click "Deploy to Vercel" button (~15 sec)
// 2. Paste invite code when prompted
// 3. Service deploys with Xwallet pre-configured
// 4. Clone the deployed repo to see the code:

git clone https://github.com/YOUR_USERNAME/xwallet-starter
cd xwallet-starter

// 5. Explore the three key files:
//    - api/issue.ts → Credential issuance endpoint
//    - api/verify.ts → Credential verification endpoint
//    - api/present.ts → Selective disclosure endpoint

Template Examples

All three starter templates are available in the packages/xwallet/templates/ directory:

templates/node-typescript/
Node.js TypeScript starter with lazy initialization. Demonstrates credential issuance, verification, and selective disclosure presentations. Runs locally with tsx or deploys to any Node.js hosting.
templates/vercel/
Vercel Edge Functions with three REST endpoints (/api/issue, /api/verify, /api/present). Zero-config deployment via deploy button. Scales automatically with Vercel's global CDN.
templates/github-starter/
Multi-platform starter repository supporting Node.js, Vercel Edge, and Cloudflare Workers. Includes examples for custom schemas, revocation registries, and audit logging. Clone and choose your platform.
TEMPLATE AVAILABILITY
All templates use the same Xwallet.lazy() pattern with auto-accept from environment variables. Switch platforms by changing deployment targets — code stays identical across Node.js, Vercel, and Cloudflare Workers.

Deployment Options

SaaS Recommended

Fully managed infrastructure. Call our REST API, we handle scaling, updates, and operations.

  • Zero infrastructure setup
  • Automatic updates
  • 99.9% uptime SLA
  • Pay per use
View Pricing →

SDK Integration

Embed directly in your application. Runs in your codebase with full programmatic control.

  • npm install @private.me/xwallet
  • TypeScript/JavaScript SDK
  • Full source access
  • Enterprise support available
Get Started →

On-Premise Enterprise

Self-hosted infrastructure for air-gapped, compliance, or data residency requirements.

  • Complete data sovereignty
  • Air-gap capable
  • Docker + Kubernetes ready
  • RBAC + audit logs included
Enterprise CLI →