Specify resolution result Content-Type#1168
Open
clehner wants to merge 1 commit intodecentralized-identity:masterfrom
Open
Specify resolution result Content-Type#1168clehner wants to merge 1 commit intodecentralized-identity:masterfrom
clehner wants to merge 1 commit intodecentralized-identity:masterfrom
Conversation
csuwildcat
reviewed
Feb 14, 2022
| - `updateCommitment` is the commitment for the next update operation as defined in [commitment schemes](https://identity.foundation/sidetree/spec/#commitment-schemes). | ||
| - `recoveryCommitment` is the commitment for the next recover or deactivate operation as defined in [commitment schemes](https://identity.foundation/sidetree/spec/#commitment-schemes). | ||
|
|
||
| The DID Resolution Result response ****MUST**** contain a `Content-Type` HTTP header with value `application/ld+json;profile="https://w3id.org/did-resolution"`. |
Member
There was a problem hiding this comment.
I am wondering why we would set LD here, as we were hoping to use just plain JSON. The output doc should parse as either, but I think folks were inclined to use plain JSON as the default.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds a requirement for a DID Resolution Result HTTP response to set a Content-Type header to indicate that it is a DID Resolution Result, as specified in DID Resolution:
Setting this Content-Type header is proposed in a PR to the ION implementation: decentralized-identity/ion#244.
Without the Content-Type header, a resolver-client might expect the response to be a DID Document rather than a DID Resolution Result, as https://w3c-ccg.github.io/did-resolution/#bindings-https currently specifies that if the Accept header is not used, the HTTP response body contains the DID Document (
didDocumentStream) rather than the DID Resolution Result object. Determining the response type from the response body (content sniffing) would be possible, but it may be preferable to rely on the Content-Type header. With this header set, a client can determine that they've received a DID Resolution Result object rather than a DID document, without having to parse the response body.