Set username and password for certain URL

Hello everyone
I need to lock a URL in this form:
Does anyone know if it’s possible here on Cloudflare or on AWS?

This URL launches every one minute by a cronjob service, in order to run a process that import content into my website.
I want to keep it private so people won’t attack it in order to crash my website.

Thank you and happy holidays

Where does that cron job run? On the same machine?

Yes, that’s correct

In that case do yourself a favour and refactor your code to not be dependent on some external HTTP call but simply invoke that code locally via a regular command line call. That would be the only sensible approach in this case.