Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

SOR Enkeltopslagsservice er en støtte-service på NSP, der tillader enkelt-opslag af SOR enheder og SHAK-mapninger gennem en JSON-snitflade.
Snitfladen er designet med BRS og MinSpærring in mente, men alle services, hvis behov opfyldes af de udstillede data, er velkomne til at kalde SORES's snitflade.

De udstillede data stammer fra SOR-databasen, der opdateres dagligt af SOR-importeren. En delmængde af data caches i memory og requests kan gennemtvinge en refresh af cachen såfremt det er ønskværdigt i udviklingsøjemed, mens driften sørger for at refreshe cachen i produktion, når importeren er kørt færdigcachen refreshes i produktion af en særskilt cron-container, hvis der er opdatede data i databasen.

Snitfladebeskrivelsen indeholder - udover beskrivelse af selve snitfladen - et par eksempler på request og response.

...

Operation

Parametre

Beskrivelse
BRSGetSorEntitySorIds: Array af SOR-Id'er, der ønskes fremsøgt
[Date]: Datagrundlags-dato
Returnerer information for hver af de forespurgte SOR entiteter, der gjaldt på den angivne dato*
BRSSearchAllChildrenSorIds: Array af SOR-Id'er, hvis under-entiteter ønskes fremsøgt
[Date]: Datagrundlags-dato
Returnerer information for alle under-entiteter for hver af de forespurgte SOR entiteter, der gjaldt på den angivne dato*
BRSMapShakToSorShakId: SHAK id, der ønskes mappet
[Date]: Datagrundlags-dato
Returnerer information for de SOR-entiteter, der på den angivne dato* havde det forespurgte SHAK id.

* eller dags dato, hvis ingen dato er angivet

Eksempler

Herunder illustrerer et par eksempler requests og responses for de tre operationer.

BRSGetSorEntity

GetSorEntityByProviderProviderIds: Array af ydernumre
[Date]: Datagrundlags-dato
Returnerer information for (en liste af) alle SOR entiteter, der var tildelt det angivne ydernummer på den angivne dato*
IsSorEntityDescendantOfSorEntitySorIdAndParentSorIdPairs: Todimensionelt array af SOR-Id-par 
[Date]: Datagrundlags-dato
Returnerer et array af booleans - for hvert par af id'er [id, mulig forælder] - om den pågældende enhed hørte under den mulige forælder i hierarkiet på den angivne dato*

* eller dags dato, hvis ingen dato er angivet

Eksempler

Herunder illustrerer et par eksempler requests og responses for de tre operationer.

BRSGetSorEntity

Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"BRSGetSorEntity\", \"sorIds\": [ \"8041000016000\", \"6101000016001\", \"91331000016003\" ] }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 Apr 2020 07:52:27 GMT


{
    "8041000016000":{
        "sorId":8041000016000,
        "from":"2016-10-18",
        "name":"Sydvestjysk Sygehus",
        "healthInstitutionSorId":8041000016000,
        "shakId":"5501",
        "parentSorId":6101000016001
    },
    "6101000016001":{
        "sorId":6101000016001,
        "from":"2015-07-30",
        "name":"Region Syddanmark"
    },
    "91331000016003":{
        "sorId":91331000016003,
        "from":"2019-04-19",
        "name":"Jørn Bøgh ApS",
        "healthInstitutionSorId":91321000016000,
        "providerId":"097926",
        "shakId":"7034010",
        "parentSorId":91321000016000
    }
}


GetSorEntityByProviderId

Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"GetSorEntityByProvider\", \"providerIds\": [ \"303712\" ] }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 May 2020 10:52:22 GMT


