diff --git a/docs/content/docs/plugins/admin.mdx b/docs/content/docs/plugins/admin.mdx index ae1e863ce2..b06c64d57a 100644 --- a/docs/content/docs/plugins/admin.mdx +++ b/docs/content/docs/plugins/admin.mdx @@ -119,45 +119,50 @@ Allows an admin to list all users in the database. ```ts type listUsers = { /** - * The value to search for. + * Query parameters for filtering, searching, and pagination. */ - searchValue?: string = "some name" - /** - * The field to search in, defaults to email. Can be `email` or `name`. - */ - searchField?: "email" | "name" = "name" - /** - * The operator to use for the search. Can be `contains`, `starts_with` or `ends_with`. - */ - searchOperator?: "contains" | "starts_with" | "ends_with" = "contains" - /** - * The number of users to return. Defaults to 100. - */ - limit?: string | number = 100 - /** - * The offset to start from. - */ - offset?: string | number = 100 - /** - * The field to sort by. - */ - sortBy?: string = "name" - /** - * The direction to sort by. - */ - sortDirection?: "asc" | "desc" = "desc" - /** - * The field to filter by. - */ - filterField?: string = "email" - /** - * The value to filter by. - */ - filterValue?: string | number | boolean = "hello@example.com" - /** - * The operator to use for the filter. - */ - filterOperator?: "eq" | "ne" | "lt" | "lte" | "gt" | "gte" = "eq" + query?: { + /** + * The value to search for. + */ + searchValue?: string = "some name" + /** + * The field to search in, defaults to email. Can be `email` or `name`. + */ + searchField?: "email" | "name" = "name" + /** + * The operator to use for the search. Can be `contains`, `starts_with` or `ends_with`. + */ + searchOperator?: "contains" | "starts_with" | "ends_with" = "contains" + /** + * The number of users to return. Defaults to 100. + */ + limit?: string | number = 100 + /** + * The offset to start from. + */ + offset?: string | number = 100 + /** + * The field to sort by. + */ + sortBy?: string = "name" + /** + * The direction to sort by. + */ + sortDirection?: "asc" | "desc" = "desc" + /** + * The field to filter by. + */ + filterField?: string = "email" + /** + * The value to filter by. + */ + filterValue?: string | number | boolean = "hello@example.com" + /** + * The operator to use for the filter. + */ + filterOperator?: "eq" | "ne" | "lt" | "lte" | "gt" | "gte" = "eq" + } } ```