Proposed features for future API releases.
Add support for open_date and closed_date?
Meta Summary Data (optional)
Results return a meta block of summary resultset data to make client application development easier. This is an optional feature to the core API.
:: `
- meta: {
limit: 2, next: null, offset: 0, previous: null, total_count: 29},
/api/features.json?limit=25&offset=50
/facilities.json?sortAsc=beds&sortDesc=nurses
Sorts the results by property.
Note
/facilities.json?property1=value&property2=value
Properties apply to all core and user defined facility properties
/facilities/count.json
Returns the count of all facilities
/facilities/count.json?beds=10
Returns counts of facilities where the number of beds are equal to 10, with beds=10 representing the querystring.
/facilities.json?q=search_value
Text search
Note
Support for this will vary by implementation.
Implementing service should specify clearly in their documentation what fields support text search.
The text search:
A site with a coded value “CHP”->”Community Health Post” would be a hit on a query on the word “post” A site with a coded value of “0203”->”Mygenge” would be a hit on queries “203” and “genge”
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | <?xml version="1.0" encoding="UTF-8"?>
<facility xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http:www.openfacility.org/v1.0 facility.xsd"
xmlns="http:www.openfacility.org/v1.0"
xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#">
<facilities>
<facility>
<!-- core required properties -->
<url>http://facilityregistry.org/api/facilities/0X9OCW3JMV98EYOVN32SGN4II</url>
<id>0X9OCW3JMV98EYOVN32SGN4II</id> <!-- internal guid -->
<moh_id identifier=”yes” agency=”moh” context =”dhis”>1234</moh_id> <!-- ministry of health DHIS-->
<unicef_id identifier=”yes” agency=”unicef” context =”mtrac”>9534</unicef_id> <!-- UNICEF mTrac ID-->
<name>Ruhiira HC</name>
<active>yes</active>
<created_at>2011-11-16T14:26:15Z</created_at>
<updated_at>2011-11-16T14:26:15Z</updated_at>
<active>yes</active>
<date_closed>2011-12-20 15:09:47</date_closed>
<geo:lat>-1.69172</geo:long>
<geo:long>29.52505</geo:long>
<!-- optional properties -->
<rm:properties xlmns:rm="http://resourcemap.instedd.org/api/1.0>
<rm:number_beds>10</rm:number_beds>
<rm:medical_officer>Dr. Mukombo</rm:medical_officer>
...
</properties>
</facility>
...
</facilities>
|