HashKey DID
  • Introduction
  • FAQ
  • Terminology
  • Developers
    • Guides
      • Register
      • Query
      • Libraries
      • Credential API Rule
    • API Reference
      • OpenAPI
      • OpenAPI For Dfinity
  • Protocol
    • Resolver
    • KYC
    • Multi-Chain
    • Credential
    • DID as NFT
    • Deployment
    • Contract API Reference
      • Registry
      • BasicInfo
      • PublicResolver
      • KYC
      • LayerZero
      • Credential
  • How to
    • Become an issuer
    • Edit issuer info
    • Issue a credential
      • Step 1: Deploy a contract
      • Step 2: Create a credential and submit
        • Claim rules
      • Step 3: Issue a credential
    • Manage your credentials
  • Support
    • Brand Kit
Powered by GitBook
On this page
  1. Protocol
  2. Contract API Reference

Registry

Mint DID

The format for a DID name requires a length between 5 and 54 characters, and only allows the use of lowercase letters a-z and digits 0-9.

function mint(address to, uint256 expiredTimestamp, string memory did, bytes memory evidence, string calldata avatar) public;
  • to: DID address

  • expiredTimestamp: the expired time of the evidence

  • did: DID name

  • evidence: the signature signed by HashKey DID

  • avatar: the url of avatar

Add authorization address

Authorize a DID to an address so that the address can view your DID information or log in to other systems on your behalf.

function addAuth(uint256 tokenId, address addr) public;
  • tokenId: DID token id

  • addr: authorization address

Remove authorization address

Remove the address that you had previously authorized.

function removeAuth(uint256 tokenId, address addr) public;
  • tokenId: DID token id

  • addr: authorization address

PreviousContract API ReferenceNextBasicInfo

Last updated 2 years ago