{"id":22,"date":"2020-03-19T19:20:43","date_gmt":"2020-03-19T19:20:43","guid":{"rendered":"http:\/\/thecloudmarathoner.com\/?p=22"},"modified":"2021-03-08T04:37:12","modified_gmt":"2021-03-08T04:37:12","slug":"place-holder-post-3","status":"publish","type":"post","link":"https:\/\/thecloudmarathoner.com\/index.php\/2020\/03\/19\/place-holder-post-3\/","title":{"rendered":"Setting up Microsoft FHIR Server on your laptop &#038; FHIR-ing up&#8230;"},"content":{"rendered":"\n<p>Hello my FHIR-ly friends, and welcome to my first post on Microsoft FHIR server!<\/p>\n\n\n\n<p>Over the last few months, i worked with Microsoft Open Source FHIR Server (OSS) and wanted to share my experience on setting it up and running locally. Yes, you may run it locally without internet \ud83d\ude42<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-style-default\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"320\" src=\"\/wp-content\/uploads\/2021\/03\/MS-FHIR-setp-1024x320.jpg\" alt=\"\" class=\"wp-image-46\" srcset=\"\/wp-content\/uploads\/2021\/03\/MS-FHIR-setp-1024x320.jpg 1024w, \/wp-content\/uploads\/2021\/03\/MS-FHIR-setp-300x94.jpg 300w, \/wp-content\/uploads\/2021\/03\/MS-FHIR-setp-768x240.jpg 768w, \/wp-content\/uploads\/2021\/03\/MS-FHIR-setp.jpg 1047w\" sizes=\"auto, (max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>This might be helpful, if you just starting to learn HL7 FHIR (<a rel=\"noreferrer noopener\" href=\"https:\/\/www.hl7.org\/fhir\/\" target=\"_blank\">https:\/\/www.hl7.org\/fhir\/<\/a>) and don&#8217;t \/ can&#8217;t spin one on your cloud environment of choice. You might also use any publicly available FHIR endpoints, discover-able from the link above.<\/p>\n\n\n\n<p>Following steps will assist you in spinning it with a Cosmos DB (emulator flavor) or a more traditional SQL Server instance. Well, let&#8217;s start right away!<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>First, let&#8217;s get the latest code:&nbsp;<a href=\"https:\/\/github.com\/microsoft\/fhir-server\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/github.com\/microsoft\/fhir-server<\/a>&nbsp;<\/li><li>Install Visual Studio 17\/19 with updates (the community version is FREE \ud83d\ude42<\/li><li>We have 2 dependencies: Cosmos DB emulator or SQL Server (depending on the data layer you&#8217;ve chosen). We will continue with instructions on Cosmos DB, and show the tip for launching it with local SQL instance as well.<\/li><li>Install Dot Net SDK 2.2.* (<a href=\"https:\/\/dotnet.microsoft.com\/download\/dotnet-core\/2.2\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/dotnet.microsoft.com\/download\/dotnet-core\/2.2<\/a>). Don&#8217;t forget to check the docs, in case it is updated to a higher version \ud83d\ude09<\/li><li>Install Azure Cosmos Emulator (<a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/cosmos-db\/local-emulator\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/docs.microsoft.com\/en-us\/azure\/cosmos-db\/local-emulator<\/a>&nbsp;).<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large is-style-default\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"727\" src=\"\/wp-content\/uploads\/2021\/03\/1584667213334-1024x727.png\" alt=\"\" class=\"wp-image-44\" srcset=\"\/wp-content\/uploads\/2021\/03\/1584667213334-1024x727.png 1024w, \/wp-content\/uploads\/2021\/03\/1584667213334-300x213.png 300w, \/wp-content\/uploads\/2021\/03\/1584667213334-768x545.png 768w, \/wp-content\/uploads\/2021\/03\/1584667213334.png 1120w\" sizes=\"auto, (max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>In VS open\u00a0Microsoft.Health.Fhir.sln\u00a0&amp; restore the packages<\/li><li>Run the build process &amp; set\u00a0<a rel=\"noreferrer noopener\" href=\"http:\/\/microsoft.health.fhir.stu3.web\/\" target=\"_blank\">Microsoft.Health.Fhir.Stu3.Web<\/a>\u00a0\u00a0as a start-up project<\/li><li><strong>Note<\/strong>: You could also use\u00a0<a rel=\"noreferrer noopener\" href=\"http:\/\/microsoft.health.fhir.r4.web\/\" target=\"_blank\">Microsoft.Health.Fhir.R4.Web<\/a>\u00a0\u00a0&#8211; based on fhir resource versions that you are planning to load.<\/li><li>Made following changes in\u00a0appsettings.json<\/li><\/ul>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code>\"Security\": {\r\n      \"Enabled\": true,\r\n      \"EnableAadSmartOnFhirProxy\": false,\r\n        \"Authentication\": {\r\n            \"Audience\": \"fhir-api\",\r\n            \"Authority\": \"https:\/\/localhost:44348\"\r\n        },\r\n      \"PrincipalClaims\": &#91;\r\n        \"iss\",\r\n        \"oid\"\r\n      ],\r\n      \"Authorization\": {\r\n        \"Enabled\": true\r\n      }\r\n    },<\/code><\/pre>\n<\/div><\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Option 1<\/strong>: Selecting\u00a0<strong>Cosmos DB<\/strong>\u00a0data layer <\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"580\" src=\"\/wp-content\/uploads\/2021\/03\/1584667354825-1024x580.png\" alt=\"\" class=\"wp-image-95\" srcset=\"\/wp-content\/uploads\/2021\/03\/1584667354825-1024x580.png 1024w, \/wp-content\/uploads\/2021\/03\/1584667354825-300x170.png 300w, \/wp-content\/uploads\/2021\/03\/1584667354825-768x435.png 768w, \/wp-content\/uploads\/2021\/03\/1584667354825-1200x680.png 1200w, \/wp-content\/uploads\/2021\/03\/1584667354825.png 1265w\" sizes=\"auto, (max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Option 2: Select SQL data layer &amp; start project (aka Press F5)<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"919\" height=\"828\" src=\"\/wp-content\/uploads\/2021\/03\/1584667523319.png\" alt=\"\" class=\"wp-image-96\" srcset=\"\/wp-content\/uploads\/2021\/03\/1584667523319.png 919w, \/wp-content\/uploads\/2021\/03\/1584667523319-300x270.png 300w, \/wp-content\/uploads\/2021\/03\/1584667523319-768x692.png 768w\" sizes=\"auto, (max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Lunch the FHIR server locally by pressing F5 &#8211; should look like following screen:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"407\" src=\"\/wp-content\/uploads\/2021\/03\/1584667623195-1024x407.png\" alt=\"\" class=\"wp-image-97\" srcset=\"\/wp-content\/uploads\/2021\/03\/1584667623195-1024x407.png 1024w, \/wp-content\/uploads\/2021\/03\/1584667623195-300x119.png 300w, \/wp-content\/uploads\/2021\/03\/1584667623195-768x305.png 768w, \/wp-content\/uploads\/2021\/03\/1584667623195-1200x477.png 1200w, \/wp-content\/uploads\/2021\/03\/1584667623195.png 1269w\" sizes=\"auto, (max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Run postman Query for Server CapabilityStatement:&nbsp;<a href=\"https:\/\/localhost:44348\/metadata?_format=json\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/localhost:44348\/metadata?_format=json<\/a>&nbsp;<\/li><li>Check the Postman SSL certification verification is off, or accept the dotnet development certificate.<\/li><li>Retrieve token to access the FHIR Server resources:<\/li><\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>POST https:\/\/localhost:44348\/connect\/token\r\nBODY: client_id=serviceclient&amp;client_secret=serviceclient&amp;grant_type=client_credentials&amp;scope=fhir-api<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"550\" src=\"\/wp-content\/uploads\/2021\/03\/1584667768992-1024x550.png\" alt=\"\" class=\"wp-image-98\" srcset=\"\/wp-content\/uploads\/2021\/03\/1584667768992-1024x550.png 1024w, \/wp-content\/uploads\/2021\/03\/1584667768992-300x161.png 300w, \/wp-content\/uploads\/2021\/03\/1584667768992-768x412.png 768w, \/wp-content\/uploads\/2021\/03\/1584667768992.png 1071w\" sizes=\"auto, (max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Hope you got so far &amp; starting your celebration&#8230; Yes, my friend, you did it! Congratulations!!!<\/p>\n\n\n\n<p>You are ready to play with FHIR \ud83d\udd25 &#8230; Just remember, to follow the FHIR safety rules that we will cover on next post \ud83d\ude42 Stay tuned and let me know what are you thoughts in the comments. Thanks!<\/p>\n<div class=\"pvc_clear\"><\/div><p id=\"pvc_stats_22\" class=\"pvc_stats all  \" data-element-id=\"22\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p><div class=\"pvc_clear\"><\/div>","protected":false},"excerpt":{"rendered":"<p>Hello my FHIR-ly friends, and welcome to my first post on Microsoft FHIR server! Over the last few months, i worked with Microsoft Open Source FHIR Server (OSS) and wanted to share my experience on setting it up and running locally. Yes, you may run it locally without internet \ud83d\ude42 This might be helpful, if &hellip; <a href=\"https:\/\/thecloudmarathoner.com\/index.php\/2020\/03\/19\/place-holder-post-3\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Setting up Microsoft FHIR Server on your laptop &#038; FHIR-ing up&#8230;&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-22","post","type-post","status-publish","format-standard","hentry","category-hl7-fhir"],"_links":{"self":[{"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/posts\/22","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/comments?post=22"}],"version-history":[{"count":6,"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/posts\/22\/revisions"}],"predecessor-version":[{"id":99,"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/posts\/22\/revisions\/99"}],"wp:attachment":[{"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/media?parent=22"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/categories?post=22"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/thecloudmarathoner.com\/index.php\/wp-json\/wp\/v2\/tags?post=22"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}