Dev License: This installation of WHMCS is running under a Development License and is not authorized to be used for production use. Please report any cases of abuse to abuse@whmcs.com

API Fax Functions Print

  • 0

cancelFaxNumber
Parameters

id      =>  [Required] ID for a specific Fax Number (Example: 923)
test    =>  Set to true if testing how cancel a Fax Number                            
Output

Array
(
    [status] => success
    [deleted_did] => 5551234567
)
                            
deleteFaxMessage
Parameters

id      =>  [Required] ID for a specific Fax Message (Example: 923)
test    =>  Set to true if testing how cancel a Fax Message                            
Output

Array
(
    [status] => success
)
                            
delEmailToFax
Parameters

id      =>  [Required] ID for a specific "Email To Fax Configuration" (Example: 923)
test    =>  Set to true if testing how cancel a "Email To Fax Configuration"                            
Output

Array
(
    [status] => success
)
                            
delFaxFolder
Parameters

id      =>  [Required] ID for a specific Fax Folder (Example: 923)
test    =>  Set to true if testing how to delete a Fax Folder                            
Output

Array
(
    [status] => success
)
                            
getBackOrders
Parameters
id => ID for a specific backorder DID
Output

Array
(
    [status] => success
    [quantity] => 1
    [back_orders] => Array
        (
            [0] => Array
                (
                    [id] => 1234
                    [description] => MIAMI, FL
                    [routing] => account:100001_VoIP
                    [failover_busy] => none:
                    [failover_unreachable] => fwd:1521
                    [failover_noanswer] => none:
                    [voicemail] => 1001
                    [pop] => 16
                    [dialtime] => 60
                    [cnam] => 1
                    [billing_type] => 2
                    [order_date] => 2014-07-30 15:09:04
                )
        )
)
                            
getFaxProvinces
Parameters
province     => CODE for a specific Province (Example: AB)
Output

Array
(
    [status] => success
    [provinces] => Array
        (
            [0] => Array
                (
                    [province] => AB
                    [province_id] => 60
                    [province_name] => Alberta
                    [country_code] => CAN
                )
        )
)
                            
getFaxStates
Parameters
state     => CODE for a specific State (Example: AL)
Output

Array
(
    [status] => success
    [states] => Array
        (
            [0] => Array
                (
                    [state] => AL
                    [state_id] => 1
                    [state_name] => Alabama
                    [country_code] => USA
                )
        )
)
                            
getFaxRateCentersCAN
Parameters

province      =>  [Required] Province two letters code (Example: AB)                            
Output

Array
(
    [status] => success
    [ratecenters] => Array
        (
            [0] => Array
                (
                    [location] => 20294
                    [area_code] => 587
                    [ratecenter] => EDMONTON
                    [available] => yes
                )
        )
)
                            
getFaxRateCentersUSA
Parameters

state      =>  [Required] Province two letters code (Example: AL)                            
Output

Array
(
    [status] => success
    [ratecenters] => Array
        (
            [0] => Array
                (
                    [location] => 1196
                    [area_code] => 205
                    [ratecenter] => ALABASTER
                    [available] => yes
                )
        )
)
                            
getFaxNumbersInfo
Parameters

did      =>  Fax Number to retrieves the information of a single number, or not send if 
you want retrieves the information of all your Fax Numbers.
Output

Array
(
    [status] => success
    [numbers] => Array
        (
            [0] => Array
                (
                    [id] => 0000
                    [did] => 5551234567
                    [description] => United States, CA, HALF MOON BAY
                    [state] => CA
                    [city] => HALF MOON BAY
                    [country] => United States
                    [email_enabled] => 1
                    [email] => address@email.com
                    [url_enabled] => 1
                    [url] => www.example.com
                    [retry] => 0
                    [attach_file] => 1
                )
        )
)
                            
getFaxNumbersPortability
Parameters

did      =>  [Required] DID Number to be ported into our network (Example: 5552341234)                            
Output

Array
(
    [status] => success
    [getFaxNumbersPortability] => yes
)
                            
getFaxMessages
Parameters

