Find

Question
· Jul 4, 2024

JWT enabled FHIR Server web app access

Hello Community,

I've configured a FHIR Server in FHIR Configuration "/csp/healthshare/learn1/fhir/r4 " and I enabled a JWT Authentication for this web application. I've invoked this url http://localhost:52773/csp/healthshare/learn1/fhir/r4/login with basic auth get the JWT token. Now I use the access token as a "Bearer" for GET the patient resource. But I got 401Unauthorized error. Anyway I can get the patient resource with basic auth. I tired assign with %ALL role for testing as well. Did I miss any additional configuration in "FHIR Server Configuration"

 

Discussion (0)1
Log in or sign up to continue
Article
· Jul 4, 2024 5m read

Application de génération de tests de messagerie HL7

Nous avons récemment mis en ligne sur OpenExchange une petite application que j'ai développée il y a quelque temps (et que @Jose-Tomas Salvador a améliorée et peaufinée) que j'utilise souvent lorsque j'ai besoin de générer de gros volumes de messagerie HL7.

L'application est développée en NodeJS et fonctionne en générant des données de patients et de médecins à partir de fichiers de départ que vous pouvez modifier à votre guise pour personnaliser les patients générés. L'application utilisera les patients générés pour préparer différents types de messages HL7. Pour le moment, l'application peut générer les types de messages suivants. Si le nombre de messages demandés dépasse le nombre de patients, les messages seront générés sur eux, créant ainsi plusieurs messages pour le même patient avec des heures différentes.

ADT^A08

Mettre à jour les données des patients avec les observations associées.

MSH|^~\&|HIS|HULP|EMPI||20240305120344||ADT^A08|176690|P|2.5.1
EVN|A08|20240305120344
PID|||1556655212^^^SERMAS^SN~230546^^^HULP^PI||GARCÍA PÉREZ^JUAN^^^||20150403|M|||PASEO PEDRO ÁLVAREZ 195 1 CENTRO^^LEGANÉS^MADRID^28379^SPAIN||555283055^PRN^^JUAN.GARCIA@YAHOO.COM|||||||||||||||||N|
PV1||N
OBX|1|NM|162986007^Pulso^SNM||79|^bpm|||||F|||20240305120344
OBX|2|NM|105723007^Temperatura^SNM||37|^Celsius|||||F|||20240305120344
OBX|3|NM|163030003^Presión sanguínea sistólica^SNM||139|^mmHg|||||F|||20240305120344
OBX|4|NM|163031004^Presión sanguínea diastólica^SNM||91|^mmHg|||||F|||20240305120344

ADT^A28

Ajoutez des informations sur le patient.

MSH|^~\&|HIS|HULP|EMPI||20240305120319||ADT^A28|377160|P|2.5.1
EVN|A28|20240305120319|20240305120319|1
PID|||1556655212^^^SERMAS^SN~922210^^^HULP^PI||GARCÍA PÉREZ^JUAN^^^||20150403|M|||PASEO PEDRO ÁLVAREZ^195 1 CENTRO^LEGANÉS^MADRID^28379^SPAIN||555283055^PRN^^JUAN.GARCIA@YAHOO.COM|||||||||||||||||N|
PV1||N
AL1|1|MA|^Polen de gramineas^|SV^^||20440605172902

SIU^S12

Nouveau rendez-vous patient.

MSH|^~\&|HIS|HULP|EMPI||20240305120758||SIU^S12|298114|P|2.5.1
SCH|607860^607860|92610^92610|||607860|TRA02^Visita de revisión de traumatología|Visita sucesiva trauma|TRA02|15|m|^^15^20240305161758^20240305163258|||||^GARCÍA ROJO^ÁLVARO^||||^GARCÍA GARCÍA^DIANA^|||||Scheduled
PID|||1556655212^^^SERMAS^SN~922210^^^HULP^PI||GARCÍA PÉREZ^JUAN ALBERTO^^^||20150403|M|||CALLE MARÍA JUAREZ 23 2A^^MÓSTOLES^MADRID^28045^SPAIN||555283055^PRN^^JUAN.GARCIA@YAHOO.COM|||||||||||||||||N|
PV1|1|O|||||^ ^^^MD^^^^|^ ^^^MD^^^^||||||||||||||||||||||||||||||||||||||||||||
RGS|1|A
AIS|1|A|^|20240305161758|||15|m^Minutes||Scheduled
AIL|1|A|TRA02^^^|^||20240305161758|||15|m^Minutes||Scheduled
AIP|1|A|1^ ^^A^MD^^^^|D^, ||20240305161758|||15|m^Minutes||Scheduled

