0
votes

The spec and the C# reference library seem to different regarding the media types for fhir.

I would think that they should be:

  • application/fhir+xml
  • application/atom+xml
  • application/fhir+json

What's the official answer?

2

2 Answers

3
votes

The correct value has changed. The specification used to say "application/fhir+json" and "application/fhir+xml", but we changed it, after ballot, to "application/json+fhir" or "application/xml+fhir".

The reference implementations and servers still haven't caught up to this change. They will in the next few weeks.

The correct mime types are:

  • application/xml+fhir - xml resource
  • application/atom+xml - xml resource bundle
  • application/json+fhir - json resource or resource bundle
1
votes

In addition, application/xml+fhir and application/json+fhir are also used when returning lists of Tags for the tag operations