David Ewins
Error library

Scheduled retry job runs every 6 hours and never does anything (401 every time)

OtherConfirmed fix

pg_cron + pg_net calling an Express API

There is no error message for this one, only the symptom in the title.

Cause

The pg_cron job sent the cron shared secret to a route protected by admin-user auth, so every call returned 401 and was ignored. The job looked scheduled and healthy.

Fix

Check net._http_response for the job's status codes. Point the job at a route that authenticates the cron secret (or run the work inside an existing cron route that does), and add a test that the route accepts the cron credential.

More Other errors

Search all errors