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

ability to set content type to be customizable for a source. aka ask for only application/ld+json, or a profile #192

Closed
valentinedwv opened this issue Apr 19, 2023 · 0 comments

Comments

@valentinedwv
Copy link
Member

valentinedwv commented Apr 19, 2023

req.Header.Set("Accept", "application/ld+json, text/html")

If text/html is in the list of accept, opencoredata sends html.
So option in a source to force a specific overidden content type.

and/or options to ignore the file extenstion...

if contains(contentTypeHeader, JSONContentType) || contains(contentTypeHeader, "application/json") || fileExtensionIsJson(urlloc) {

or better logic...

@valentinedwv valentinedwv changed the title opencore force content type to be only application/ld+json, ability to set content type to be customizable for a source. aka ask for only application/ld+json, or a profile Apr 29, 2023
valentinedwv added a commit that referenced this issue May 2, 2023
Prep for json profiles #163
valentinedwv added a commit that referenced this issue May 2, 2023
Prep for json profiles #163
valentinedwv added a commit that referenced this issue May 3, 2023
Prep for json profiles #163
#128. For Validation just unmarshal an interface
valentinedwv added a commit that referenced this issue May 3, 2023
Prep for json profiles #163
#128. For Validation just unmarshal an interface
valentinedwv added a commit that referenced this issue May 3, 2023
Prep for json profiles #163
#128. For Validation just unmarshal an interface
valentinedwv added a commit that referenced this issue May 9, 2023
Prep for json profiles #163
#128. For Validation just unmarshal an interface
valentinedwv added a commit that referenced this issue Aug 31, 2023
* accept content types #192.
Prep for json profiles #163



* accept content types #192.
Prep for json profiles #163
#128. For Validation just unmarshal an interface
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

No branches or pull requests

1 participant