How to do API calls?

I created a small repository where there is an example on how to send an email (sendgrid) using a “Queue Canister”, a NodeJS worker (using redis) “oracle”, that fetch tasks periodically from a queue canister and then trigger some API calls.

Worker code is here: https://github.com/davidp94/icqs-demo/tree/master/worker

Queue Canister: https://github.com/davidp94/icqs-demo/blob/master/src/icqs_demo/main.mo

Example of your canister adding a task to the Queue Canister: https://github.com/davidp94/icqs-demo/blob/master/src/icqs_demo_developer_canister/main.mo