ORU^R01

Transmission non sollicitée de l’observation demandée.

MSH|^~\&|HIS|CHGM|EMPI||20240305121511||ORU^R01|16955|P|2.5.1
PID|||1556655212^^^SEGSOC^SSN~230546^^^CHGM^PI||GARCÍA PÉREZ^JUAN^^^||20150403|M|||PASEO PEDRO ÁLVAREZ 195 1 CENTRO^^LEGANÉS^MADRID^28379^SPAIN||555283055^PRN^^JUAN.GARCIA@YAHOO.COM|||||||||||||||||N|
PV1||O|||||079492022O^GARCÍA FERNÁNDEZ^PETRONILA^^MD^^^^|||||||1|||||450908|||||||||||||||||||||||||20240305121511|20240305121511
ORC|1|193683|8680||||^^^20240305121511||20240305121511|||0631438066E^MARGALL GARCÍA^MARCOS^^MD^^^^|CHGM||||||||CHGM||||||||LAB
OBR|1|193683|8680|LAB^LABORATORY^L||||||||||||0631438066E^MARGALL GARCÍA^MARCOS^^MD^^^^|||||||||F
OBX|1|NM|WBC^Conteo de glóbulos blancos^SNM||2.0|10(9)/L|4.0-10.6||||F|||20240305121511
OBX|2|NM|RBC^Conteo de glóbulos rojos^SNM||3.0|10x12/L|4.5-5.9||||F|||20240305121511
OBX|3|NM|HGB^Hemoglobina^SNM||13.0|g/dL|12.0-16.0||||F|||20240305121511
OBX|4|NM|HCT^Hematocrito^SNM||48.0|%|36.0-46.0||||F|||20240305121511
OBX|5|NM|MCV^Volumen celular medio^SNM||75|fL|80-100||||F|||20240305121511
OBX|6|NM|MCH^Hemoglobina celular media^SNM||22.0|pg|26-34||||F|||20240305121511
OBX|7|NM|MCHC^Concentración de hemoglobina celular media^SNM||24.0|g/dL|31-37||||F|||20240305121511
OBX|8|NM|RDW^Ancho de distribución eritrocitaria^SNM||15.0|%|11.5-14.5||||F|||20240305121511
OBX|9|NM|PLT^Conteo de plaquetas - Automatizado^SNM||284|10(9)L|140-440||||F|||20240305121511
OBX|10|NM|MPV^Volumen de plaquetas medio^SNM||10.0|UMx1000|8-11||||F|||20240305121511
OBX|11|NM|NE^# Neutrófilos^SNM||6.00|#|1.8-8.5||||F|||20240305121511
OBX|12|NM|LY^# Linfa^SNM||2.00|#|0.8-3.5||||F|||20240305121511
OBX|13|NM|MO^# Monocitos^SNM||0.00|#|0.2-0.9||||F|||20240305121511
OBX|14|NM|EO^# Eosinófilos^SNM||0.00|#|0.0-0.6||||F|||20240305121511
OBX|15|NM|BA^# Basófilos^SNM||0.00|#|0.0-0.2||||F|||20240305121511
OBX|16|NM|PERCENTNE^% Neutrófilos^SNM||57.0|%|40-80||||F|||20240305121511
OBX|17|NM|PERCENTLY^% Linfa^SNM||19.0|%|15-45||||F|||20240305121511
OBX|18|NM|SEG^Neutrófilos segmentados^SNM||55.0|%|50-75||||F|||20240305121511
OBX|19|NM|LYMPHS^Linfocitos^SNM||37.0|%|20-44||||F|||20240305121511
OBX|20|NM|MONO^Monocitos^SNM||2.0|%|2-9||||F|||20240305121511
OBX|21|NM|ATYP^Linfocitos atípicos^SNM||33|%|0-100||||F|||20240305121511

