You can grab the demo number from your search result and then call another
endpoint:
/demographics/{demo number}
The response should have the email, etc in JSON
This OSCAR API is kinda poor...
On Wed, Apr 5, 2023 at 10:31 AM Adrian Starzynski <ad...@ad...> wrote:
> (To clarify I need to get the email value for a demographic number, and if
> possible also be able to lookup patient by Dob/email)
> ------------------------------
> *From:* Adrian Starzynski <ad...@ad...>
> *Sent:* Wednesday, April 5, 2023 1:23:47 PM
> *To:* osc...@li... <
> osc...@li...>
> *Subject:* Re: REST endpoint for lookup demographic by HIN
>
>
> Ok thanks.
>
> I just noticed that the api response for get demographic by HIN and by ID
> via search term does not include email address.
>
>
>
> /ws/services/demographics/search?startIndex=0&itemsToReturn=100
>
>
>
> {
>
> "type": "HIN", // can also search DemographicNo and specify it as term
>
> "term": "1234567890",
>
> "active": true,
>
> "integrator": false,
>
> "outofdomain": true
>
> }
>
>
>
> Response (no email):
>
>
>
>
> "{\"offset\":0,\"limit\":0,\"total\":1,\"timestamp\":1680713767653,\"content\":[{\"demographicNo\":5,\"lastName\":\"TEST\",\"firstName\":\"PATIENT\",\"chartNo\":\"\",\"sex\":\"M\",\"dob\":946713600000,\"providerNo\":\"7\",\"providerName\":\"Test,Adrian\",\"rosterStatus\":\"\",\"patientStatus\":\"AC\",\"phone\":\"905-555-1234\",\"hin\":\"5555555555\",\"remoteFacilityId\":null,\"formattedDOB\":\"2000-01-01\"}],\"query\":null}"
>
>
>
> What is correct endpoint for the email lookup method do you know?
>
>
>
> *From: *Yehia Qaisy <ys...@ho...>
> *Date: *Wednesday, April 5, 2023 at 12:02 PM
> *To: *osc...@li... <
> osc...@li...>
> *Subject: *Re: [Oscarmcmaster-devel] REST endpoint for lookup demographic
> by HIN
>
> Use HIN as the unique identifier by searching by HIN, then match the
> returned DOB with the DOB of patient to lookup.
>
>
>
> Regards,
>
> Yehia Qaisy, MD
>
>
>
> Sent from Mail <https://go.microsoft.com/fwlink/?LinkId=550986> for
> Windows 10
>
>
>
> *From: *Adrian Starzynski <ad...@ad...>
> *Sent: *Wednesday, April 5, 2023 5:41 PM
> *To: *osc...@li...
> *Subject: *Re: [Oscarmcmaster-devel] REST endpoint for lookup demographic
> by HIN
>
>
>
> Thanks Dr. Qaisy that is exactly what I needed.
>
>
>
> What is the best api search method to lookup a demographic by HIN and DOB
> (my goal is to lookup only a direct match) -- since HIN is always unique
> should it simply be search by HIN, then the application should take the DOB
> returned and compare to the DOB of the patient to lookup in question to see
> if it is match OR is there an api search where you can specify both HIN and
> DOB and get no result if no match.
>
> *From:* Yehia Qaisy <ys...@ho...>
> *Sent:* April 5, 2023 4:03 AM
> *To:* osc...@li... <
> osc...@li...>
> *Subject:* Re: [Oscarmcmaster-devel] REST endpoint for lookup demographic
> by HIN
>
>
>
> Hi Adrian,
>
>
>
> You can use the endpoint and webservice search with POST method and using
> params: startIndex and itemsToReturn
>
>
>
> as an example:
>
>
>
> /ws/services/demographics/search?startIndex=0&itemsToReturn=100
>
>
>
> on the post Body: to search by HIN, select HIN as type and use term for
> HIN number value to search for.
>
> {
>
> "type": "HIN",
>
> "term": "1234567890",
>
> "active": true,
>
> "integrator": false,
>
> "outofdomain": true
>
> }
>
>
>
> See attachment for an example on postman and a code..
>
>
>
>
>
> Regards,
>
> Yehia Qaisy, MD
>
>
>
>
>
>
>
> Sent from Mail
> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgo.microsoft.com%2Ffwlink%2F%3FLinkId%3D550986&data=05%7C01%7C%7Ce5dc28d3b8de42c1d22a08db35db7b25%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638162989174382492%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=MTjlYegNhxrwE1BM8wDUB23cmn2nEwTExlHK1UeeCL8%3D&reserved=0>
> for Windows 10
>
>
>
> *From: *Adrian Starzynski <ad...@ad...>
> *Sent: *Wednesday, April 5, 2023 9:16 AM
> *To: *A list for advanced OSCAR user discussions
> <osc...@li...>;
> osc...@li...
> *Subject: *[Oscarmcmaster-devel] REST endpoint for lookup demographic by
> HIN
>
>
>
> Hello,
>
> Can anyone who knows share what is the Rest Api endpoint in OSCAR for
> looking up a patient demographic by HIN ?
>
> i.e. /ws/demographic/......search?hin=1234567890
>
>
>
> It's a commonly used endpoint in 99% of integrations but can't find any
> documentation on what the correct endpoint is exactly
>
>
>
> Thanks
>
>
>
>
>
> --
>
> Adrian Starzynski
>
>
>
>
>
>
>
>
> _______________________________________________
> Oscarmcmaster-devel mailing list
> Osc...@li...
> https://lists.sourceforge.net/lists/listinfo/oscarmcmaster-devel
>
|