Search loading...

API Hub

Explore and Make use of Nationally Defined Messaging APIs

 

Serialisation

Requirements for FHIR content types

The FHIR standard allows a number of serialisations of resources to be used. Ideally, servers will support the two main serialisations – XML and JSON, however there may be cases where this is difficult to achieve.

FHIR-SERIAL-01: FHIR ReST APIs MUST support JSON serialisation

All FHIR ReST endpoints MUST support JSON formatted requests/responses. FHIR ReST endpoints SHOULD also support XML formatted requests/responses. The serialisation mime-types supported MUST be declared in the Conformance/CapabilityStatement resource for the endpoint, and the server MUST use the usual FHIR mechanisms to allow clients to request a specific Content Type as per the FHIR spec (servers may choose to reject the use of XML if it is not supported).

FHIR-SERIAL-02: FHIR Messaging Interfaces MUST support XML serialisation

All FHIR messaging endpoints MUST support XML formatted requests/responses. FHIR messaging endpoints SHOULD also support JSON formatted requests/responses. The serialisation mime-types supported MUST be declared in the Conformance/CapabilityStatement resource for the messaging endpoint.

FHIR-SERIAL-03: Namespaces outside those defined in the FHIR specification MUST NOT be used

The FHIR standard specifies a specific namespace for FHIR XML elements, with a second namespace for XHTML content in narrative sections. Those specifying FHIR APIs MUST not use other namespaces in their APIs

Tags:

All content is available under the Open Government Licence v3.0, except where otherwise stated