Coder Social home page Coder Social logo

smart-on-fhir-tutorial's People

Contributors

amcginn avatar kolkheang avatar kpshek avatar level60warlock avatar maxphilips avatar rayguny avatar xiaoningmzhang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

smart-on-fhir-tutorial's Issues

Small issues with the tutorial (misspelled words, wrong link)

I recently finished the tutorial and found a few small issues with the tutorial. Would it be possible to get these issues updated?

The issues I noticed:

  • The EHR App Launch Flow diagram and the Patient App Launch Flow diagram both have "authorization" spelled incorrectly on an arrow.
  • The registration process for apps has changed slightly from what the tutorial mentions. The registration process now asks for a Type of Access (online or offline), and there is no longer an Authorized field to select.
  • The link to a discussion on patient credentials (Launch a Standalone App section) doesn't contain working test data for Sandbox. I did see the link to a Google Doc at the very end of the discussion that contains test data; would it be possible to change the tutorial to point to that Google doc instead of the discussion post?

Incorrect links and instructions in tutorial

  1. “Project Setup” section
  • The folder name "smart-on-fhir-tutorial/source/example-smart-app" is no longer valid. It should be "smart-on-fhir-tutorial/example-smart-app".
  • “fhir-client.js” file name is not accurate. It would be better to list it as “fhir-client-version#.js” or something similar as we pulled one version of the open source fhir client file in this tutorial. The file is mentioned several times in the tutorial, including code snippet.
  • The link in this statement “Additional documentation on fhir-client.js can be found here.” is not valid anymore. http://docs.smarthealthit.org/client-js/node.html might be the new link.
  1. “Access FHIR resource “ section
  • The last link is not available anymore. Same as 1.c
  1. “Test your app” section
  • The description says the console will ask whether the app requires a patient before you select a patient. However, it seems like it always shows the list of patients. Have we removed the option of not involving a patient context?
  • No matter if selecting showing banner to display or not, I never could see a patient demo banner when the page is launched.
  1. “MPages Integration” section
  • The tutorial and the code snippet are inconsistent with our latest code in the repository. The tutorial mentioned that we already had the set up to securely embed the SMART app into MPage view, but it doesn’t show in the same way in the code.
  • Not seeing "hidden" attribute to the tag in index, health, launch.html files
  • "babel-polyfill" are commented out
  • "cerner-smart-embeddable-lib" are commented out

Cannot find Authorization server

Hi, everyone!
I have some troubles in process of authorization of my SMART App.
In the tutorial, they wrote about Authrization:
"The responsibility of launch.html is to redirect to the appropriate FHIR authorization server. As you can see in the code, fhir-client makes our job pretty easy. All we have to do is call FHIR.oauth2.authorize and supply the client_id generated by the code console during registration and the scopes we registered."

But when I deploy and go to 'https://.github.io/smart-on-fhir-tutorial/example-smart-app/', the browser says 'Failed to call FHIR Service'.
Also when I go to 'https://.github.io/smart-on-fhir-tutorial/example-smart-app/launch.html' where function FHIR.oauth2.authorize is in, there is an error that is caused by no authorization server is identified.

Of course, I registered my app and now have a Client_ID, and use it in function FHIR.oauth2.authorize, as tutorial says.
I think when go to url 'https://.github.io/smart-on-fhir-tutorial/example-smart-app/launch.html', I should give it params 'iss' and 'launch'.
But for this, I need to know url of Authorization server.
It is what I cannot solve, and as it is the beginning of SMART app development, I could make no step in advance.

As I am not familiar with SMART app(though very experienced in api development using JS), really hope to see your kind reply.

Thank you.

Failed to call FHIR Service after launch

Hi,

I forked the smarton-fhir tutorial onto my computer and I managed to follow the steps from this url, including the outline for the project setup and registration without utilizing the bundle executable to deploy to github pages (just used git changes from the CL). I go to console code and click on the app I created and hit launch to transport me to the millenium sandbox login and enter the username and password provided. When I' redirected I get a p tag with the information:

Failed to call FHIR Service

Is my patient call using your example suppose to take me to an error point?

-Akeem Spencer

Problem registering App on Code Cerner

After getting Batman at Health page, I'm facing this msg:
image
while trying to register the App, at the second step of the tutorial; I tried in three different systems, with Chrome, IExplorer and Edge, to no avail.

Any directions?

Application may see a JavaScript error due to insufficient Observation data

The sample application can run into a JavaScript error when the response from the server does not have the appropriate Observation data. The application should ensure that data is valid before accessing the data.

The component object can be nil. Currently the find function is accessing this component object without checking.

https://github.com/cerner/smart-on-fhir-tutorial/blob/gh-pages/example-smart-app/src/js/example-smart-app.js#L92-L93

Official sample App is not working - Throwing 'Failed to call FHIR service' error

I am following tutorial https://engineering.cerner.com/smart-on-fhir-tutorial/#introduction and trying to test my sample app which is forked as mentioned in the documentation. Followed all instructions mentioned in documentation.

