https://github.com/rootworkit/php-sfax
PHP client for Scrypt's Sfax service.
https://github.com/rootworkit/php-sfax
hacktoberfest hipaa sfax
Last synced: about 1 month ago
JSON representation
PHP client for Scrypt's Sfax service.
- Host: GitHub
- URL: https://github.com/rootworkit/php-sfax
- Owner: rootworkit
- License: mit
- Created: 2016-10-03T15:40:56.000Z (about 9 years ago)
- Default Branch: 2.0.x
- Last Pushed: 2024-08-29T05:53:56.000Z (about 1 year ago)
- Last Synced: 2025-08-29T04:18:34.193Z (about 1 month ago)
- Topics: hacktoberfest, hipaa, sfax
- Language: PHP
- Homepage:
- Size: 79.1 KB
- Stars: 3
- Watchers: 3
- Forks: 3
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# php-sfax
PHP client for Scrypt's Sfax service.## Installation
```bash
composer require rootwork/php-sfax
```## Usage Examples
### Create the Client Instance
```php
sendFax(
'Malcolm Reynolds',
'19999999999',
'/path/to/file.pdf'
);if ($result->isSuccess) {
$queueId = $result->SendFaxQueueId;
}
```### Send a Fax from a URL
```php
sendFaxFromUrl(
'Malcolm Reynolds',
'19999999999',
Rootwork\Sfax\Client::FORMAT_TIF,
'https://www.yoursite.com/getFile?token=ABC123&file=12345678.tif'
);
```### Download Inbound Faxes
```php
receiveInboundFax();foreach ($result->InboundFaxItems as $fax) {
$fileData = $sfax->downloadInboundFaxAsPdf($fax->FaxId);
file_put_contents("/faxes/$fax->FaxId.pdf", $fileData);
}
```## Running Tests
Tests can be run using composer helper scripts, `test` or `testdox`, depending on your output preferences.
```bash
composer install
composer test
composer testdox
```Code coverage reports are written to `build/`.