SGHI FHIR Profile Implementation Guide
0.1.0 - ci-build

SGHI FHIR Profile Implementation Guide, published by Kathurima Kimathi. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/savannahghi/sil_fhir_profile_ig/ and changes regularly. See the Directory of published versions

Data Type Profile: SGHI Attachment

Official URL: https://fhir.slade360.co.ke/fhir/StructureDefinition/sghi-Attachment Version: 0.1.0
Draft as of 2025-12-02 Computable Name: SGHIAttachment

A custom document used for capturing the source of consent

Usages:

You can also check for usages in the FHIR IG Statistics

Formal Views of Profile Content

Description of Profiles, Differentials, Snapshots and how the different presentations work.

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Attachment C 0..* Attachment Content in a format defined elsewhere
Constraints: att-1
... contentType ΣC 1..1 code Mime type of the content, with charset etc.
Binding: MimeTypes (required): BCP 13 (RFCs 2045, 2046, 2047, 4288, 4289 and 2049)
Required Pattern: application/json
... url Σ 1..1 url Uri where the data can be found
Example General: http://www.acme.com/logo-small.png
... creation Σ 1..1 dateTime Date attachment was first created

doco Documentation for this format

Terminology Bindings

Path Status Usage ValueSet Version Source
Attachment.contentType Base required Mime Types 📍5.0.0 FHIR Std.

Constraints

Id Grade Path(s) Description Expression
att-1 error Attachment If the Attachment has data, it SHALL have a contentType data.empty() or contentType.exists()
ele-1 error **ALL** elements All FHIR elements must have a @value or children hasValue() or (children().count() > id.count())

This structure is derived from Attachment

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Attachment 0..* Attachment Content in a format defined elsewhere
... contentType 1..1 code Mime type of the content, with charset etc.
Required Pattern: application/json
... url 1..1 url Uri where the data can be found
... creation 1..1 dateTime Date attachment was first created

doco Documentation for this format
NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Attachment C 0..* Attachment Content in a format defined elsewhere
Constraints: att-1
... id 0..1 id Unique id for inter-element referencing
... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
... contentType ΣC 1..1 code Mime type of the content, with charset etc.
Binding: MimeTypes (required): BCP 13 (RFCs 2045, 2046, 2047, 4288, 4289 and 2049)
Required Pattern: application/json
... data C 0..1 base64Binary Data inline, base64ed
... url Σ 1..1 url Uri where the data can be found
Example General: http://www.acme.com/logo-small.png
... size Σ 0..1 integer64 Number of bytes of content (if url provided)
... hash Σ 0..1 base64Binary Hash of the data (sha-1, base64ed)
... title Σ 0..1 string Label to display in place of the data
Example General: Official Corporate Logo
... creation Σ 1..1 dateTime Date attachment was first created
... height 0..1 positiveInt Height of the image in pixels (photo/video)
... width 0..1 positiveInt Width of the image in pixels (photo/video)
... frames 0..1 positiveInt Number of frames if > 1 (photo)
... duration 0..1 decimal Length in seconds (audio / video)
... pages 0..1 positiveInt Number of printed pages

doco Documentation for this format

Terminology Bindings

Path Status Usage ValueSet Version Source
Attachment.contentType Base required Mime Types 📍5.0.0 FHIR Std.
Attachment.language Base required All Languages 📍5.0.0 FHIR Std.

Constraints

Id Grade Path(s) Description Expression
att-1 error Attachment If the Attachment has data, it SHALL have a contentType data.empty() or contentType.exists()
ele-1 error **ALL** elements All FHIR elements must have a @value or children hasValue() or (children().count() > id.count())
ext-1 error **ALL** extensions Must have either extensions or value[x], not both extension.exists() != value.exists()

This structure is derived from Attachment

Summary

Mandatory: 3 elements

Key Elements View

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Attachment C 0..* Attachment Content in a format defined elsewhere
Constraints: att-1
... contentType ΣC 1..1 code Mime type of the content, with charset etc.
Binding: MimeTypes (required): BCP 13 (RFCs 2045, 2046, 2047, 4288, 4289 and 2049)
Required Pattern: application/json
... url Σ 1..1 url Uri where the data can be found
Example General: http://www.acme.com/logo-small.png
... creation Σ 1..1 dateTime Date attachment was first created

doco Documentation for this format

Terminology Bindings

Path Status Usage ValueSet Version Source
Attachment.contentType Base required Mime Types 📍5.0.0 FHIR Std.

Constraints

Id Grade Path(s) Description Expression
att-1 error Attachment If the Attachment has data, it SHALL have a contentType data.empty() or contentType.exists()
ele-1 error **ALL** elements All FHIR elements must have a @value or children hasValue() or (children().count() > id.count())

Differential View

This structure is derived from Attachment

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Attachment 0..* Attachment Content in a format defined elsewhere
... contentType 1..1 code Mime type of the content, with charset etc.
Required Pattern: application/json
... url 1..1 url Uri where the data can be found
... creation 1..1 dateTime Date attachment was first created

doco Documentation for this format

Snapshot View

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Attachment C 0..* Attachment Content in a format defined elsewhere
Constraints: att-1
... id 0..1 id Unique id for inter-element referencing
... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
... contentType ΣC 1..1 code Mime type of the content, with charset etc.
Binding: MimeTypes (required): BCP 13 (RFCs 2045, 2046, 2047, 4288, 4289 and 2049)
Required Pattern: application/json
... data C 0..1 base64Binary Data inline, base64ed
... url Σ 1..1 url Uri where the data can be found
Example General: http://www.acme.com/logo-small.png
... size Σ 0..1 integer64 Number of bytes of content (if url provided)
... hash Σ 0..1 base64Binary Hash of the data (sha-1, base64ed)
... title Σ 0..1 string Label to display in place of the data
Example General: Official Corporate Logo
... creation Σ 1..1 dateTime Date attachment was first created
... height 0..1 positiveInt Height of the image in pixels (photo/video)
... width 0..1 positiveInt Width of the image in pixels (photo/video)
... frames 0..1 positiveInt Number of frames if > 1 (photo)
... duration 0..1 decimal Length in seconds (audio / video)
... pages 0..1 positiveInt Number of printed pages

doco Documentation for this format

Terminology Bindings

Path Status Usage ValueSet Version Source
Attachment.contentType Base required Mime Types 📍5.0.0 FHIR Std.
Attachment.language Base required All Languages 📍5.0.0 FHIR Std.

Constraints

Id Grade Path(s) Description Expression
att-1 error Attachment If the Attachment has data, it SHALL have a contentType data.empty() or contentType.exists()
ele-1 error **ALL** elements All FHIR elements must have a @value or children hasValue() or (children().count() > id.count())
ext-1 error **ALL** extensions Must have either extensions or value[x], not both extension.exists() != value.exists()

This structure is derived from Attachment

Summary

Mandatory: 3 elements

 

Other representations of profile: CSV, Excel, Schematron