Another one
Here's my profile for a patient with an extension that communicated the language ability of the patient.
Json version:
{ "resourceType": "StructureDefinition", "id": "mirjam-patient-language", "url": "http://mirjams.example.org/StructureDefinition/patient-with-language", "name": "PatientWithLanguage", "status": "draft", "date": "2018-03-27T14:03:07.565+01:00", "fhirVersion": "3.0.1", "kind": "resource", "abstract": false, "type": "Patient", "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Patient", "derivation": "constraint", "differential": { "element": [ { "id": "Patient.name", "path": "Patient.name", "max": "1" }, { "id": "Patient.communication.extension", "path": "Patient.communication.extension", "slicing": { "discriminator": [ { "type": "value", "path": "url" } ], "rules": "open" } }, { "id": "Patient.communication.extension:spokenorwritten", "path": "Patient.communication.extension", "sliceName": "spokenorwritten", "max": "1", "type": [ { "code": "Extension", "profile": "http://mirjam.example.org/StructureDefinition/SpokenOrWrittenExtension" } ] } ] } }