You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 10 Current »

Medication prescriptions can be sent to RED using the FHIR interface and are stored in the RED database (see RED interchange API - Create Data Medication). In order to create prescriptions the user must be in the role of a physician and use a physician SMC-B card.

Processing of the electronic prescriptions may be triggered by a separate request (e.g. at the end of the day). RED processes all stored prescriptions that have not been processed yet, prompts the user for the electronic signature, sends the signed prescriptions to Fachdienst and returns an array of all task-ids. In order to accept a process prescriptions must be in the role of a physician and use a physician SMC-B card.

GET request triggering bulk processing requests for electronic prescriptions
{{baseURL}}/{{tenant}}/TI?action=$processerp

See RED Interchange API - Postman Collection 

  • 0231- Patient und Medication PZN and create ERP: creates a new person with coverage, practitioner and organization and medication, then creates an electronic prescription and returns the prescription task ID
  • 0233 - Patient und Medication Rezeptur and create ERP: creates a new person with coverage, practitioner and organization and medication for an extemporaneous mixture, then creates an electronic prescription and returns the prescription task ID

Additional parameters

The request may be extended by additional parameters

cardname: specify the Name of the HBA to be used for signature creation. Requires to set the name to HBC card in RED before

Example of a request with cardname parameter
{{baseURL}}/{{tenant}}/Bundle?action=$createerp&cardname=HBAArzt

hbaiccsn and smcbiccsn: specify the ICCSN-IDs of HBA and SMC-B to be used. The ICCSNs can be fetched by using a getCards request. They are assigned to the card and will not change over time

Example of a request with iccsn parameters
{{baseURL}}/{{tenant}}/Bundle?action=$createerp&hbaiccsn=80276883110000136667&smbiccsn=80276883110000117848

patientdocument: after the prescription has been handed over to Fachdienst this returns the token and access code and a base64 string representing the patient document with the barcode for the pharmacy

Example of a request with patient document
{{baseURL}}/{{tenant}}/Bundle?action=$createerp&patientdocument=true

RED returns an array of prescriptions with person information and prescription lines

Result of bulk processing of a stored prescription
<Prescriptions>
    <person>
        <person>
            <lastname>Kastner</lastname>
            <firstname>Tobias</firstname>
            <birthday>1935-05-21</birthday>
        </person>
        <prescriptions>
            <prescription>
                <name>ENCEPUR KINDER / 1 FER N1</name>
                <url>{"urls":["Task/160.000.203.391.781.13/$accept?ac=1da7bf1a92146b0d249380df07150465c0945798c1c9f65aadf8c3de687bb685"]}</url>
            </prescription>
        </prescriptions>
    </person>
    <person>
        <person>
            <lastname>Meier</lastname>
            <firstname>Luca</firstname>
            <birthday>2012-10-08</birthday>
        </person>
        <prescriptions>
            <prescription>
                <name>Hydrochlorothiazid 2mg/ml (NRF 26.4) Suspension</name>
                <url>{"urls":["Task/160.000.203.391.782.10/$accept?ac=2058ffbe2fbf0ac890d948ded9e5d9a7f777783f6f233d05a38849fdf019483f"]}</url>
            </prescription>
        </prescriptions>
    </person>
    <person>
        <person>
            <lastname>Finkel</lastname>
            <firstname>Michelle</firstname>
            <birthday>2005-05-08</birthday>
        </person>
        <prescriptions>
            <prescription>
                <name>Viskose Aluminiumchlorid Hexahydrat-Lösung 20%(NRF 11.132.)</name>
                <url>{"urls":["Task/160.000.203.391.783.07/$accept?ac=45111875220241da5aa3f8c4a16580e5fc3d4aea2fdd4acdf507bada90828b8a"]}</url>
            </prescription>
        </prescriptions>
    </person>
</Prescriptions>

If the request could not be processed successfully an error message is returned

Error object
{
    "Error": {
        "key": "erp.service.signdocument.error",
        "desc": "Es gab ein Problem beim Signieren des Dokuments",
        "hint": "Möglicherweise wurde die PIN nicht korrekt eingegeben?"
    }
}
  • No labels