Skip to content

Commit

Permalink
Merge pull request #465 from onc-healthit/LANTERN-806-Adding-webscrap…
Browse files Browse the repository at this point in the history
…er-interop-url

LANTERN-806: Add webscraper for interop url
  • Loading branch information
vishnu-mettles authored Dec 16, 2024
2 parents ca043b3 + cd1bbe0 commit 91c44d6
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ var curemdURL = "https://www.curemd.com/developer/base-fhir-urls/"
var emdscloudURL = "https://identity.emdscloud.com/api/api-resource/fhir"
var betaAfoundriaURL = "https://beta.afoundria.com/api/fhir/urls"
var ehealthlineURL = "http://ehealthline.com/dev/pdf/FHIR%20API%20Endpoints.htm"
var interopURL = "https://interop.ehnote.com/fhir"
var fhirptURL = "https://fhirpt-stage.officeally.com/fhir/r4/endpoints"
var chntechURL = "https://onc.chntechsolutions.com/ic-ehr-fhir-api/"
var zoobooksystemsURL = "https://zoobooksystems.com/api-documentation/"
Expand Down Expand Up @@ -588,6 +589,8 @@ func QueryCHPLEndpointList(chplURL string, fileToWriteTo string) {
CSVParser(chplURL, fileToWriteTo, "./endpoints.csv", -1, 0, true, 1, 0)
} else if URLsEqual(chplURL, ehealthlineURL) {
EhealthlineWebscraper(ehealthlineURL, fileToWriteTo)
} else if URLsEqual(chplURL, interopURL) {
InteropWebscraper(chplURL, fileToWriteTo)
} else if URLsEqual(chplURL, fhirptURL) {
BundleQuerierParser(chplURL, fileToWriteTo)
} else if URLsEqual(chplURL, chntechURL) {
Expand Down
22 changes: 22 additions & 0 deletions endpointmanager/pkg/chplendpointquerier/interopwebscraper.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package chplendpointquerier

import (
"strings"

log "github.com/sirupsen/logrus"
)

func InteropWebscraper(CHPLURL string, fileToWriteTo string) {

var lanternEntryList []LanternEntry
var endpointEntryList EndpointList
var entry LanternEntry
entry.URL = strings.TrimSpace(CHPLURL)
lanternEntryList = append(lanternEntryList, entry)
endpointEntryList.Endpoints = lanternEntryList
err := WriteCHPLFile(endpointEntryList, fileToWriteTo)
if err != nil {
log.Fatal(err)
}

}

0 comments on commit 91c44d6

Please sign in to comment.