survease / php-lib
Survease API PHP Library
0.1.1
2021-06-03 11:05 UTC
Requires
- php: ^7.4
- ext-curl: *
- ext-json: *
- guzzlehttp/guzzle: ^7.3
Requires (Dev)
- league/openapi-psr7-validator: ^0.16.1
- phpunit/phpunit: ^9.5
- roave/security-advisories: dev-master
- symplify/easy-coding-standard: ^9.3
This package is auto-updated.
Last update: 2024-12-29 06:34:37 UTC
README
Join Survease platform here: https://www.survease.com/
Installation
composer require survease/php-lib
Example
<?php $httpClient = \Survease\Api\HttpClientFactory::make('apikey'); $client = new \Survease\Api\Client($httpClient); // Add a single invitation to dispatch $resource = $client->survey('surveyId') ->invitations() ->add(new \Survease\Api\DTO\InvitationRecipient('email@email.com', 'John', 'Snow', 'ru')); $response = $client->makeRequest($resource); if ($response->isSuccessful()) { echo "Well done"; }