While testing the app, i am getting 'Failed to call FHIR service' error

My git repository is https://github.com/dhaneshov/smart-on-fhir-tutorial

x-request-id returned by the response

Request URL : https://fhir-ehr-code.cerner.com/dstu2/ec2458f2-1e24-41c8-b71b-0e701af7583d/Patient/12724065
X-Request-Id: 7137e0e7-a557-4a5b-a559-437e9da76d30

Request URL: https://fhir-ehr-code.cerner.com/dstu2/ec2458f2-1e24-41c8-b71b-0e701af7583d/Observation?code=http%3A%2F%2Floinc.org%7C8302-2%2Chttp%3A%2F%2Floinc.org%7C8462-4%2Chttp%3A%2F%2Floinc.org%7C8480-6%2Chttp%3A%2F%2Floinc.org%7C2085-9%2Chttp%3A%2F%2Floinc.org%7C2089-1%2Chttp%3A%2F%2Floinc.org%7C55284-4&patient=12724065
X-Request-Id: 5f1359ec-ef71-4dea-9d75-ecef3eb7ba18

Example app misinterprets patient date of birth

When the example app gets the JSON about the patient, it has a bug in translating the JSON of the birthdate (say, "2012-02-19") into a local date ("2/19/2012").

It's off by one day. The JSON may say "2012-02-19," but the date displayed says "2/18/2012". This is because the example app just feeds the JSON into a JavaScript Date object (https://github.com/cerner/smart-on-fhir-tutorial/blob/gh-pages/example-smart-app/src/js/example-smart-app.js#L30)

Note I am not talking about being off by one month. You've already adjusted the month for January being 0 not 1. I am talking about being off by one day.

The problem is that when you initialize the Date object with a date string, it interprets it as UTC time zone, not local time zone. But then when you run .getDate(), it gives you local time zone. So "2012-02-19" is interpreted as a UTC date of midnight on 2/19, which when localized to the US will come across as some time the day before.

"parsing of date strings with the Date constructor (and Date.parse, they are equivalent) is strongly discouraged" --- https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date

Currently:

var dob = new Date(patient.birthDate);

Suggested (use the multi-argument version of Date, something like this)

var dob = patient.birthDate.split('-');
dob[1]--; // in JavaScript, January is 0
dob = new Date(dob[0], dob[1], dob[2]);

"Being Testing" is not available on Cerner Code Console

I am trying to test my app and need a test provider/patient credential. The guide for this repo stated the following

Next log back into the code console and click on the app you’ve registered (My amazing SMART app). To launch your app through the code console click the “Begin Testing” button. The console will ask if the app you’re launching requires a patient in context. Our app requires a patient, so select yes and choose a patient. Please note the millennium username and password, you’ll need this credential when prompted. Finally, click launch and the console will redirect to your application.

However, I was unable to see a "Being Testing" button in my code console. Is this instruction still valid? If not, how should I go about getting a sandbox provider/patient credential for testing openid/Oauth2 for instance?

Thanks!

Cannot find Authorization Server

Hi, everyone!
I have some troubles in process of authorization of my SMART App.
In the tutorial, they wrote about Authrization:
"The responsibility of launch.html is to redirect to the appropriate FHIR authorization server. As you can see in the code, fhir-client makes our job pretty easy. All we have to do is call FHIR.oauth2.authorize and supply the client_id generated by the code console during registration and the scopes we registered."

But when I deploy and go to 'https://.github.io/smart-on-fhir-tutorial/example-smart-app/', the browser says 'Failed to call FHIR Service'.
Also when I go to 'https://.github.io/smart-on-fhir-tutorial/example-smart-app/launch.html' where function FHIR.oauth2.authorize is in, there is an error that is caused by no authorization server is identified.

Of course, I registered my app and now have a Client_ID, and use it in function FHIR.oauth2.authorize, as tutorial says.
I think when go to url 'https://.github.io/smart-on-fhir-tutorial/example-smart-app/launch.html', I should give it params 'iss' and 'launch'.
But for this, I need to know url of Authorization server.
It is what I cannot solve, and as it is the beginning of SMART app development, I could make no step in advance.

As I am not familiar with SMART app(though very experienced in api development using JS), really hope to see your kind reply.

Thank you.

HL7

Does smart app API provide HL7 values?

The supplied "client_id" value does not correspond to any registered applications on record.

Getting the below error when lunch App from SMART code console. The App has been registered.
An application was attempting to request access to healthcare data with Abilities Center; unfortunately, the application isn't currently registered. If you require further assistance, please contact support.
Information to provide to Technical Support
Correlation ID:cbcc7b39-99a9-4a9f-98cb-cf1eec04bdcb
Information to provide to Unknown Application
The supplied "client_id" value does not correspond to any registered applications on record.
Error Code:urn:cerner:error:authorization-server:oauth2:grant:unknown-client

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.