SAGEA LogoDocs & API
CookbooksMYLO Cookbooks

Place Outbound Reminder Calls

Schedule MYLO outbound calls from a CSV of appointments and track each call to completion.

  • Schedule calls with to, agent_id, and scheduled_at
  • Launch a batch from CSV without double dialing
  • Poll per-call status until each reminder completes Time to complete: ~20 minutes

Prerequisites

  • SAGEA_API_KEY exported in your shell as Bearer auth
  • Python 3.10+ with requests installed
  • A CSV file with phone, name, and scheduled_at columns
  • Complete Send your first API request
  • Read the MYLO overview import from '@/components/Tabs';

Step 1: Prepare your appointments CSV

Create a CSV with E.164 numbers and ISO timestamps for each reminder.

cat appointments.csv
# phone,name,scheduled_at
# +9779812345678,Asha,2026-09-16T09:00:00+05:45
# +9779856781234,Bikash,2026-09-16T09:15:00+05:45

Use +97798XXXXXXXX format and keep times in the recipient local zone.

Step 2: Schedule outbound calls

Call POST /mylo/calls once per row with to, agent_id, and scheduled_at.

curl -X POST https://api.sagea.space/mylo/calls \
  -H "Authorization: Bearer $SAGEA_API_KEY" -H "Content-Type: application/json" \
  -d '{"to":"+9779812345678","agent_id":"reminder_np","scheduled_at":"2026-09-16T09:00:00+05:45"}'

Store each returned call_id next to the CSV row for status polling.

Step 3: Poll per-call status to completion

Poll each call until it reaches a terminal state before marking it done.

CALL_ID="call_REPLACE_ME"
curl https://api.sagea.space/mylo/calls/$CALL_ID \
  -H "Authorization: Bearer $SAGEA_API_KEY"
# repeat until status is completed, failed, busy, or no-answer

Retry busy once, and log failed numbers for manual follow up.

Verify

ErrorCauseFix
401 UnauthorizedMissing or invalid API keyExport valid SAGEA_API_KEY and retry
404 session_not_foundStale call ID in poll loopRefresh call_id list from Step 2 output
429 rate_limit_exceededBatch scheduled too fastAdd delay between creates, retry with backoff
422 voice_not_foundAgent uses unknown voice presetSet agent voice to nova or atlas

What's next

On this page