docs: add pagination and limit: 0 information in pagination for API docs (#12243)

Fixes https://github.com/payloadcms/payload/issues/12140
This commit is contained in:
Paul
2025-05-05 13:17:04 -07:00
committed by GitHub
parent 800c424777
commit 05ae957cd5

View File

@@ -55,10 +55,11 @@ All collection `find` queries are paginated automatically. Responses are returne
All Payload APIs support the pagination controls below. With them, you can create paginated lists of documents within your application: All Payload APIs support the pagination controls below. With them, you can create paginated lists of documents within your application:
| Control | Description | | Control | Default | Description |
| ------- | --------------------------------------- | | ------------ | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `limit` | Limits the number of documents returned | | `limit` | `10` | Limits the number of documents returned per page - set to `0` to show all documents, we automatically disabled pagination for you when `limit` is `0` for optimisation |
| `page` | Get a specific page number | | `pagination` | `true` | Set to `false` to disable pagination and return all documents |
| `page` | `1` | Get a specific page number |
### Disabling pagination within Local API ### Disabling pagination within Local API