Перейти к содержанию

JSON примеры для выполнения операции выписки электронного рецепта с ЭЦП

Пример 1

Ресурс Parameters с min набором полей в ресурсе MedicationPrescription

{
  "resourceType":"Parameters",
  "parameter":[
    {
      "name":"medicationprescription",
      "resource":
      {"resourceType": "MedicationPrescription",
    "meta": {
        "profile": ["http://fhir.org/fhir/StructureDefinition/by-medicationprescription"]
    },
    "contained": [
        {
        "resourceType": "Medication",
        "id": "internalMedication1",
        "code": {
            "coding": [{
                "system": "http://www.pharma.by/Справочник.Дозировка",
                "code": "53903",
                "display": "Аква Марис спрей назальн. 30мл флакон №1"
            }]
        },
        "isBrand": true,
        "kind": "product",
        "product": {

            "ingredient": [{
                "item": {"reference": "#internalMedication2"}
            }]
        }
    },
        {
        "resourceType": "Medication",
        "id": "internalMedication2",
        "code": {
            "coding": [{
                "system": "http://www.pharma.by/Справочник.МеждународноеНаименование",
                "code": "14556",
                "display": "Аква Марис Плюс"
            }]
        },
        "isBrand": false
    }],
    "extension": [{
        "url": "http://fhir.org/fhir/StructureDefinition/by-medicamentType",
        "valueCodeableConcept": {
            "coding": [{
                "system": "http://hl7.org/fhir/vs/by-medicament-type",
                "code": "medicinal"
            }]
        }
    }],
    "dateWritten": "2018-06-15",
    "status": "active",
    "patient": {
    "reference": "Patient/{{PatientId}}",
     "display": "Денисенко Кирилл Дмитриевич",
        "extension":  [{
            "url":"http://uiip.bas-net.by/hl7/fhir/patient-medication-card", 
            "valueReference":{"reference":"Patient?identifier=5362789032573296"} 
        } ]
    },
    "prescriber": {
        "reference": "Practitioner/{{PractitionerId}}",
        "display":"Титчев Сергей Леонидович",
            "extension":  [{
                "url":"http://uiip.bas-net.by/hl7/fhir/practitioner-personal-passport-number", 
                "valueReference":{"reference":"Practitioner?identifier=7357494A001PB6"} 
            } ]
    },
    "medication": {
        "reference": "#internalMedication1"
    },
     "dosageInstruction": [{
        "text": "2 раза в день"
    }],
    "dispense": {
        "validityPeriod": {
            "start": "2018-06-15",
            "end": "2021-01-01"
        },
        "quantity": {
            "value": 10.1
        }
    }
 }
    },
    {
     "name":"DigitalSignature",
     "valueBase64Binary":""
   }
    ]
}

Ресурс MedicationPrescription, подготовленный для подписи

{"contained":[{"code":{"coding":[{"code":"53903","display":"Аква Марис спрей назальн. 30мл флакон №1","system":"http://www.pharma.by/Справочник.Дозировка"}]},"id":"internalMedication1","isBrand":true,"kind":"product","product":{"ingredient":[{"item":{"reference":"#internalMedication2"}}]},"resourceType":"Medication"},{"code":{"coding":[{"code":"14556","display":"Аква Марис Плюс","system":"http://www.pharma.by/Справочник.МеждународноеНаименование"}]},"id":"internalMedication2","isBrand":false,"resourceType":"Medication"}],"dateWritten":"2018-06-15","dispense":{"quantity":{"value":10.1},"validityPeriod":{"end":"2021-01-01","start":"2018-06-15"}},"dosageInstruction":[{"text":"2 раза в день"}],"extension":[{"url":"http://fhir.org/fhir/StructureDefinition/by-medicamentType","valueCodeableConcept":{"coding":[{"code":"medicinal","system":"http://hl7.org/fhir/vs/by-medicament-type"}]}}],"medication":{"reference":"#internalMedication1"},"patient":{"display":"Денисенко Кирилл Дмитриевич","extension":[{"url":"http://uiip.bas-net.by/hl7/fhir/patient-medication-card","valueReference":{"reference":"Patient?identifier=5362789032573296"}}]},"prescriber":{"display":"Титчев Сергей Леонидович","extension":[{"url":"http://uiip.bas-net.by/hl7/fhir/practitioner-personal-passport-number","valueReference":{"reference":"Practitioner?identifier=7357494A001PB6"}}]},"resourceType":"MedicationPrescription"}

Пример 2

Ресурс Parameters с max набором полей в ресурсе MedicationPrescription