Comment ça fonctionne

Le README.md associé au projet explique comment déployer l'application. Pour y accéder, il vous suffira de saisir l'URL dans votre navigateur internet : http://localhost:5000, et la fenêtre principale s'ouvrira automatiquement.

Ci-dessous vous pouvez indiquer le nombre de patients souhaités et le nombre de médecins. Avec les deux fichiers générés, vous pouvez générer autant de messages que vous le souhaitez des types décrits ci-dessus.

Vous avez la possibilité de générer des messages pour différentes autorités assignatrices (l'organisme qui attribue le numéro d'historique) ainsi que différents identifiants des patients (numéro de sécurité sociale, NIF, etc...).

Comme vous pouvez le constater, il s'agit d'une application basique, n'hésitez pas à modifier ce que vous souhaitez et à l'adapter à vos besoins et si vous avez des questions à ce sujet, écrivez-les dans les commentaires.

Pd. : Les fichiers sont en espagnol, désolé !

Discussion (0)1
Log in or sign up to continue
Article
· Jul 4, 2024 1m read

How to change the special variable $ZTIMESTAMP to your local time zone

InterSystems FAQ rubric

$ZTIMESTAMP returns the date and time in UTC format, so to change it to the local time zone, use the following system method: 

$SYSTEM.Util.UTCtoLocalWithZTIMEZONE($ZTIMESTAMP)

The above output will be in the format ddddd,sssss.fff.

    ddddd: Same format as $HOROLOG dates
 sssss: An integer indicating the number of seconds elapsed since midnight on the current date
 fff: Variable number of digits indicating the fractional part of a second

* Similar to $HOROLOG, except that $HOROLOG does not include fractional seconds. 

SAMPLES>write $SYSTEM.Util.UTCtoLocalWithZTIMEZONE($ZTIMESTAMP)," - ", $horolog,!
63895,64252.66 - 63895,64252
SAMPLES>write $ZDATETIME($SYSTEM.Util.UTCtoLocalWithZTIMEZONE($ZTIMESTAMP),8)
20151209 17:45:56
SAMPLES>write $ZDATETIME($ZTIMESTAMP,8)
20151209 08:46:05
SAMPLES>
1 Comment
Discussion (1)1
Log in or sign up to continue
Question
· Jul 4, 2024

forward REST calls and retain path parameters

Hi, I have a controller which handles accounts, and forwards to the relevant controller based on the path, example below:

XData UrlMap
{
<Routes>

<Map Prefix="/:accountId/anothercontroller" Forward="AnotherController"/>

</Routes>
}

Problem is that inside AnotherController, the accountId path parameter is lost, I assume that's because the map forward simply checks if there's a match then forwards.

AnotherController:

XData UrlMap
{
<Routes>

<Route Url="/:somethingId" Method="POST" Call="CreateSomething"/>

</Routes>
}
ClassMethod CreateSomething(somethingId)
{
}

The reason for this is because I don't want to specify the same route including the accountId for many routes, instead is it possible to forward the accountId to get something like this:

XData UrlMap
{
<Routes>

<Route Url="/:somethingId" Method="POST" Call="CreateSomething"/>

</Routes
}
/// accountId passed through and accessible
ClassMethod CreateSomething(accountId, somethingId)
{
}

 

We'll be upgrading to IRIS soon, so if it is possible there I'd love to know where I can read more about how to do so.

Thank you.

2 Comments
Discussion (2)0
Log in or sign up to continue
Article
· Jul 4, 2024 9m read

Criação de uma aplicação web React simples com backend IRIS: resolução de CORS

Integrar aplicações frontend de React com serviços backend como a base de dados IRIS através de APIs REST pode ser uma forma poderosa de contruir aplicações web robustas. No entanto, um obstáculo comum que os desenvolvedores costumam encontrar é o problema de Cross-Origin Resource Sharing (CORS), que pode impedir que o frontend acesse os recursos no backend devido a restrições de segurança impostas pelos navegadores web. Nesse artigo, exploraremos como abordar os problemas de CORS ao integrar aplicações web de React com serviços backend de IRIS.

Discussion (0)1
Log in or sign up to continue