I’ve made a JSON-based interface to the new SL search, which provides access to all data available (I think).
All the methods have the base URL http://services.katharineberry.co.uk/search/.
Firstly, the search itself. This provides acccess to either MG or TG search, and provides information about all results on the page. It also supports specifying a page.
The format is as follows:
http://services.katharineberry.co.uk/search/search/(teen|main|mature)/search+string[/page-number]
The /page-number must be an integer, and is optional. If you use “teen” you get TG results, “main” gives MG results, and “mature” gives MG results with mature enabled. The output, assuming you know what JSON is, is fairly self-explanatory.
Additionally, you can access a bunch of other data:
- http://services.katharineberry.co.uk/search/classified/required-uuid
- http://services.katharineberry.co.uk/search/place/required-uuid
- http://services.katharineberry.co.uk/search/resident/required-uuid
- http://services.katharineberry.co.uk/search/region/required-uuid
- http://services.katharineberry.co.uk/search/event/eventid
- http://services.katharineberry.co.uk/search/group/required-uuid
Excluding events, all of the above expect a UUID in place of “required-uuid”. They can take both hyphenated and unhyphenated UUIDs. Events expect an Event ID, which are currently seven digit integers.
It can also pick out up to the top 100 popular places (I could do more - up to 50,000 - but capped it at 100 to save my server from certain death). The format for this is as follows:
http://services.katharineberry.co.uk/search/popular/(main|teen)/count
Using “main” gets MG data, “teen” gets TG data. “count” specifies the number of results to be returned.
Finally, as a bonus feature, if you have a key and have no idea what it’s for, put it in like this:
http://services.katharineberry.co.uk/search/unknown-uuid
This will make it search through the classifieds, parcels, residents, regions, events, groups, and textures. If it’s any of the above (except textures) it’ll return the same output as the standard services, with the added property “uuidtype” being set to one of the above. If it was a texture you only get the uuidtype. Please note that this takes several seconds to run, and is a relatively heavy job for my server.
I hope someone finds some use for this. Personally, I plan to use it in AjaxLife.