# Enhance Django OAuth Library for Clean JSON Responses in API Development

**URL:** <https://forum.djangoproject.com/t/enhance-django-oauth-library-for-clean-json-responses-in-api-development/24322>\
**Category:** Forms & APIs\
**Created:** [October 5, 2023, 2:09pm UTC](https://forum.djangoproject.com/t/enhance-django-oauth-library-for-clean-json-responses-in-api-development/24322 "2023-10-05T14:09:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![0xdolan](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/0xdolan/32/16274_2.png) [@0xdolan](https://forum.djangoproject.com/u/0xdolan)\
**Post date:** [October 5, 2023, 2:09pm UTC](https://forum.djangoproject.com/t/enhance-django-oauth-library-for-clean-json-responses-in-api-development/24322/1 "2023-10-05T14:09:30Z")

</div>

What is the recommended approach for using the Django OAuth library in API development to ensure that the API returns clean JSON responses instead of rendering Django HTML templates? I need JSON results for the front-end (built with Next.js) to redesign the pages, without relying on Django’s HTML templates.
