[docs]@set_service_action_metadata(endpoint=TextGenerationLimitRetrieveEndpoint)defretrieve(self)->TextGenerationLimitRetrieveResponse:""" Retrieves the current text generation limit from the server. Raises: ApiResponseException: In case of a known API error. ApiNetworkException: In case of unhandled network error. """self._log_method_execution("Text Generation Limit Retrieve")withself._get_http_client()asclient:metadata=get_service_action_metadata(self.retrieve)response=client.get(url=self._get_endpoint(metadata.endpoint),params=_TextGenerationLimitRetrieveParametersQuery().model_dump(),)returnTextGenerationLimitRetrieveResponse(**response.json())
[docs]@set_service_action_metadata(endpoint=TextGenerationLimitRetrieveEndpoint)asyncdefaretrieve(self)->TextGenerationLimitRetrieveResponse:""" Retrieves the current text generation limit from the server. Raises: ApiResponseException: If target feedback/generation does not exist or cannot be updated. ApiNetworkException: In case of unhandled network error. """self._log_method_execution("Text Generation Limit ARetrieve")asyncwithself._get_async_http_client()asclient:metadata=get_service_action_metadata(self.aretrieve)response=awaitclient.get(url=self._get_endpoint(metadata.endpoint),params=_TextGenerationLimitRetrieveParametersQuery().model_dump(),)returnTextGenerationLimitRetrieveResponse(**response.json())