I am in the process of learning how to write apps using smart-on-fhir. I have gone through the tutorials on
http://docs.smarthealthit.org/tutorials/ , and I am running into some issues regarding updating a record.
The first tutorial has a simple program on plnkr and I put in an update:
smart.api.update({type: pt.resourceType, data: JSON.stringify(pt), id:
pt.id});
This allowed me, as far as I can tell, to successfully change something in pt (gender, for example). Then when I read into pt again, it would have the changes that I put.
I tried the same thing with the Cerner Sandbox SMART-on-FHIR Tutorial. When I try to update, it gives a 404 error (not found). I checked the 3 parameters, and they seem to be inputting the right data, but for some reason, it isn't working.
I am thinking this might have something to do with the second example needing authorization. Or maybe the environment,
code.cerner.com , doesn't allow for updates.
If anyone has any info that would help me figure out my problem, I would greatly appreciate it!