diff options
author | 2021-04-24 16:44:06 +0200 | |
---|---|---|
committer | 2021-04-24 16:44:06 +0200 | |
commit | b32f5b86d51eb2af4d959bc78450ec049e8b563f (patch) | |
tree | 71f57ac8159c0837bf7ac9c93817fbb513d18847 /pydis_site/apps/api/pagination.py | |
parent | Update doc in pydis_site/apps/api/pagination.py (diff) |
Pagination: Use REPL style examples
Diffstat (limited to 'pydis_site/apps/api/pagination.py')
-rw-r--r-- | pydis_site/apps/api/pagination.py | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/pydis_site/apps/api/pagination.py b/pydis_site/apps/api/pagination.py index faf33687..2a325460 100644 --- a/pydis_site/apps/api/pagination.py +++ b/pydis_site/apps/api/pagination.py @@ -11,35 +11,35 @@ class LimitOffsetPaginationExtended(LimitOffsetPagination): For example: ## Default response - { - "count": 1, - "next": null, - "previous": null, - "results": [{ - "id": 6, - "inserted_at": "2021-01-26T21:13:35.477879Z", - "expires_at": null, - "active": false, - "user": 1, - "actor": 2, - "type": "warning", - "reason": null, - "hidden": false - }] - } + >>> { + ... "count": 1, + ... "next": None, + ... "previous": None, + ... "results": [{ + ... "id": 6, + ... "inserted_at": "2021-01-26T21:13:35.477879Z", + ... "expires_at": None, + ... "active": False, + ... "user": 1, + ... "actor": 2, + ... "type": "warning", + ... "reason": null, + ... "hidden": false + ... }] + ... } ## Required response - [{ - "id": 6, - "inserted_at": "2021-01-26T21:13:35.477879Z", - "expires_at": null, - "active": false, - "user": 1, - "actor": 2, - "type": "warning", - "reason": null, - "hidden": false - }] + >>> [{ + ... "id": 6, + ... "inserted_at": "2021-01-26T21:13:35.477879Z", + ... "expires_at": None, + ... "active": False, + ... "user": 1, + ... "actor": 2, + ... "type": "warning", + ... "reason": None, + ... "hidden": False + ... }] """ default_limit = 100 |