from      =>    Start Date for Filtering Fax Messages (Example: '2014-03-30') - Default value: Today
to        =>    End Date for Filtering Fax Messages (Example: '2014-03-30') - Default value: Today
folder    =>    Name of specific Fax Folder (Example: SENT) - Default value: ALL
id        =>    ID for a Specific Fax Message (Example: 23434)                            
Output

Array
(
    [status] => success
    [faxes] => Array
        (
            [0] => Array
                (
                    [id] => 0000
                    [folder] => INBOX
                    [date] => 2016-01-01 00:00:00
                    [callerid] => 5552341234
                    [stationid] => 5552341234
                    [destination] => 7772341234
                    [description] => INBOUND FAX
                    [pages] => 2
                    [duration] => 1:16
                    [status] => SUCCESS
                    [rate] => 0.000
                    [total] => 0.000
                    [msg] =>
                )
        )
)
                            
getFaxMessagePDF
Parameters

id      =>    [Required] ID of the Fax Message requested (Values from getFaxMessages)                            
Output

Array
(
    [status] => success
    [message_base64] => PDF file encrypted in Base64
)
                            
getFaxFolders
Parameters

                            
Output

Array
(
    [status] => success
    [folders] => Array
        (
            [0] => Array
                (
                    [id] => 0000
                    [name] => INBOX
                )
        )
)
                            
getEmailToFax
Parameters

                                    ID of the "Email to Fax" configuration                            
Output

Array
(
    [status] => success
    [emailToFax] => Array
        (
            [0] => Array
                (
                    [id] => 0000
                    [enabled] => 1
                    [email] => your@email.com
                    [security_code] => 12345
                    [security_code_enabled] => 1
                    [from] => 5552341234
                )
        )
)
                            
mailFaxMessagePDF
Parameters

id      =>    [Required] ID of the Fax Message requested (Values from getFaxMessages)
email   =>    [Required] Destination email adreess (example: yourname@company.com)                            
Output

Array
(
    [status] => success
    [message_status] => message_sent
)
                            
moveFaxMessage
Parameters

fax_id      =>    [Required] ID of the Fax Message requested (Values from getFaxMessages)
folder_id   =>    [Required] ID of the destination Fax Folder (Values from getFaxFolders)
test        =>    Set to true if testing how to move a Fax Message                            
Output

Array
(
    [status] => success
)
                            
orderFaxNumber
Parameters

location            =>    [Required] Location ID of the Fax Number (Values from getFaxRateCentersCAN/getFaxRateCentersUSA)
quantity             =>    [Required] Quantity of Fax Numbers to order (Example: 3)
email               =>    Email address where send notifications when receive Fax Messages 
                          - (Example: yourname@company.com)
email_enable        =>    Flag to enable the email notifications.
                          - (Values: 1 = true, 0 = false) - Default: 0
email_attach_file   =>    Flag to enable attach the Fax Message as a PDF file in the notifications. 
                          - (Values: 1 = true, 0 = false) - Default: 0
url_callback        =>    URL where make a POST when you receive a Fax Message.
url_callback_enable =>    Flag to enable the URL Callback functionality.
                          - (Values: 1 = true, 0 = false) - Default: 0
url_callback_retry  =>    Flag to enable retry the POST action in case we don't receive "ok".
test                =>      Set to true if testing how Orders work
                            - Orders can not be undone
                            - When testing, no Orders are made                            
Output

Array
(
    [status] => success
    [dids]   => array(
        [0] => 5552341234
        [1] => 5552341234
        [2] => 5552341234
        ...
    )
)
                            
setFaxFolder
Parameters

name        =>    [Required] Name of the Fax Folder to create or update (Example: FAMILY)
id          =>    [Only for updates] ID of the Fax Folder to edit (Values from getFaxFolders)
test        =>    Set to true if testing how to create/update a Fax Folder                            
Output

Array
(
    [status] => success
)
                            
setEmailToFax
Parameters

id                    =>    [Only for updates] ID of the "Email to Fax" to edit (Values from getEmailToFax)
enabled               =>    If Enable, we will send Fax Message when we receive an email from the provided address. (Values:1=Enable / 0=Disable)
auth_email            =>    [Required] Email address from you will sent Fax Messages
from_number_id        =>    [Required] Fax number that will appear as fax sender. (values from getFaxNumbersInfo)
security_code_enabled =>    If Enable, we will check the mail subject if this include a Security Code before send the Fax. (Values:1=Enable / 0=Disable)
security_code         =>    [Required] An alphanumeric code to identify your emails before send as Fax.
test                  =>    Set to true if testing.                            
Output

Array
(
    [status] => success
)
                            
searchFaxAreaCodeCAN
Parameters

area_code   =>    [Required] Area code number, as the initial of the Fax Number you looking for. (values from getFaxRateCentersCAN)                            
Output

Array
(
    [status] => success
    [ratecenters]   => array(
        [0] => Array
            (
                [ratecenter] => ACTON
                [area_code] => 226
                [available] => yes
            )
    )
)
                            
searchFaxAreaCodeUSA
Parameters

area_code   =>    [Required] Area code number, as the initial of the Fax Number you looking for. (values from getFaxRateCentersUSA)                            
Output

Array
(
    [status] => success
    [ratecenters]   => array(
        [0] => array(
            [ratecenter] => COLD SPRING
            [area_code]  => 845
            [available]  => yes
        )
    )
)
                            
setFaxNumberInfo
Parameters

did                 =>    [Required] DID Number to be ported into our network (Example: 5552341234)
email               =>    Email address where send notifications when receive Fax Messages 
                          - (Example: yourname@company.com)
email_enable        =>    Flag to enable the email notifications.
                          - (Values: 1 = true, 0 = false) - Default: 0
email_attach_file   =>    Flag to enable attach the Fax Message as a PDF file in the notifications. 
                          - (Values: 1 = true, 0 = false) - Default: 0
url_callback        =>    URL where make a POST when you receive a Fax Message.
url_callback_enable =>    Flag to enable the URL Callback functionality.
                          - (Values: 1 = true, 0 = false) - Default: 0
url_callback_retry  =>    Flag to enable retry the POST action in case we don't receive "ok".
test                =>    Set to true if testing how to update the information of a Fax Number                            
Output

Array
(
    [status] => success
)
                            
setFaxNumberEmail
Parameters

did                 =>    [Required] DID Number to be ported into our network (Example: 5552341234)
email               =>    Email address where send notifications when receive Fax Messages 
                          - (Example: yourname@company.com)
email_enable        =>    Flag to enable the email notifications.
                          - (Values: 1 = true, 0 = false) - Default: 0
email_attach_file   =>    Flag to enable attach the Fax Message as a PDF file in the notifications. 
                          - (Values: 1 = true, 0 = false) - Default: 0
test                =>    Set to true if testing how to set the email of a Fax Number                            
Output

Array
(
    [status] => success
)
                            
setFaxNumberURLCallback
Parameters

did                 =>    [Required] DID Number to be ported into our network (Example: 5552341234)
url_callback        =>    URL where make a POST when you receive a Fax Message.
url_callback_enable =>    Flag to enable the URL Callback functionality.
                          - (Values: 1 = true, 0 = false) - Default: 0
url_callback_retry  =>    Flag to enable retry the POST action in case we don't receive "ok".
test                =>    Set to true if testing how to set the URL callback of a Fax Number                            
Output

Array
(
    [status] => success
)
                            
sendFaxMessage
Parameters

to_number           =>    [Required] Destination DID Number (Example: 5552341234)
from_name           =>    [Required] Name of the sender (Example: 5552341234)
from_number         =>    [Required] DID number of the Fax sender
send_email_enabled  =>    Flag to enable the send of a copy of your Fax via email.
                          - (Values: 1 = true, 0 = false) - Default: 0
send_email          =>    Email address where you want send a copy of your Fax.
station_id          =>    An word to identify a equipment or department sending the Fax.
file                =>    [Required] The file must be encoded in Base64, and in one of the following formats: pdf, txt, jpg, gif, png, tif 
test                =>    Set to true if testing how to send a Fax Message                            
Output

Array
(
    [status] => success
)
                            

Was this answer helpful?

« Back

Powered by WHMCompleteSolution