How do I use the 'Error' endpoint?

The 'Error' API endpoint is your endpoint to let the Argus system know the cron job has thrown an error. It can be a simple GET endpoint if you just want to log that an error occurred. You can notify it by simply sending a curl request such as curl https://argus.to/your_unique/endpoint_url/error when you capture the error.

If you are on the Laravel framework, all you need to do is at the `pingOnFailure` directive to your scheduler.

$schedule->command('emails:send') ->daily() ->pingOnFailure('https://argus.to/your_unique/endpoint_url/error');

If you wish to pass a JSON message with your error, you can also make a POST request to the same endpoint with your message. An example of that might be something like

curl -d '{"status":"error", "message":"add your error message here"}' -H "Content-Type: application/json" -X POST https://argus.to/your_unique/endpoint_url/error