Views
LLMClient api/v1/llm_clients CRUD views.
- class smarter.apps.llm_client.api.v1.views.views.LLMClientAPIKeyListView(*args, **kwargs)[source]
Bases:
ListViewBaseLLMClientAPIKey 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
LLMClientAPIKeySerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientAPIKeyView(*args, **kwargs)[source]
Bases:
ViewBaseLLMClientAPIKey view for smarter api.
- serializer_class
alias of
LLMClientAPIKeySerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientCustomDomainListView(*args, **kwargs)[source]
Bases:
ListViewBaseLLMClientCustomDomain 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
LLMClientCustomDomainSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientCustomDomainView(*args, **kwargs)[source]
Bases:
ViewBaseLLMClientCustomDomain view for smarter api.
- serializer_class
alias of
LLMClientCustomDomainSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientDeployView(*args, **kwargs)[source]
Bases:
ViewBaseLLMClient deployment view for smarter api.
- serializer_class
alias of
LLMClientSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientFunctionsListView(*args, **kwargs)[source]
Bases:
ListViewBaseLLMClientFunctions 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
LLMClientFunctionsSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientFunctionsView(*args, **kwargs)[source]
Bases:
ViewBaseLLMClientFunctions view for smarter api.
- serializer_class
alias of
LLMClientFunctionsSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientListView(*args, **kwargs)[source]
Bases:
ListViewBaseLLMClient list view for smarter api.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication checks and logging.
- Parameters:
request (Request) – 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
LLMClientSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientPluginListView(*args, **kwargs)[source]
Bases:
ListViewBaseLLMClientPlugin 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
LLMClientPluginSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientPluginView(*args, **kwargs)[source]
Bases:
ViewBaseLLMClientPlugin view for smarter api.
- serializer_class
alias of
LLMClientPluginSerializer
- class smarter.apps.llm_client.api.v1.views.views.LLMClientView(*args, **kwargs)[source]
Bases:
ViewBaseLLMClient view for smarter api.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication check.
- Parameters:
request (Request) – The incoming HTTP request.
- Raises:
AuthenticationFailed – Raised when authentication fails.
SmarterTokenAuthenticationError – Raised for errors specific to SmarterTokenAuthentication.
- serializer_class
alias of
LLMClientSerializer
- class smarter.apps.llm_client.api.v1.views.views.ListViewBase(*args, **kwargs)[source]
Bases:
SmarterAdminListAPIViewBase class for all llm_client list views.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication checks and logging.
- Parameters:
request (Request) – 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.llm_client.api.v1.views.views.ViewBase(*args, **kwargs)[source]
Bases:
SmarterAdminAPIViewBase class for all llm_client detail views.
- dispatch(request, *args, **kwargs)[source]
Extend DRF dispatch() to add authentication check.
- Parameters:
request (Request) – The incoming HTTP request.
- Raises:
AuthenticationFailed – Raised when authentication fails.
SmarterTokenAuthenticationError – Raised for errors specific to SmarterTokenAuthentication.