Commons:Wiki Loves Monuments 2011/May Meeting/Notes/Tech

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search
Wiki Loves Monuments meetup
Friday 13th, 14th and 15th May 2011, Betahaus, Berlin

Notes from Tech-discussion[edit]

(steal form )

All calls are normal GET requests, e.g <>.

Properties must be URL encoded using UTF-8.

Ideas on parameters
  • Common parameters (applicable to all orders)
    • props = [country|lang|id|name|address|municipality|lat|lon|image|source|changed]: the properties which should be returned. (By default all of them.
    • format= [kml|gpx|poi|html|layar|json|xml]
    • action=[search|statistics|help] (default=help)
    • callback = [callbackname] (used for JSONP for Javascript mashups). Implies format=JSON.
    • limit = [integer] (the maximum number of results you will get back, 100 by default. Max 500.
    • bbox = left,bottom,right,top. Bounding box with topleft and bottomright latlong coordinates. E.g. bbox=11.54,48.14,11.543,48.145. This is the same way OSM works (see
  • Specific orders action =
    • search: searches monuments containing the specified text OR "*" to show all monuments within the following parameters:
    • srcountry = countrycode (by default all is returned, this should be a valid two-character ISO 639-1 code)
    • srquery = Freeform search on all fields. (e.g. 'srquery=Brandenburger%20Tor')
    • sr<prop> = Freeform search on a property
      • srmunicipality = municipality (freeform search)
      • sraddress = address (freeform search)
    • srwith<prop>=
    • srwithout<prop>=
    • srwithimage=[true|false]
      • srcoordinates = [true|false] (no parameter = any) ?? <-- What does this mean?
      • srimage = [true|false] (no parameter = any) ??
    • srcontinue = (whatever the previous call gave you)
    • statistics: gives statistical data, of a given country
      • stcountry = countrycode (by default all is returned, this should be a valid twocharacter ISO 639-1 code)
      • stvar = [withimage|withcoordinates|noimage|nocoordinates|total|add more]
      • stformat = [percent|number|both]

Please note: Just ideas. Feel free to improve, delete or whatever you want. Search operators:
foo Exactly 'foo'
foo%Begins with foo
%fooEnds with foo
%foo% Contains foo anywhere

  • Do some sort of query
  • For each row create an object
  • Render the object in the output format