DID Operations

Create a new DID:

const did = await axesConnect.did.create({
  did: 'did:axes:example',
  publicKey: 'publicKeyString',
  serviceEndpoint: 'https://example.com/endpoint',
  tokenId: 123,
  tokenContract: '0x123...'
});

Update an existing DID:

await axesConnect.did.update({
  did: 'did:axes:example',
  publicKey: 'newPublicKeyString',
  serviceEndpoint: 'https://newexample.com/endpoint'
});

Transfer a DID:

await axesConnect.did.transfer({
  tokenId: 123,
  tokenContract: '0x123...'
});

Retrieve DID data:

const didData = await axesConnect.did.getByAddress(userAddress);
// or
const didData = await axesConnect.did.getByDID('did:axes:example');

Last updated