contracts/algo-did.algo.ts is a smart contract for mapping public keys to a DID document.
src/index.ts is an SDK for uploading and resolving DID Documents.
Uploads a DID document for a public key in an Algorand DID contract. This function will upload the data to box storage and then read back the data for validation.
Given a DID (algo:did:${address}-${appID}
), returns the data stored in box storage of the given app ID for the given address.
__test__/algo-did.test.ts contains tests for uploading and resolving both big (multi-box) and small (single-box) documents.
- Docker
- Algokit
- Run
yarn
- Boot localnet with
alogokit localnet start
- Run tests with
yarn test