keboola / sync-actions-client
Sync actions PHP Client
2.0.0
2024-09-04 13:01 UTC
Requires
- php: ^8.2
- guzzlehttp/guzzle: ^7.8
- psr/log: ^1.1
- symfony/config: ^6.4
- symfony/validator: ^6.4
Requires (Dev)
- keboola/coding-standard: >=7.0.2
- keboola/php-temp: ^2.0
- php-parallel-lint/php-parallel-lint: ^1.3
- phpstan/phpstan: ^1.4
- phpunit/phpunit: ^9.5
- symfony/process: ^5.0
README
PHP client for the Job Queue API (API docs).
Usage
composer require keboola/sync-actions-api-php-client
use Keboola\SyncActionsClient\Client; use Keboola\SyncActionsClient\JobData; use Psr\Log\NullLogger; $client = new Client( 'http://sync-actions.keboola.com/', 'xxx-xxxxx-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ); $result = $client->createJob(new JobData( 'keboola.ex-db-snowflake', 'getTables' )); var_dump($result);
Development
Clone this repository and init the workspace with following command:
git clone https://github.com/keboola/sync-actions-api-php-client
cd sync-actions-api-php-client
docker-compose build
docker-compose run --rm dev composer install --no-scripts
Create .env
file with following contents:
KBC_SYNC_ACTIONS_URL=https://sync-actions.keboola.com/ KBC_TOKEN=xxx-xxxxx-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Run the test suite using this command:
docker-compose run --rm dev composer tests
Integration
For information about deployment and integration with KBC, please refer to the deployment section of developers documentation