Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to add service to an existing DID (and more broadly, how to update) #157

Open
jiyoonie9 opened this issue May 17, 2024 · 2 comments
Open
Labels
did related to decentralized identifiers discuss enhancement New feature or request

Comments

@jiyoonie9
Copy link
Contributor

We need to hold design discussions to come up with a unified update() method signature that complies with how each did method handles (or doesn't handle) updates, and has an intuitive DX which allows the developer to discover what operations can or can't be done with specific did methods.

For example, although addService() implemented in decentralized-identity/web5-kt#313 would add a service to BearerDid construct, BearerDid is an abstraction that holds a DID (of any kind) and related objects like keymanager and diddocument.

Adding a service should have downstream implications besides mutating our library-specific BearerDid abstraction, but decentralized-identity/web5-kt#313 does not (and cannot, without prior design discussion) support the downstream actions.

A couple examples to illustrate this point:

  1. If we were to add a service to an existing did:dht, we need to also publish the mutated DID, otherwise if we resolve the same did:dht again, the new service would not exist in the resolution result.
  2. If we were to try and add a service to an existing did:jwk, that actually should not be possible, because did:jwk does not support updates at all.

relevant issues / PRs
decentralized-identity/web5-kt#310
decentralized-identity/web5-kt#311
decentralized-identity/web5-kt#313

@decentralgabe
Copy link
Member

Do we have a consistent interface for interacting with DIDs? Update should certainly be one of the methods on that interface. Not all methods need to implement all methods on the interface.

@decentralgabe decentralgabe added did related to decentralized identifiers enhancement New feature or request and removed blocker needs a decision labels Aug 16, 2024
@decentralgabe
Copy link
Member

@jiyoontbd do you feel the guidance in the spec at present is sufficient? If not, could you speak to what type of text you'd like to see? And test vectors to follow (feel free to add to #167)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
did related to decentralized identifiers discuss enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants