Package Exports
- @ew-did-registry/did-resolver-interface
- @ew-did-registry/did-resolver-interface/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@ew-did-registry/did-resolver-interface) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
DID Resolver Interface
EW-DID library has a design goal to support different DID methods. did-document allows management of keys, authorisation, delegation and service endpoints in standardised way. In the practical scenario, the CRUD behaviour of the did-document needs to be specific to the DID method's underlying implementation. EW-DID aims to handle this through the DID method specific resolver implementation.
did-resolver-interface defines the contract required for CRUD behaviour of the did-document. did-ethr-resolver provides a reference implementation of ERC 1056 standard.
Class Diagram
Pseudo example of implementation
// MyResolver - Implement the read only behaviour for your DID Method
class Resolver implements IResolver{
read(){
// return the whole DID Document
}
readAttribute(){
// read an attribute as per did method requirement
}
validDelegate(){
//validate a delegate as per did method requirement
}
}
// MyResolver - Implement the update and revoke behaviour for your DID Method
class Operator extends Resolver implements IOperator {
create(){
//create specific to did method
}
update(){
//update specific to did method
}
deactivate(){
//deactivate specific to did method
}
revokeDelegate(){
//revokeDelegate specific to did method
}
revokeAttribute(){
//revoke attribute specific to did method
}
}