<commit_before># BadgeKit Client

[![Latest Version on Packagist][ico-version]][link-packagist]
[![Software License][ico-license]](LICENSE.md)
[![Total Downloads][ico-downloads]][link-downloads]

Here is a PHP client for Mozilla's [BadgeKit API][badgekit-api].

## Install

Via Composer

``` bash
$ composer require caxy/badgekit-client
```
## Usage

``` php
$factory = new ClientFactory('https://badgekit.example.com', 'MASTER_SECRET_FROM_BADGEKIT');
$client = $factory->createServiceClient();

$command = $client->getCommand('get_reviews', [
  'system' => 'example',
  'application' => '235f684c5e5f88f1575434403adc2562',
  'badge' => 'a-groovy-badge',
]);
$result = $client->execute($command);
```

## Change log

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

## Testing

``` bash
$ composer test
```<commit_msg>add namespace to usage example.<commit_after># BadgeKit Client

[![Latest Version on Packagist][ico-version]][link-packagist]
[![Software License][ico-license]](LICENSE.md)
[![Total Downloads][ico-downloads]][link-downloads]

Here is a PHP client for Mozilla's [BadgeKit API][badgekit-api].

## Install

Via Composer

``` bash
$ composer require caxy/badgekit-client
```
## Usage

``` php
$factory = new Caxy\BadgeKit\ClientFactory('https://badgekit.example.com', 'MASTER_SECRET_FROM_BADGEKIT');
$client = $factory->createServiceClient();

$command = $client->getCommand('get_reviews', [
  'system' => 'example',
  'application' => '235f684c5e5f88f1575434403adc2562',
  'badge' => 'a-groovy-badge',
]);
$result = $client->execute($command);
```

## Change log

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

## Testing

``` bash
$ composer test
```
{'fraction_non_alphanumeric': 0.17164179104477612, 'fraction_numerical': 0.027554535017221583, 'mean_word_length': 6.085365853658536, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 15, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2780008', 'n_tokens_mistral': 654, 'n_tokens_neox': 605, 'n_words': 126}