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

Update Accept header to application/vc+ld+json #605

Merged
merged 6 commits into from
Dec 5, 2023

Conversation

rhofvendahl
Copy link
Collaborator

@rhofvendahl rhofvendahl commented Nov 6, 2023

This PR updates references to Accept header in "Create Credentials" requests to use either application/vc+ld+json or application/vc+ld+json+sd-jwt, as discussed in issue #574.

EDIT: using application/sd-jwt rather than application/vc+ld+json+sd-jwt, as discussed in 11/7/23 trace call.

@rhofvendahl rhofvendahl changed the title Feat/accept header Update Accept header to application/vc+ld+json Nov 6, 2023
@TallTed
Copy link
Contributor

TallTed commented Nov 8, 2023

As we discussed on the call --

application/vc+ld+json+sd-jwt should not exist.

An application/sd-jwt is akin to an application/zip, and should not externally expose the media type of the document(s) it contains in its own media type; those should be revealed/discovered when that/those document(s) are extracted or sniffed.

In this scenario, an application/vc+ld+json document would be the result of extracting/sniffing from an application/sd-jwt document, and would be what is expected during such a transaction. Contents of other media types should lead to errors.

In sum: Accept headers in "Create Credentials" requests should be either application/vc+ld+json or application/sd-jwt (the latter of which will always package an application/vc+ld+json, in this context).

@rhofvendahl rhofvendahl self-assigned this Nov 8, 2023
@rhofvendahl
Copy link
Collaborator Author

I'll be splitting out the data integrity proof updates, with sd-jwt work pending resolution in the jose-cose working group

@@ -156,7 +156,7 @@
"header": [
{
"key": "Accept",
"value": "application/json",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would remove this part

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you say more? In this case the Accept header is on a Verify request, so just represents a preference that the verification response be in json format, right?

@mkhraisha
Copy link
Collaborator

@rhofvendahl is there anything outstanding for this PR?

@rhofvendahl
Copy link
Collaborator Author

@mkhraisha Once Orie's suggestion is resolved this should be ready to merge.

There are still some references to application/sd-jwt which may need to change if the jose-cose working group decides to go with something else, but there needs to be some value in those cases so I think it should work for now.

@OR13
Copy link
Collaborator

OR13 commented Dec 5, 2023

Related PR: w3c/vc-jose-cose#186

^ in case this PR is not merged, the current PR will continue to be correct.

@nissimsan nissimsan merged commit d1da4dd into w3c-ccg:main Dec 5, 2023
@brownoxford brownoxford deleted the feat/accept-header branch January 9, 2024 18:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants