by ricmarques » Fri Jul 27, 2012 10:33 am
Les -
I went down this road for a customer about 9 months ago... I ended up using Hylafax with IAXmodem on a separate Asterisk server and peered it to the Switchvox to send faxes over the PRI. One big advantage to this approach is the large number of Hylafax clients, and it's ease of integration. (I'll let you research that part on your own). We just used a standard Hylafax printer client that prompts for the phone number when you print, and you're done.
Now, to answer your question more directly: The main difficulty with using the Switchvox API to send faxes is the fact that it is undocumented, and unsupported (and I was told by someone very high up in the food chain at Digium that this particular API was going to stay that way - undocumented and unsupported). That said, the next problem is how the API call functions:
switchvox.users.fax.send is the API call that is used. The parameters (all are required) for use are:
"account_id": <the account user id number that you wish to send a fax from>
"fax_id": <the id number of the fax you wish to send>
"folder": <the folder that fax exists in>
"phone_number": <the phone number you want to send to>
(I guess I just documented this API for Digium... )
account_id and folder are easy to obtain, but identifying exactly which fax_id and matching it all together, and then providing the phone_number to send it to aren't so easy... it could require just about as much interaction with the user as using the built-in functionality...