Notifications
Clear all

Fetching Slot resources doesn't ever return any data!


(@derek)
Active Member
Blev medlem: 1 månad sedan
Inlägg: 6
Topic starter  

I have been unable so far to retrieve any time slot resources using the FHIR API. There is an example query in the Cambio docs at Simplifier - Search Slot Example which based on the self-reference entry looks like this:-

 http://172.20.177.186/fhir/Slot?_count=500&_include=Slot%3Aschedule.practitioner&_profile=https%3A%2F%2Ffhir.cambio.se%2Ffhir%2FStructureDefinition%2FSlotLiteSe%2Fv1&healthcareFacility=SE162321000024-ABCD&healthcareService=746&start=gt2022-02-11T00%3A00%3A00.615%2001%3A00&start=lt2022-02-12T23%3A59%3A59.615%2001%3A00 

I try to enter a similar query (updating it to use the recommended base URL instead of IPs) with the same parameters as above (note that I'm using Postman so these ought to be properly URL encoded) to produce an updated query like so:-

 https://api.openservices.cambio.se/fhir/Slot?_count=500&_include=Slot:schedule.practitioner&_profile=https://fhir.cambio.se/fhir/StructureDefinition/SlotLiteSe/v1&healthcareFacility=SE162321000024-ABCD&healthcareService=746&start=gt2022-02-11T00:00:00.615  01:00&start=lt2022-02-12T23:59:59.615 01:00

However, when executed using GET, it doesn't return any slots but returns an empty result like this:-

{
    "resourceType": "Bundle",
    "id": "29aa18e6-6715-4457-a1aa-770cb4c8e7a5",
    "meta": {
        "lastUpdated": "2023-11-09T22:17:02.975+01:00"
    },
    "type": "searchset",
    "total": 0,
    "link": [
        {
            "relation": "self",
            "url": "https://13.74.30.234:8080/fhir/Slot?_count=500&_include=Slot%3Aschedule.practitioner&_profile=https%3A%2F%2Ffhir.cambio.se%2Ffhir%2FStructureDefinition%2FSlotLiteSe%2Fv1&_sid=simon.fridlund%40zymego.com&healthcareFacility=SE162321000024-ABCD&healthcareService=746&start=gt2022-02-11T00%3A00%3A00.615%2001%3A00&start=lt2022-02-12T23%3A59%3A59.615%2001%3A00"
        }
    ]
}

As the parameters are the same as the example, I'm surprised that it doesn't return the same results. The only thing that differs between the two queries is perhaps the `Patient` entry embedded in the header. Unfortunately the Cambio example doesn't disclose header information so I'm not sure what Patient data value was used for the example.

In my particular query, I'm using the following name,value pairs in the header:-

Ocp-Apim-Subscription-key, <My API Key Here!>
patient, 195609111553

Possibly, I'm not using the correct patient id, or the wrong format so there are no valid results?

It is difficult to determine from the limited test data, docs and examples what the correct combination of parameters ought to be to return any time-slots. It would be great if someone could supply full details of what a working example would look like with the current sandbox.

Thanks!


   
Citera
Topic Tags
(@cambioinnovation)
Medlem Admininistratör
Blev medlem: 2 år sedan
Inlägg: 7

   
SvaraCitera