Authentication

Most API calls require authentication. The client libraries have built-in authentication handling, which will automatically authenticate each request when properly initialized.

HTTP Authentication

HTTP authentication may be used simply by using the API key as the username and the API secret as the password. For example:

curl 'https://api.phaxio.com/v2.1/faxes/123' \
  -u 'API_KEY:API_SECRET'
require_once('autoload.php');

$faxId = '123';

use Phaxio\Phaxio;
$phaxio = new Phaxio('API_KEY', 'API_SECRET', 'https://api.phaxio.com/v2.1/');
$phaxio->faxStatus($faxId);