Midlaj, hi! Twilio developer evangelist here.
You cannot use a local path because media url has to be publicly accessible to Twilio's servers (ie it has to have a URL) so that the asset can be retrieved and added to the message. If a local path were accepted, it would point to "/Users/Name/file.gif" on a random Twilio server.
You can use Twilio Assets to send local files. You could alternatively also use Ngrok.com to expose your local webserver to the internet, hosting the files with ngrok and sharing the local files externally.
Let me know if this helps at all!
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…