Test receiving a fax
Method
Path
faxes?direction=received
direction
parameter may be specified in URL or POST body. May only be used with test API credentials.
Request Parameters
Name | Type | Description |
---|---|---|
direction | String | Set to received to receive test fax. |
file | Binary Stream | A PDF file to simulate receiving. |
from_number | Phone Number | The phone number of the simulated sender in E.164 format. Default is the public Phaxio fax number. |
to_number | Phone Number | The phone number, in E.164 format, that is receiving the fax. Specifically, a Phaxio phone number you have purchased in your account that is "receiving" the fax, or the public Phaxio fax number. Default is the public Phaxio fax number. |
Response
A JSON object with success
and message
attributes.
Sample Call
curl https://api.phaxio.com/v2/faxes \
-u 'API_KEY:API_SECRET' \
-F 'direction=received' \
-F 'file=@/path/to/a/PDF/file/containing/a/PhaxCode'
Sample Response
{
"success":true,
"message":"Test fax received from +18773346654 to +18773346654. Calling back now..."
}