Summary
API Filters Summary
This summary provides a brief overview of the various filters available in our API. These filters allow you to query, sort, paginate, and include related data efficiently.
Where Filter
The where
filter allows for complex queries with conditions similar to MongoDB. It supports a variety of operators like $eq
, $gt
, $regex
, and more, allowing for detailed data retrieval based on specific criteria.
Detailed Where Filter Documentation
Sort Filter
The sort
filter enables sorting the results of your query by one or more fields, either in ascending (1
) or descending (-1
) order. This is useful for organizing data returned from the API in a meaningful order.
Detailed Sort Filter Documentation
Limit Filter
The limit
filter restricts the number of records returned in a query, which is particularly useful in managing large datasets and improving query performance by reducing the amount of data transmitted.
Detailed Limit Filter Documentation
Skip Filter
The skip
filter is used to paginate through results by skipping a specified number of records before returning the remaining data. This complements the limit
filter in providing full pagination capabilities.
Detailed Skip Filter Documentation
Include Filter
The include
filter allows for the inclusion of related models in your query results. It can be specified with a relation
and an optional scope
that applies additional filters to the included model, such as where
, sort
, and limit
.
Detailed Include Filter Documentation
Conclusion
By utilizing these filters, developers can efficiently query and manipulate large sets of data, customize the output, and optimize the performance of their applications. These filters provide powerful tools for precise and efficient data retrieval, ensuring that applications perform optimally with minimal load times.