Skip to main content

example:

class TestAPI(APIView):

    @staticmethod
    def get(request):
        tests = Test.objects.all() # filter or order by or anything else
        
        pagination = PaginationObject(objects=tests, page=1, numbers_in_page=10, 
                     serializer=TestSerializer)

        return Response(pagination.serializer_data(), status=status.HTTP_200_OK)

to get all objects in one page :

        pagination = PaginationObject(objects=tests, page=1, numbers_in_page=-1, 
                     serializer=TestSerializer)

Metadata

Release files for djangorestframework-pagination 1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for djangorestframework-pagination 1.2
File Size Uploaded Provenance Actions
djangorestframework_pagination-1.2.tar.gz 2.7 kB Without provenance Details for djangorestframework_pagination-1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for djangorestframework-pagination 1.2
File Interpreter ABI Platform Actions
djangorestframework_pagination-1.2-py3-none-any.whl Python 3 none any Details for djangorestframework_pagination-1.2-py3-none-any.whl

Total release size: 6.1 kB

Release files / djangorestframework_pagination-1.2.tar.gz

Download URL djangorestframework_pagination-1.2.tar.gz
Size 2.7 kB
Tags Source
SHA-256 checksum
How to use checksums
e3f1b4a2b3185a6615ce164238e6f1a2d5e54991b653e1a534d4f1609e262947
BLAKE2b-256 checksum
How to use checksums
16bb020e227dec54e612418698bfae48aee8b66fab414d616047cfb7d325362f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Release files / djangorestframework_pagination-1.2-py3-none-any.whl

Download URL djangorestframework_pagination-1.2-py3-none-any.whl
Size 3.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b286067b7972e6249301b08b370412d03531f374899fef207e46b220fbb54a93
BLAKE2b-256 checksum
How to use checksums
73808583c112c8b99437845d4c22c7378ce03cc0d159085162c57498a1e6da82
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Security for djangorestframework-pagination 1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.2 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page