Human ID (by human.tech)
  • Introduction
    • Private Credentials
    • The Issue of Regulatory Compliance & Non-Consensual Data Sharing
    • Need Support?
  • For Users
    • FAQs
    • Verifying Identity with Human ID
    • Verifying ePassport
    • Using Human ID with NEAR
    • Getting Refunded
  • For Developers
    • Integrating Human ID
    • Custom Sybil Resistance
    • API Reference
    • Dry Runs
    • Sign Protocol Attestations
    • Verax Attestations
    • Off-Chain Proofs
    • Clean Hands Attestations
  • For Node Operators
    • Run an Observer
  • Architecture
    • Overview
    • Flow of Data
    • Flow of Data: KYC Proof of Personhood
    • Where Data Is(n't) Stored
    • VOLE-based ZK
    • On-Chain Proofs
    • Clean Hands Architecture
  • How it Works
    • Modularity of the Stack
    • Issuer
    • Credentials
    • Hub
Powered by GitBook
On this page
  • Overview
  • 1. Redirect user to Holonym
  • 2. Verify proof
Export as PDF
  1. For Developers

Off-Chain Proofs

PreviousVerax AttestationsNextClean Hands Attestations

Last updated 11 months ago

Overview

The flow is the following:

  1. Your site redirects user to Holonym where the user generates the requested proof.

  2. After generating the proof, the user is redirected to a callback specified by the organization. The proof is included in the URL query parameters. At the callback location, the organization can verify the proof.

1. Redirect user to Holonym

Redirect user to the following URL:

https://app.holonym.id/prove/off-chain/<proofType>?callback=<callback>

Parameter descriptions:

  • proofType - Either uniqueness (for government ID proof of uniqueness), uniqueness-phone (for phone proof of uniqueness), or us-residency (for proof of US residency).

  • callback - The URL to which the user should be redirected once they've generated their proof. The proof will be added a query parameter to this callback. For example, if callback is https://example.com, the user will be redirected to https://example.com?proof=<proof>.

2. Verify proof

The user will not be redirected to the callback unless the proof is valid. But you may want to verify the proof yourself.

You can use the package to verify proofs.

import { 
  verifyUniquenessProof
} from '@holonym-foundation/off-chain-sdk';

/**
 * @param proof - The value of the "proof" query parameter passed to the callback URL
 * @returns {Promise<boolean>}
 */
async function verify(proof) {
  const parsedProof = JSON.parse(proof);
  const result = await verifyUniquenessProof(parsedProof);
  console.log(`User is unique: ${result}`);
  return result;
}

@holonym-foundation/off-chain-sdk