error.py 691 B

1234567891011121314151617181920212223242526
  1. from libs.exception import BaseHTTPException
  2. class NotCompletionAppError(BaseHTTPException):
  3. error_code = 'not_completion_app'
  4. description = "Not Completion App"
  5. code = 400
  6. class NotChatAppError(BaseHTTPException):
  7. error_code = 'not_chat_app'
  8. description = "App mode is invalid."
  9. code = 400
  10. class NotWorkflowAppError(BaseHTTPException):
  11. error_code = 'not_workflow_app'
  12. description = "Only support workflow app."
  13. code = 400
  14. class AppSuggestedQuestionsAfterAnswerDisabledError(BaseHTTPException):
  15. error_code = 'app_suggested_questions_after_answer_disabled'
  16. description = "Function Suggested questions after answer disabled."
  17. code = 403