sashalenz/binotel-api

API for Binotel

1.7.0 2024-04-01 12:18 UTC

This package is auto-updated.

Last update: 2024-10-31 00:18:57 UTC


README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

Installation

You can install the package via composer:

composer require sashalenz/binotel-api

You can publish and run the migrations with:

php artisan vendor:publish --provider="Sashalenz\Binotel\BinotelServiceProvider" --tag="binotel-api-migrations"
php artisan migrate

You can publish the config file with:

php artisan vendor:publish --provider="Sashalenz\Binotel\BinotelServiceProvider" --tag="binotel-api-config"

This is the contents of the published config file:

return [
    'url' => env('BINOTEL_API_URL', 'https://api.binotel.com/api/'),
    'version' => env('BINOTEL_API_VERSION', '4.0'),
    'format' => env('BINOTEL_API_FORMAT', 'json'),

    'key' => env('BINOTEL_API_KEY', null),
    'secret' => env('BINOTEL_API_SECRET', null),

    'actions' => [
        'apiCallSettings' => \Sashalenz\Binotel\Actions\ApiCallSettings::class,
        'apiCallCompleted' => \Sashalenz\Binotel\Actions\ApiCallCompleted::class,
        'receivedTheCall' => \Sashalenz\Binotel\Actions\ReceivedTheCall::class,
        'answeredTheCall' => \Sashalenz\Binotel\Actions\AnsweredTheCall::class,
        'hangupTheCall' => \Sashalenz\Binotel\Actions\HangupTheCall::class
    ],

    'customer_class' => null,
    'employee_class' => null,
    'pbx_class' => null,

    'domain' => env('BINOTEL_API_DOMAIN', env('APP_URL'))
];

Usage

$customersList = Sashalenz\Binotel\Binotel::customers()->list();

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

The MIT License (MIT). Please see License File for more information.