Clear error messagesΒΆ
Provide useful error messages
Graceful handling of failure conditions is an essential part of delivering a high quality API.
Recommended
Error messages should conform to the standards relevant for the technology in use.
Recommended
Error messages should provide a human-readable error message that is designed to be read and understood by the user.
Recommended
Error messages should include a diagnostic message that contains technical details for use by the developers/maintainers of the application that consumes the API.
May
Diagnostic messages may include links to documentation and other ‘hints’ that might assist developers resolve issues that may have resulted in the error condition.
Further information on error messaging for REST APIs is provided in the Build and publish APIs guidance.