Querying For a List of Objects
URL
GET to the following URL:
http://rest.wasabisync.com/client_apps/<appId>/users/<userId>/known_objects.json&where=<queryobject>&schema=<schema_version>&objtype=<objtype>&sort=<sort_order>
Parameters
- appId - (Required) The application id which will receive your data. This should be of the form: com.yourcompany.yourapplication.
- userId - (Required) The id of the user who will own the object you are posting. Typically, this will be an email address.
- where - (Optional) A Wasabi Sync JSON Query Object encoded using URL encoding. If not specified, returns all objects of the given type. If objtype is not specified, returns all objects owned by the user.
- schema - (Optional)The schema version expected. (Default: The user's most recently synchronized schema version.)
- objtype - (Optional) The type of object to query for. (Required if specifying where or sort_order.)
- sort_order - (Optional) Specifies a field name to sort the results by. See also: Query Sorting
Result
Discussion
This method allows you to query for a list of objects. The list of objects may be homogenous, or, if the objtype parameter is not specified may contain different types of objects.
The where
parameter is a JSON object conforming to the Wasabi Sync JSON Query Object definition and should be encoded using URL encoding to remove spaces and other characters reserved for use in URLs.
Specifying none of the optional parameters results in listing all of the known objects owned by the given user.