Skip to content

Commit

Permalink
Added description for searches
Browse files Browse the repository at this point in the history
  • Loading branch information
portableant committed Jun 4, 2010
1 parent 48e2657 commit 955d5b9
Show file tree
Hide file tree
Showing 22 changed files with 32 additions and 35 deletions.
2 changes: 1 addition & 1 deletion brooklyn/brooklyn.Collection.getRightsTypes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Search Brooklyn Museum's collections database</description>
<documentationURL>http://www.brooklynmuseum.org/opencollection/api/docs/request/collection.getRightsTypes</documentationURL>
<sampleQuery>select * from {table} where format='xml' and version='1' and api_key='{key}';</sampleQuery>
<sampleQuery description="Get rights types for Brooklyn objects">select * from {table} where format='xml' and version='1' and api_key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="response.rightstypes" produces="XML">
Expand Down
4 changes: 2 additions & 2 deletions brooklyn/brooklyn.collection.getImages.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Search Brooklyn Museum's collections database for images</description>
<documentationURL>http://www.brooklynmuseum.org/opencollection/api/docs/request/collection.getImages</documentationURL>
<sampleQuery>select * from {table} where itemtype="object" and item_id="4174" and version="1" and api_key='{key}';</sampleQuery>
<sampleQuery description="Retrieve an object by type and id number">select * from {table} where itemtype="object" and item_id="4174" and api_key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="response.images" produces="XML">
Expand All @@ -14,7 +14,7 @@
<paging model="offset">
<start id="start_index" default="0"/>
<pagesize id="results_limit" max="20"/>
<total default="100"/>
<total default="20"/>
</paging>
<inputs>
<key id="item_type" type="xs:string" paramType="query" required="true" />
Expand Down
2 changes: 1 addition & 1 deletion brooklyn/brooklyn.collection.getItem.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Search Brooklyn Museum's collections database by item type and number</description>
<documentationURL>http://www.brooklynmuseum.org/opencollection/api/docs/request/collection.getItem</documentationURL>
<sampleQuery>select * from {table} where itemtype="object" and item_id="1687" and version="1" and api_key='{key}';</sampleQuery>
<sampleQuery description="Get item details by type and id">select * from {table} where itemtype="object" and item_id="1687" and version="1" and api_key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="response.object" produces="XML">
Expand Down
7 changes: 6 additions & 1 deletion brooklyn/brooklyn.collection.search.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,18 @@
<author>Daniel Pett</author>
<description>Search Brooklyn Museum's collections database</description>
<documentationURL>http://www.brooklynmuseum.org/opencollection/api/docs/request/collection.search</documentationURL>
<sampleQuery>select * from {table} where keyword="Egypt" and version="1" and api_key='{key}';</sampleQuery>
<sampleQuery description="Get items from Brooklyn collection for Egypt">select * from {table} where keyword="Egypt"and api_key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="response.resultset.items" produces="XML">
<urls>
<url>http://www.brooklynmuseum.org/opencollection/api/?method=collection.search</url>
</urls>
<paging model="offset">
<start id="start_index" default="0" />
<pagesize id="results_limit" max="20" />
<total default="20" />
</paging>
<inputs>
<key id="item_type" type="xs:string" paramType="query" required="false"/>
<key id="keyword" type="xs:string" paramType="query" />
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getCommittee.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of members of a Parliamentary Committee</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getCommittee</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and name="health committee" and key='{key}';</sampleQuery>
<sampleQuery description="Find all members of the Health Committee on 7th May 2010">select * from {table} where date='2010-05-07' and name="health committee" and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.members" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getConstituencies.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of Parliamentary Constituencies</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getConstituencies</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and distance='20' and latitude="51.8400534244" and longitude="-1.50292754722" and key='{key}';</sampleQuery>
<sampleQuery description="Find constituencies within distance x on date from a spatial point">select * from {table} where date='2010-05-07' and distance='20' and latitude="51.8400534244" and longitude="-1.50292754722" and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getConstituency.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get constituency details</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getConstituency</documentationURL>
<sampleQuery>select * from {table} where name='battersea' and postcode='Sw11 3ds' and key='CzhqDaDMAgkMEcjdvuGZeRtR';</sampleQuery>
<sampleQuery description="Find a constituency by name">select * from {table} where name='battersea' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="" produces="XML">
Expand Down
6 changes: 2 additions & 4 deletions twfy/twfy.getDebates.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of Parliamentary debates</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getDebates</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and type="westminsterhall" and key='{key}';</sampleQuery>
<sampleQuery description="Find all debates in Westminster Hall on a date">select * from {table} where date='2010-05-07' and type="westminsterhall" and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand All @@ -13,7 +13,7 @@
</urls>
<paging model="page">
<start id="page" default="1" />
<pagesize id="per_page" max="20" />
<pagesize id="num" max="20" />
<total default="20" />
</paging>
<inputs>
Expand All @@ -22,8 +22,6 @@
<key id="search" type="xs:string" paramType="query" required="false" />
<key id="person" type="xs:string" paramType="query" required="false" />
<key id="gid" type="xs:string" paramType="query" required="false" />
<key id="page" type="xs:string" paramType="query" required="false"/>
<key id="num" type="xs:string" paramType="query" required="false" />
<key id="order" type="xs:string" paramType="query" required="false" />
<key id="key" type="xs:string" paramType="query" required="true" private="true"/>
<key id="output" type="xs:string" paramType="query" const="true" default="xml"/>
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getGeometry.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get geometry from theyworkforyou website (very loose for NI)</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getGeometry</documentationURL>
<sampleQuery>select * from {table} where person="10777" and key='{key}';</sampleQuery>
<sampleQuery description="Find spatial coordinates by name of constituency" >select * from {table} where name="battersea" and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy" produces="XML">
Expand Down
6 changes: 2 additions & 4 deletions twfy/twfy.getHansard.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Query Hansard for a wide variety of information</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getHansard</documentationURL>
<sampleQuery>select * from {table} where search="Portable Antiquities Scheme" and person='10291' and key="{key}";</sampleQuery>
<sampleQuery description="Search for a specific term and uttered by person">select * from {table} where search="Portable Antiquities Scheme" and person='10291' and key="{key}";</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.rows.match" produces="XML">
Expand All @@ -13,15 +13,13 @@
</urls>
<paging model="page">
<start id="page" default="1" />
<pagesize id="per_page" max="20" />
<pagesize id="num" max="20" />
<total default="20" />
</paging>
<inputs>
<key id="search" type="xs:string" paramType="query" required="false" />
<key id="person" type="xs:string" paramType="query" required="false" />
<key id="order" type="xs:string" paramType="query" required="false" />
<key id="page" type="xs:string" paramType="query" required="false" />
<key id="num" type="xs:string" paramType="query" required="false" />
<key id="key" type="xs:string" paramType="query" required="true" private="true" />
<key id="output" type="xs:string" paramType="query" const="true" default="xml" />
</inputs>
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getLord.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get MP details</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getLord</documentationURL>
<sampleQuery>select * from {table} where id='13375' and key={key}</sampleQuery>
<sampleQuery description="Get a Lord's details by id number">select * from {table} where id='13375' and key={key}</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getLords.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of members of the House of Lords</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getLords</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and party='Conservative' and key='{key}'</sampleQuery>
<sampleQuery description="Get a list of Lords by party on a certain date">select * from {table} where date='2010-05-07' and party='Conservative' and key='{key}'</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMLA.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get MLA details for their terms of office</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMLA</documentationURL>
<sampleQuery>select * from {table} where id='13755' and constituency='Newry and Armagh' and key='{key}';</sampleQuery>
<sampleQuery description="Get an MLA member detail by number and constituency">select * from {table} where id='13755' and constituency='Newry and Armagh' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMLAs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of MLAs</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMLAs</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and party='Conservative' and key='{key}';</sampleQuery>
<sampleQuery description="Get aall conservative MLAs on a certain date">select * from {table} where date='2010-05-07' and party='Conservative' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMP.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get MP details</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMP</documentationURL>
<sampleQuery>select * from {table} where id='10900' and constituency='Aberavon' and extra='true' and key='{key}';</sampleQuery>
<sampleQuery description="Get an MP by ID and constituency">select * from {table} where id='10900' and constituency='Aberavon' and extra='true' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMPInfo.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get MP further information (very comprehensive)</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMPInfo</documentationURL>
<sampleQuery>select * from {table} where id='11905' and fields='bbc_profile_url,comments_on_speeches' and key='{key}';</sampleQuery>
<sampleQuery description="Get extended information for an MP by id and return only selected fields">select * from {table} where id='11905' and fields='bbc_profile_url,comments_on_speeches' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMPs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a lis of MPs</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMPs</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and party='conservative' and key='{key}';</sampleQuery>
<sampleQuery description="Get all Conservative MPs on a date">select * from {table} where date='2010-05-07' and party='conservative' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMSP.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get MSP details</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMSP</documentationURL>
<sampleQuery>select * from {table} where id='10900' and constituency='Aberavon' and extra='true' and key='{key}';</sampleQuery>
<sampleQuery description="Get MSP details by id number">select * from {table} where id='10900'and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getMSPs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of Members of Scottish Parliament</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getMSPs</documentationURL>
<sampleQuery>select * from {table} where date='2010-05-07' and party='Conservative' and key='{key}';</sampleQuery>
<sampleQuery description="Get a list of MSPs by party on a date">select * from {table} where date='2010-05-07' and party='Conservative' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
2 changes: 1 addition & 1 deletion twfy/twfy.getPerson.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get MP details for a single person</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getPerson</documentationURL>
<sampleQuery>select * from {table} where id='10900' and key='{key}';</sampleQuery>
<sampleQuery description="Get a person's details using their individual id number">select * from {table} where id='10900' and key='{key}';</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand Down
6 changes: 2 additions & 4 deletions twfy/twfy.getWMS.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of written ministerial statements</description>
<documentationURL>http://www.theyworkforyou.com/api/getWMS</documentationURL>
<sampleQuery>select * from {table} where date="2006-01-09"and key="{key}";</sampleQuery>
<sampleQuery description="Get all Written ministerial statements on a date">select * from {table} where date="2006-01-09"and key="{key}";</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand All @@ -13,7 +13,7 @@
</urls>
<paging model="page">
<start id="page" default="1" />
<pagesize id="per_page" max="20" />
<pagesize id="num" max="20" />
<total default="20" />
</paging>
<inputs>
Expand All @@ -22,8 +22,6 @@
<key id="person" type="xs:string" paramType="query" required="false" />
<key id="gid" type="xs:string" paramType="query" required="false" />
<key id="order" type="xs:string" paramType="query" required="false" />
<key id="page" type="xs:string" paramType="query" required="false"/>
<key id="num" type="xs:string" paramType="query" required="false" />
<key id="gid" type="xs:string" paramType="query" required="false" />
<key id="key" type="xs:string" paramType="query" required="true" private="true"/>
<key id="output" type="xs:string" paramType="query" const="true" default="xml"/>
Expand Down
6 changes: 2 additions & 4 deletions twfy/twfy.getWrans.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<author>Daniel Pett</author>
<description>Get a list of written answers by parliamentarians</description>
<documentationURL>http://www.theyworkforyou.com/api/docs/getWrans</documentationURL>
<sampleQuery>select * from {table} where date="2006-01-09"and key="{key}";</sampleQuery>
<sampleQuery description="Get all written answers on a date">select * from {table} where date="2006-01-09"and key="{key}";</sampleQuery>
</meta>
<bindings>
<select itemPath="twfy.match" produces="XML">
Expand All @@ -13,7 +13,7 @@
</urls>
<paging model="page">
<start id="page" default="1" />
<pagesize id="per_page" max="20" />
<pagesize id="num" max="20" />
<total default="20" />
</paging>
<inputs>
Expand All @@ -22,8 +22,6 @@
<key id="person" type="xs:string" paramType="query" required="false" />
<key id="gid" type="xs:string" paramType="query" required="false" />
<key id="order" type="xs:string" paramType="query" required="false" />
<key id="page" type="xs:string" paramType="query" required="false"/>
<key id="num" type="xs:string" paramType="query" required="false" />
<key id="gid" type="xs:string" paramType="query" required="false" />
<key id="key" type="xs:string" paramType="query" required="true" private="true"/>
<key id="output" type="xs:string" paramType="query" const="true" default="xml"/>
Expand Down

0 comments on commit 955d5b9

Please sign in to comment.