Skip to content
This repository has been archived by the owner on Mar 1, 2021. It is now read-only.

Vendor media types not recognised #87

Open
jmerhar opened this issue Feb 19, 2013 · 5 comments
Open

Vendor media types not recognised #87

jmerhar opened this issue Feb 19, 2013 · 5 comments
Assignees

Comments

@jmerhar
Copy link

jmerhar commented Feb 19, 2013

Vendor media types (http://tools.ietf.org/html/rfc4288#section-3.2) are the preferred method for REST API versioning according to many sources. However, when a service specifies a vendor media type in the Content-Type header, the Rest Console doesn't recognise it and doesn't parse the response accordingly.

Examples:

  1. Should be parsed as JSON: application/vnd.company.app1-v100+json
  2. Should be parsed as XML: application/vnd.company.app2-v250+xml
@ahmadnassri
Copy link
Owner

ah, that's a very good feature ... will certainly add that next!

@ghost ghost assigned ahmadnassri Feb 19, 2013
@jmerhar
Copy link
Author

jmerhar commented Feb 19, 2013

Thanks, looking forward to it. And thanks for a great tool, it's invaluable for testing REST APIs.

@jmerhar
Copy link
Author

jmerhar commented Feb 21, 2013

I've noticed another very strange, seemingly related bug:

  1. I make a POST request with Content-Type "application/x-www-form-urlencoded" and Accept set to a vendor media type.
  2. The request executes fine and the server returns a response with Content-Type set to the same vendor media type.
  3. I then press "Send" again, with exactly the same settings, and the Content-Type header is no longer sent with the request.
  4. This happens for every subsequent request until I change the Content-Type of the response to something like "text/html". After that it starts working again.

Does the Content-Type response header of the previous request somehow affect the Content-Type request header of the next one?

@ahmadnassri
Copy link
Owner

interesting ... I see no reason for that behaviour, none that would be related to the response content type ... can you please open a separate ticket for this (easier to track)

I know I keep sounding like a broken record, but new version is coming soon, its a complete rewrite adding many many many new features and allowing for better debugging of issues like these!

@jmerhar
Copy link
Author

jmerhar commented Feb 21, 2013

OK, I opened a new ticket. It seemed somehow related to this one, but it could also be completely unrelated.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants