Questions tagged [django-rest-framework]
Django REST framework is a powerful and flexible toolkit for building RESTful Web APIs. Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design. Built by experienced developers, it takes care of much of the hassle of Web development, so you can focus on writing your app without needing to reinvent the wheel. It’s free and open source.
django-rest-framework
31,906
questions
0
votes
0
answers
7
views
PDF not generated from Django template
I am working on a form where I need to pass the user inputs into a context which is then passed to Django template which should be converted to a PDF file. However, instead of getting a PDF attachemnt ...
0
votes
0
answers
13
views
SSL handshake issue
I have a code that sends api request to an api endpoint, and prints data. It works well in my local machine. But when I deploy it to my ec2, it stucks after sending request to api endpoint. My ec2 is ...
0
votes
0
answers
13
views
Django is saving UUID without dashes in MySQL
I'm creating a Django application that uses UUID in some models. While i was using a MySQL database locally django was creating the UUID and saving it without dashes. Everything was working. Now i'm ...
0
votes
0
answers
15
views
How to Create a Token Using Django REST Framework?
I am trying to implement token-based authentication in my Django project using Django REST Framework, but I am unsure of the steps required to create and manage tokens.
I Installed Django REST ...
0
votes
0
answers
26
views
"detail": "Authentication credentials were not provided." Django REST framework that uses adfs authentication backend
I am working on a django project which uses django_auth_adfs (Azure Active Directory) as its authentication backend. I have set up its API service using rest_framework. In the browsable views of the ...
-1
votes
0
answers
37
views
How can I log variables based on database configuration?
Backend: Python 3.11 and Django 5.0.6
Database: PostgreSQL 15.6
We are shifting to deploying a Python x Django .exe file for the backend. Consequently, we will be unable to modify the code directly on ...
0
votes
1
answer
17
views
How to run on_success in Celery ONLY on the last worker process in a group?
I have been scratching my head about this for days now. I have a a background running task, which takes around 1 hour. I am processing 5000 images. I create a group of celery tasks and each task ...
0
votes
0
answers
19
views
How does DRF de-serializes the json?
I am using react as frontend and django as backend.
I have used fetch API to send send POST request to the server. The data is passed through JSON.stringify().
This request will be intercepted by ...
0
votes
0
answers
13
views
I get a ProgrammingError when connecting Django and postgresql
What we want to accomplish.
I want to get the data of Category table from postgresql using Django's rest framework.
Problems/Unknown Issues
When I try to access the db using api, I get a ...
-1
votes
1
answer
29
views
"detail": "Not Found" Error With Python Django REST API
Im having an issue with a Python Django REST API i've built that manages the file upload and retreival from and to a Google Cloud SQL DB. I am not exactly sure whats causing the error but whene i run ...
-1
votes
0
answers
28
views
Django Rest Framework RetrieveUpdateAPIView not working
I'm having an issue with using RetrieveUpdateAPIView and RetrieveDestroyAPIView. I'm trying to Update or Delete a Newsletter object while logged in as an administrator. Unfortunately, after clicking '...
1
vote
1
answer
78
views
How to get authorized in Microsoft AD using curl?
I have a django project which uses Azure Active directory for the authentication and I have set up its API using rest_framework. At the moment, I am trying to access this API using curl. I am able to ...
0
votes
2
answers
44
views
Where to write validation in django? [closed]
What is the best practice to write the validation in django project?
Is writing validation in serializer or in models better?
I have tried both for writing validation but still I am unable to choose ...
-2
votes
0
answers
23
views
How do fetch the real time latitude and longitude in Django and display that as a tracking map in the template? [closed]
I want to fetch the real time latitude and longitude from the Kotlin.
I just want to display the real time latitude and longitude as a map in a template by using a Django frame work how do I do this? ...
0
votes
1
answer
34
views
django-rest-framework-datatables server side FieldError: Cannot resolve keyword '0' into field
I have followed the docs from here: https://django-rest-framework-datatables.readthedocs.io/
I am getting this error:
django.core.exceptions.FieldError: Cannot resolve keyword '0' into field. Choices ...