lee-to/php-calendly

Calendly API client for PHP

v1.0 2020-08-19 07:42 UTC

This package is auto-updated.

Last update: 2024-04-19 15:45:09 UTC


README

Calendly API client for PHP

Installation

Calendly API client for PHP can be installed with Composer. Run this command:

composer require lee-to/php-calendly

Usage.

Documentation

Api token

use CalendlyApi\CalendlyApi;
use CalendlyApi\HttpAdapters\CurlHttpClient;

Init.

$calendlyApi = new CalendlyApi($token, new CurlHttpClient);

Hooks

List all

$calendlyApi->hook()->all()

Get one

$calendlyApi->hook()->get($id)

Create

$calendlyApi->hook()->create(["url" => "https://name.com", "events" => ["invitee.created"]])

Delete

$calendlyApi->hook()->delete($id)

User

About

$calendlyApi->user()->me()

User Event Types

$calendlyApi->user()->event_types()

Tests

  1. Composer is a prerequisite for running the tests. Install composer globally, then run composer install to install required files.
  2. Get personal token, then create tests/CalendlyApiTestCredentials.php from tests/CalendlyApiTestCredentials.php.dist and edit it to add your credentials.
  3. The tests can be executed by running this command from the root directory:
$ ./vendor/bin/phpunit

Contributing

Please see CONTRIBUTING for details.

Credits

License

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

Security

If you have found a security issue, please contact the maintainers directly at leetodev@ya.ru.