DRF Views
Setup
uv add "djangosdk[drf]"ChatAPIView
Usage
# myapp/views.py
from djangosdk.views.chat import ChatAPIView
from myapp.agents import SupportAgent
class SupportChatView(ChatAPIView):
agent_class = SupportAgent# myapp/urls.py
from django.urls import path
from myapp.views import SupportChatView
urlpatterns = [
path("api/chat/", SupportChatView.as_view()),
]Request Format
Response Format
StreamingChatAPIView
Usage
Request Format
SSE Response
Authentication
Customizing the Agent Per Request
URL Configuration
Last updated
Was this helpful?