Skip to content

Instantly share code, notes, and snippets.

@kaydarla
Last active February 10, 2024 18:43
Show Gist options
  • Save kaydarla/6052330 to your computer and use it in GitHub Desktop.
Save kaydarla/6052330 to your computer and use it in GitHub Desktop.
Spoof Call
#!/bin/bash
AUTH_ID="Replace with your auth_id"
AUTH_TOKEN="Replace with your auth_token"
# Use a phone number in E164 format
SPOOF_CALLER_ID="Set a CLID here"
YOUR_PHONE_NUMBER="Set your phone number"
NUMBER_TO_CALL="Set the phone number to call"
curl -XPOST \
-u ${AUTH_ID}:${AUTH_TOKEN} \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d "{\"from\":\"${SPOOF_CALLER_ID}\",\"to\":\"YOUR_PHONE_NUMBER\",\"answer_url\":\"https://plivodirectdial.herokuapp.com/response/sip/route/?ForwardTo=${NUMBER_TO_CALL}&CLID=${SPOOF_CALLER_ID}\",\"answer_method\":\"GET\"}"
https://api.plivo.com/v1/Account/${AUTH_ID}/Call/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment