Fetch a paginated list of records
Retrieves a paginated list of records for the specified object type. Supports filtering parameters.
Request
- Base URL: https://api.reallysimplesystems.com
- URL: https://api.reallysimplesystems.com/api/{objectNames}
- Auth: HTTP bearer
Query parameters
The number of records per page. Defaults to 20.
The page number to retrieve. Defaults to the first page.
A JSON object specifying the fields to order by and their direction (asc or desc). Each key is a field name, and the value is the sort direction. Example: {"name": "asc", "created_at": "desc"}. Field names are case-insensitive.
A JSON object specifying filters for the records. Example: ?q={“name”: “Test”} or ?q={“name”: “Test”, “sector”: “Design”}. The query allows using fields and operators for complex queries. Below are the supported operators and their usage: <table> <thead> <tr> <th>Operator</th> <th>Description</th> <th>Example</th> </tr> </thead> <tbody> <tr> <td><code>$not</code></td> <td>Negation logical operator</td> <td><code>{"field": {"$not": val}}</code></td> </tr> <tr> <td><code>$in</code></td> <td>Match any value in array</td> <td><code>{"field": {"$in": [value1, value2, ...]}}</code></td> </tr> <tr> <td><code>$nin</code></td> <td>Not match any value in array</td> <td><code>{"field": {"$nin": [value1, value2, ...]}}</code></td> </tr> <tr> <td><code>$or</code></td> <td>Logic operator</td> <td><code>{"$or": [{"field": value}, {"field": value}]}</code></td> </tr> <tr> <td><code>$gt</code></td> <td>Greater than</td> <td><code>{"field": {"$gt": 1000}}</code></td> </tr> <tr> <td><code>$gte</code></td> <td>Greater than or equal</td> <td><code>{"field": {"$gte": 1000}}</code></td> </tr> <tr> <td><code>$lt</code></td> <td>Less than</td> <td><code>{"field": {"$lt": 1000}}</code></td> </tr> <tr> <td><code>$lte</code></td> <td>Less than or equal</td> <td><code>{"field": {"$lte": 1000}}</code></td> </tr> <tr> <td><code>$bt</code></td> <td>Between value1 and value2 inclusive</td> <td><code>{"field": {"$bt": [1000, 2000]}}</code></td> </tr> <tr> <td><code>$sw</code></td> <td>Starts with</td> <td><code>{"field": {"$sw": "tes"}}</code></td> </tr> <tr> <td><code>$ew</code></td> <td>Ends with</td> <td><code>{"field": {"$ew": "tes"}}</code></td> </tr> <tr> <td><code>$con</code></td> <td>Contains</td> <td><code>{"field": {"$con": "tes"}}</code></td> </tr> </tbody> </table>
The name of child objects to include with the record data. This allows you to get child record data with the parent, instead of making a separate request to the child route
Response
Successful response containing the list of records.
Example response
{
"data": {
"metadata": {
"url": "http://api.example.com/api/accounts",
"object_type": "list",
"total_count": 100,
"has_more": true
},
"list": [
{
"metadata": {
"url": "http://api.example.com/api/account/1",
"list_url": "http://api.example.com/api/accounts",
"parent": null,
"object_type": "record",
"record_type": "account"
},
"record": {
"id": 1,
"name": "Example Account",
"created_at": "2024-11-08T00:00:00.000000Z",
"updated_at": "2024-11-08T00:00:00.000000Z"
}
}
],
"links": {
"first": "http://api.example.com/api/accounts?page=1",
"last": "http://api.example.com/api/accounts?page=5",
"prev": null,
"next": "http://api.example.com/api/accounts?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 5,
"path": "http://api.example.com/api/accounts",
"per_page": 20,
"to": 20,
"total": 100
}
}
}Changes
No recorded changes to this operation across all 1 revision of this API.