Search code examples
hl7-fhirhapidstu2-fhirhapi-fhir

Does HAPI FHIR Java API support chained parameters?


I am trying to form a request like :

http://host/api/FHIR/DSTU2/Schedule?Schedule.actor:Practitioner=1234&Schedule.actor:Practitioner.location=5678&slottype=urn:oid:1.2.3|PrimaryCare&start=2016-08-08

Using HAPI FHIR Java API, how can I parse following params :

Schedule.actor:Practitioner=1234

Schedule.actor:Practitioner.location=5678


Solution

  • This is definitely supported.

    Assuming you're creating a server, you would want a parameter on your resource provider method like:

    @IncludeParam(allow={"Schedule:actor","Schedule:practitioner"}) 
    Set<Include> theIncludes
    

    Add "*" to the list of strings to just whitelist anything