{
    "303712":[
        {
            "sorId":709251000016004,
            "from":"2018-08-18",
            "name":"Fodterapeut Mette Nielsen",
            "healthInstitutionSorId":399351000016009,
            "providerId":"303712",
            "parentSorId":399351000016009
        },
        {
            "sorId":842311000016008,
            "from":"2018-08-18",
            "name":"Hanne Møller-San Pedro",
            "healthInstitutionSorId":842301000016006,
            "providerId":"303712",
            "parentSorId":842301000016006
        },
        {
    
Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"BRSGetSorEntity\", \"sorIds\": [ \"8041000016000\", \"6101000016001\", \"91331000016003\" ] }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 Apr 2020 07:52:27 GMT


{
    "8041000016000":{
        "sorId":8041000016000701371000016004,
            "from":"20162018-1008-18",
            "name":"SydvestjyskAnnette Steen SygehusNielsen",

            "healthInstitutionSorId":8041000016000701361000016009,
            "shakIdproviderId":"5501303712",
        "parentSorId":6101000016001
    },
    "6101000016001"parentSorId":{701361000016009
        "sorId":6101000016001,}
        "from":"2015-07-30",
        "name":"Region Syddanmark"
    },
    "91331000016003":{
        "sorId":91331000016003,
        "from":"2019-04-19",
        "name":"Jørn Bøgh ApS",]
}

BRSSearchAllChildren

Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"BRSSearchAllChildren\", \"sorIds\": [ \"246061000016002\" ] }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 Apr 2020 07:54:55 GMT


{
    "246061000016002":[
        "healthInstitutionSorId":91321000016000,{
        "providerId":"097926",
        "shakIdsorId":"7034010"246071000016007,
        "parentSorId":91321000016000
    }
}

BRSSearchAllChildren

Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"BRSSearchAllChildren\", \"sorIds\": [ \"246061000016002\" ] }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 Apr 2020 07:54:55 GMT


{
    "246061000016002":["from":"2019-04-16",
            "name":"SVS Tand- Mund- og Kæbekirurgisk ambulatorium (Esbjerg)",
            "healthInstitutionSorId":8041000016000,
            "shakId":"550108T",
            "parentSorId":246061000016002
        },
        {
            "sorId":246071000016007452041000016004,
            "from":"2019-0408-1617",
            "name":"SVS Tandtand-, Mundmund- og Kæbekirurgiskkæbekirurgisk ambulatoriumamb. (Esbjerg)",
            "healthInstitutionSorId":8041000016000,
            "shakId":"550108T",
            "parentSorId":246061000016002246071000016007
        },
        {
            "sorId":452041000016004246081000016009,
            "from":"2019-0804-1716",
            "name":"SVS tandTand-, mundMund- og kæbekirurgiskKæbekirurgisk amb.afsnit (Esbjerg)",
            "healthInstitutionSorId":8041000016000,
            "parentSorIdshakId":246071000016007"5501081",
        },
    "parentSorId":246061000016002
    {
    }
        "sorId":246081000016009,
            "from":"2019-04-16",
            "name":"SVS Tand- Mund- og Kæbekirurgisk afsnit (Esbjerg)",
            "healthInstitutionSorId":8041000016000,
            "shakId":"5501081",
            "parentSorId":246061000016002
        }
    ]]
}

IsSorEntityDescendantOfSorEntity

Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"IsSorEntityDescendantOfSorEntity\", \"sorIdAndParentSorIdPairs\": [ [\"246061000016002\", \"246081000016009\"], [\"246081000016009\", \"246061000016002\"] ] }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 May 2020 10:53:37 GMT


{
    "child=246061000016002, possibleAncestor=246081000016009":false,
    "child=246081000016009, possibleAncestor=246061000016002":true
}

BRSMapShakToSor

Expand
titlecurl -i -X POST -H "Content-Type: application/json" -d "{\"op\": \"BRSMapShakToSor\", \"shakId\": \"5501\" }" http://test1.ekstern-test.nspop.dk:8080/sores/
No Format
HTTP/1.1 200 OK
Connection: keep-alive
X-Powered-By: Undertow/1
Server: WildFly/8
Transfer-Encoding: chunked
Content-Type: application/json;charset=utf-8
Date: Wed, 22 Apr 2020 07:56:18 GMT


{
    "5501":[
        {
            "sorId":245601000016003,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245531000016006,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245271000016006,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245011000016008,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246271000016001,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244461000016003,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245931000016001,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245141000016005,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":618861000016004,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246331000016007,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245731000016004,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246221000016000,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":320651000016001,
            "from":"2019-04-16",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246291000016002,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244851000016004,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244811000016003,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245451000016000,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244721000016002,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244591000016008,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246531000016001,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244681000016007,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245221000016007,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245581000016005,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246571000016004,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245851000016003,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245891000016009,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246251000016008,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245401000016001,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245771000016002,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":8041000016000,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245641000016000,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":618901000016009,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":618911000016006,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246311000016001,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":244441000016004,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245501000016002,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246361000016004,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246091000016006,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":318611000016008,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246321000016005,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246191000016005,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246061000016002,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246231000016003,
            "from":"2019-04-16",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":390631000016000,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":245511000016000,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        },
        {
            "sorId":246551000016006,
            "from":"2019-12-21",
            "healthInstitutionSorId":8041000016000
        }
    ]
}

...