Views
ChatBot api/v1/chatbots CRUD views.
- class smarter.apps.chatbot.api.v1.views.views.ChatBotDeployView(*args, **kwargs)[source]
Bases:
ViewBaseChatBot deployment view for smarter api.
- serializer_class
alias of
ChatBotSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatBotFunctionsListView(*args, **kwargs)[source]
Bases:
ListViewBaseChatBotFunctions list view for smarter api.
- get_queryset(*args, **kwargs)[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using self.queryset.
This method should always be used rather than accessing self.queryset directly, as self.queryset gets evaluated only once, and those results are cached for all subsequent requests.
You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- serializer_class
alias of
ChatBotFunctionsSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotAPIKeyListView(*args, **kwargs)[source]
Bases:
ListViewBaseChatBotAPIKey list view for smarter api.
- get_queryset(*args, **kwargs)[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using self.queryset.
This method should always be used rather than accessing self.queryset directly, as self.queryset gets evaluated only once, and those results are cached for all subsequent requests.
You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- serializer_class
alias of
ChatBotAPIKeySerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotAPIKeyView(*args, **kwargs)[source]
Bases:
ViewBaseChatBotAPIKey view for smarter api.
- serializer_class
alias of
ChatBotAPIKeySerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotCustomDomainListView(*args, **kwargs)[source]
Bases:
ListViewBaseChatBotCustomDomain list view for smarter api.
- get_queryset(*args, **kwargs)[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using self.queryset.
This method should always be used rather than accessing self.queryset directly, as self.queryset gets evaluated only once, and those results are cached for all subsequent requests.
You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- serializer_class
alias of
ChatBotCustomDomainSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotCustomDomainView(*args, **kwargs)[source]
Bases:
ViewBaseChatBotCustomDomain view for smarter api.
- serializer_class
alias of
ChatBotCustomDomainSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotFunctionsView(*args, **kwargs)[source]
Bases:
ViewBaseChatBotFunctions view for smarter api.
- serializer_class
alias of
ChatBotFunctionsSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotListView(*args, **kwargs)[source]
Bases:
ListViewBaseChatBot list view for smarter api.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication checks and logging.
- Parameters:
request (HttpRequest) – The incoming HTTP request.
- Returns:
The HTTP response generated by the view.
- Return type:
HttpResponse
- Raises:
AuthenticationFailed – Raised when authentication fails.
SmarterTokenAuthenticationError – Raised for errors specific to SmarterTokenAuthentication.
- get_queryset(*args, **kwargs)[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using self.queryset.
This method should always be used rather than accessing self.queryset directly, as self.queryset gets evaluated only once, and those results are cached for all subsequent requests.
You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- serializer_class
alias of
ChatBotSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotPluginListView(*args, **kwargs)[source]
Bases:
ListViewBaseChatBotPlugin list view for smarter api.
- get_queryset(*args, **kwargs)[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using self.queryset.
This method should always be used rather than accessing self.queryset directly, as self.queryset gets evaluated only once, and those results are cached for all subsequent requests.
You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- serializer_class
alias of
ChatBotPluginSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotPluginView(*args, **kwargs)[source]
Bases:
ViewBaseChatBotPlugin view for smarter api.
- serializer_class
alias of
ChatBotPluginSerializer
- class smarter.apps.chatbot.api.v1.views.views.ChatbotView(*args, **kwargs)[source]
Bases:
ViewBaseChatBot view for smarter api.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication check.
- Parameters:
request (HttpRequest) – The incoming HTTP request.
- Raises:
AuthenticationFailed – Raised when authentication fails.
SmarterTokenAuthenticationError – Raised for errors specific to SmarterTokenAuthentication.
- serializer_class
alias of
ChatBotSerializer
- class smarter.apps.chatbot.api.v1.views.views.ListViewBase(*args, **kwargs)[source]
Bases:
SmarterAdminListAPIViewBase class for all chatbot list views.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication checks and logging.
- Parameters:
request (HttpRequest) – The incoming HTTP request.
- Returns:
The HTTP response generated by the view.
- Return type:
HttpResponse
- Raises:
AuthenticationFailed – Raised when authentication fails.
SmarterTokenAuthenticationError – Raised for errors specific to SmarterTokenAuthentication.
- class smarter.apps.chatbot.api.v1.views.views.ViewBase(*args, **kwargs)[source]
Bases:
SmarterAdminAPIViewBase class for all chatbot detail views.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication check.
- Parameters:
request (HttpRequest) – The incoming HTTP request.
- Raises:
AuthenticationFailed – Raised when authentication fails.
SmarterTokenAuthenticationError – Raised for errors specific to SmarterTokenAuthentication.