Skip to main content

Extensibility and Integration

 

OutSystems

Handling REST Errors

When retrieving data from a REST API, if the service returns an HTTP error status code (400 and above), OutSystems throws an exception. This allows you to easily handle the REST API error by implementing your own logic.

To handle a REST API error, do the following:

  1. Add an Exception Handler in the logic that uses the REST API, and set the Exception Handler to catch All Exceptions;
  2. Implement the logic to handle the error, like displaying a message to the end-user.
  • Was this article helpful?