example - carbs

Carbs Sample :

{
  "resourceType": "Observation", // Resource name value in FHIR for this profile
  "id": "57787b6e-291a-45ba-8d0a-b16000b31c71",
  "meta": { // used for validation of the profile
		"profile": [
			"http://roche.com/fhir/iop/StructureDefinition/Observation"
		]
	},
  "status": "final",  // FHIR hardcorded value for status
  "code": {
    "coding": [
      {
        "system": "http://loinc.org",
        "code": "9059-7",
        "display": "Carbohydrate intake Estimated" // code for carbs
      }
    ]
  },
  "subject": {
    "reference": "Patient/34605fdc-74aa-4587-a5f0-92e6c5f64527"
  },
  "effectiveDateTime": "2017-10-03T06:32:00+01:00",
  "valueQuantity": {
    "value": 30,
    "unit": "g",
    "system": "http://unitsofmeasure.org",
    "code": "g"
  },
  "device": {
    "reference": "Device/8954c958-41c5-4a24-82ef-693218c2f625"
  }
}


Carbs sample with (component sub type) :


{
  "resourceType": "Observation", // Resource name value in FHIR for this profile
  "id": "57787b6e-291a-45ba-8d0a-b16000b31c71",
  "meta": { // used for validation of the profile
		"profile": [
			"http://roche.com/fhir/iop/StructureDefinition/Observation"
		]
	},
  "status": "final",  // FHIR hardcorded value for status
  "code": {
    "coding": [
      {
        "system": "http://loinc.org",
        "code": "9059-7",
        "display": "Carbohydrate intake Estimated" // code for carbs
      }
    ]
  },
  "subject": {
    "reference": "Patient/34605fdc-74aa-4587-a5f0-92e6c5f64527"
  },
  "effectiveDateTime": "2017-10-03T06:32:00+01:00",
  "valueQuantity": {
    "value": 30,
    "unit": "g",
    "system": "http://unitsofmeasure.org",
    "code": "g"
  },
  "device": {
    "reference": "Device/8954c958-41c5-4a24-82ef-693218c2f625"
  },
  "component": [ // sub category - carbs
			{
		"code": {
			"coding": [ 
				{
					"system": "http://snomed.info/sct",
					"code": "769560003",
					"display": "With lunch (qualifier value)"
				}
			]
		}
	}
 ]
}

Component.code coding for all possible sample types

This section describes how each sub component type has to be handled in Modelling. The following coding section needs to be updated based on the sub component type.

For example:

"component": [ // sub category - type
			{
		"code": {
			"coding": [ 
				{
					"system": "http://snomed.info/sct",
					"code": "769560003",
					"display": "With lunch (qualifier value)"
				}
			]
		}
	}
 ]

Below are some of possible codes for BG subType (component),for exhaustive list of codes refer HERE

System Code Display
http://snomed.info/sct 1179047002 Estimated quantity of intake of carbohydrate (observable entity)
http://snomed.info/sct 228979009 Small slices/meal (qualifier value)
http://snomed.info/sct 260229002 Standard meal (finding)
http://snomed.info/sct 228978001 large slices/meal (qualifier value)
http://snomed.info/sct 1551000175109 With snack (qualifier value)
http://snomed.info/sct 257689006 Restaurant (environment)
http://snomed.info/sct 769561004 With breakfast (qualifier value)
http://snomed.info/sct 769560003 With lunch (qualifier value)
http://snomed.info/sct 769559008 With dinner (qualifier value)
http://snomed.info/sct 267023007 Binging (finding)
http://snomed.info/sct 424616004 Without regard to meals (qualifier value)