{
  "resourceType":"Parameters",
  "parameter":[
    {
      "name":"medicationprescription",
      "resource":
      {"resourceType": "MedicationPrescription",
    "meta": {
        "profile": ["http://fhir.org/fhir/StructureDefinition/by-medicationprescription"]
    },
     "identifier": [
      {
         "system":  "http://uiip.bas-net.by/hl7/fhir/serial-number",
         "value":  "МН-0011234567"
      }
   ],
    "contained": [
        {
        "resourceType": "Medication",
        "id": "internalMedication1",
        "code": {
            "coding": [{
                "system": "http://www.pharma.by/Справочник.Дозировка",
                "code": "53903",
                "display": "Аква Марис спрей назальн. 30мл флакон №1"
            }]
        },
        "isBrand": true,
        "kind": "product",
        "product": {
            "form": {
                "coding": [{
                    "system": "http://www.pharma.by/Справочник.ЛекарственнаяФорма",
                    "code": "0081",
                    "display": "капли в нос"
                }]
            },
            "ingredient": [{
                "item": {
                    "reference": "#internalMedication2"
                }
            }]
        }
    },
        {
        "resourceType": "Medication",
        "id": "internalMedication2",
        "code": {
            "coding": [{
                "system": "http://www.pharma.by/Справочник.МеждународноеНаименование",
                "code": "14556",
                "display": "Аква Марис Плюс"
            }]
        },
        "isBrand": false
    }],
    "extension": [{
        "url": "http://fhir.org/fhir/StructureDefinition/by-medicamentType",
        "valueCodeableConcept": {
            "coding": [{
                "system": "http://hl7.org/fhir/vs/by-medicament-type",
                "code": "medicinal"
            }]
        }
    },
    {
        "url": "http://fhir.org/fhir/StructureDefinition/by-iteration",
        "valueCodeableConcept": {
            "coding": [
                {
                    "system": "http://hl7.org/fhir/vs/by-iteration",
                    "code": "once"
                }
            ]
        }
    },
    {
        "url": "http://fhir.org/fhir/StructureDefinition/by-quantityInIteration",
        "valueDecimal": 1.9
    },
    {
        "url": "http://fhir.org/fhir/StructureDefinition/by-factor",
        "valueDecimal": 0.9
    },
    {
        "url": "http://fhir.org/fhir/StructureDefinition/by-speedProduction",
        "valueCodeableConcept": {
            "coding": [{
                "system": "http://hl7.org/fhir/vs/by-speed-production",
                "code": "10",
                "display": "10"
            }]
        }
    }
    ],
    "dateWritten": "2018-06-15",
    "status": "active",
    "patient": {
    "reference": "Patient/{{PatientId}}",
     "display": "Денисенко Кирилл Дмитриевич",
        "extension":  [{
        "url":"http://uiip.bas-net.by/hl7/fhir/patient-medication-card", 
        "valueReference":{"reference":"Patient?identifier=5362789032573296"} } ]
    },
    "prescriber": {
        "reference": "Practitioner/{{PractitionerId}}",
        "display":"Титчев Сергей Леонидович",
            "extension":  [{
            "url":"http://uiip.bas-net.by/hl7/fhir/practitioner-personal-passport-number", 
            "valueReference":{"reference":"Practitioner?identifier=7357494A001PB6"} } ]
    },
    "note": "Дополнительные сведения о рецепте",
    "medication": {
        "reference": "#internalMedication1"
    },
    "dosageInstruction": [{
        "text": "2 раза в день"
    }],
    "dispense": {
        "validityPeriod": {
            "start": "2018-06-15",
            "end": "2021-01-01"
        },
        "numberOfRepeatsAllowed": 1,
        "quantity": {
            "value": 10.1
        }
    }
 }
    },
    {
     "name":"DigitalSignature",
     "valueBase64Binary":""
   }
    ]
}

Ресурс MedicationPrescription, подготовленный для подписи

{"contained":[{"code":{"coding":[{"code":"53903","display":"Аква Марис спрей назальн. 30мл флакон №1","system":"http://www.pharma.by/Справочник.Дозировка"}]},"id":"internalMedication1","isBrand":true,"kind":"product","product":{"form":{"coding":[{"code":"0081","display":"капли в нос","system":"http://www.pharma.by/Справочник.ЛекарственнаяФорма"}]},"ingredient":[{"item":{"reference":"#internalMedication2"}}]},"resourceType":"Medication"},{"code":{"coding":[{"code":"14556","display":"Аква Марис Плюс","system":"http://www.pharma.by/Справочник.МеждународноеНаименование"}]},"id":"internalMedication2","isBrand":false,"resourceType":"Medication"}],"dateWritten":"2018-06-15","dispense":{"numberOfRepeatsAllowed":1,"quantity":{"value":10.1},"validityPeriod":{"end":"2021-01-01","start":"2018-06-15"}},"dosageInstruction":[{"text":"2 раза в день"}],"extension":[{"url":"http://fhir.org/fhir/StructureDefinition/by-medicamentType","valueCodeableConcept":{"coding":[{"code":"medicinal","system":"http://hl7.org/fhir/vs/by-medicament-type"}]}},{"url":"http://fhir.org/fhir/StructureDefinition/by-factor","valueDecimal":0.9},{"url":"http://fhir.org/fhir/StructureDefinition/by-speedProduction","valueCodeableConcept":{"coding":[{"code":"10","display":"10","system":"http://hl7.org/fhir/vs/by-speed-production"}]}}],"identifier":[{"system":"http://uiip.bas-net.by/hl7/fhir/serial-number","value":"МН-0011234567"}],"medication":{"reference":"#internalMedication1"},"note":"Дополнительные сведения о рецепте","patient":{"display":"Денисенко Кирилл Дмитриевич","extension":[{"url":"http://uiip.bas-net.by/hl7/fhir/patient-medication-card","valueReference":{"reference":"Patient?identifier=5362789032573296"}}]},"prescriber":{"display":"Титчев Сергей Леонидович","extension":[{"url":"http://uiip.bas-net.by/hl7/fhir/practitioner-personal-passport-number","valueReference":{"reference":"Practitioner?identifier=7357494A001PB6"}}]},"resourceType":"MedicationPrescription"}