django-microapi Documentation¶

A tiny library to make writing CBV-based APIs easier in Django.

Essentially, this just provides some sugar on top of the plain old django.views.generic.base.View class, all with the intent of making handling JSON APIs easier (without the need for a full framework).

Usage:

  • django-microapi Quick Start
    • Installation
    • Usage
  • Tutorial
    • Setup
    • The Existing Application
    • Your First Steps
    • Hook Up the API Endpoint
    • Adding a Detail Endpoint
    • Tangent: Serialization
    • Adding Author Information
    • Creating Data
    • Updating & Deleting Data
    • Final Code
    • Next Steps
  • Testing
    • Example Endpoint
    • Adding Tests
    • Inspecting Responses
    • Testing Data-Creating Endpoints
    • “Final” API Test Code
    • Pytest Support

API Docs:

  • microapi.views
    • ApiView
  • microapi.serializers
    • ModelSerializer
  • microapi.tests
    • ApiTestCase
    • assert_accepted()
    • assert_app_error()
    • assert_bad_request()
    • assert_created()
    • assert_forbidden()
    • assert_no_content()
    • assert_not_allowed()
    • assert_not_found()
    • assert_ok()
    • assert_status_code()
    • assert_unauthorized()
    • check_response()
    • create_request()
  • microapi.http
    • http.OK
    • http.CREATED
    • http.ACCEPTED
    • http.NO_CONTENT
    • http.BAD_REQUEST
    • http.UNAUTHORIZED
    • http.FORBIDDEN
    • http.NOT_FOUND
    • http.NOT_ALLOWED
    • http.IM_A_TEAPOT
    • http.APP_ERROR
  • microapi.exceptions
    • ApiError
    • DataValidationError
    • InvalidFieldError

Indices and tables¶

  • Index

  • Module Index

  • Search Page

django-microapi

Navigation

Usage:

  • django-microapi Quick Start
  • Tutorial
  • Testing

API Docs:

  • microapi.views
  • microapi.serializers
  • microapi.tests
  • microapi.http
  • microapi.exceptions

Related Topics

  • Documentation overview
    • Next: django-microapi Quick Start
©2023, Daniel Lindsley. | Powered by Sphinx 8.0.2 & Alabaster 1.0.0 | Page source