alexeevdv/carrot-quest-yii2-client

Yii2 component for carrot-quest-php-client

Installs: 2 459

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 2

Forks: 0

Open Issues: 0

Type:yii2-extension

0.1.0 2019-12-14 11:06 UTC

This package is auto-updated.

Last update: 2024-11-14 22:10:48 UTC


README

Build Status codecov PHP 7.1 PHP 7.2 PHP 7.3 PHP 7.4

Yii2 component for carrot-quest-php-client

Installation

The preferred way to install this extension is through composer.

Either run

$ php composer.phar require alexeevdv/carrot-quest-yii2-client "^0.1"

or add

"alexeevdv/carrot-quest-yii2-client": "^0.1"

to the require section of your composer.json file.

Configuration

[
    'components' => [
        'carrotQuest' => [
            'class' => alexeevdv\yii\CarrotQuest\Client::class,
            'authToken' => 'MY_AUTH_TOKEN',
        ],
    ],
]

or

[
    'container' => [
        'singletons' => [
            alexeevdv\CarrotQuest\ClientInterface::class => [
                'class' => alexeevdv\yii\CarrotQuest\Client::class,
                'authToken' => 'MY_AUTH_TOKEN',
            ],
        ],
    ],
]

Usage

Yii::$app->carrotQuest->userSetProperties(777, ['$name' => 'John'], false);

Methods

For the list of available methods see https://github.com/alexeevdv/carrot-quest-php-client