PHPackages                             databreakers/php-data-api-client - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. databreakers/php-data-api-client

ActiveLibrary[API Development](/categories/api)

databreakers/php-data-api-client
================================

PHP client for DataBreakers DataAPI.

v2.1.0(8y ago)225.3k4MITPHPPHP &gt;=5.5.0

Since Nov 12Pushed 8y agoCompare

[ Source](https://github.com/DataBreakers/php-data-api-client)[ Packagist](https://packagist.org/packages/databreakers/php-data-api-client)[ Docs](https://databreakers.com)[ RSS](/packages/databreakers-php-data-api-client/feed)WikiDiscussions master Synced 4w ago

READMEChangelog (1)Dependencies (3)Versions (15)Used By (0)

PHP client for DataBreakers DataAPI
===================================

[](#php-client-for-databreakers-dataapi)

This library provides PHP implementation of client for DataBreakers DataAPI.

Requirements
------------

[](#requirements)

Library requires PHP version 5.4 (or higher) and [Guzzle](http://guzzlephp.org).

Installation
------------

[](#installation)

The best way to install it is using the [Composer](http://getcomposer.org/):

```
$ composer require databreakers/php-data-api-client
```

Quickstart
----------

[](#quickstart)

```
use DataBreakers\DataApi;

// Create a new instance of Client and provide your credentials
$client = new DataApi\Client('yourAccountId', 'yourSecretKey');

// Define items attributes (do this only when items attributes aren't defined in recommender yet)
$client->addItemsAttribute('title', DataApi\DataType::TEXT, 'en', DataApi\MetaType::TITLE);
$client->addItemsAttribute('color', DataApi\DataType::TEXT, 'en');
$client->addItemsAttribute('weight', DataApi\DataType::INTEGER);

// Add some items (if you are adding multiple items, users or interactions it's much faster to use batches)
$itemsBatch = (new DataApi\Batch\EntitiesBatch())
	->addEntity('fridgeId', [
		'title' => 'Fridge',
		'color' => 'white',
		'weight' => 55
	])
	->addEntity('carId', [
		'title' => 'Car',
		'color' => 'blue',
		'weight' => 1547
	]);
$client->insertOrUpdateItems($itemsBatch);

// Define users attributes (do this only when users attributes aren't defined in recommender yet)
$client->addUsersAttribute('name', DataApi\DataType::TEXT, 'en', DataApi\MetaType::TITLE);
$client->addUsersAttribute('age', DataApi\DataType::INTEGER);

// Add some users
$usersBatch = (new DataApi\Batch\EntitiesBatch())
	->addEntity('johnId', [
		'name' => 'John Smith',
		'age' => 35
	])
	->addEntity('sophiaId', [
		'name' => 'Sophia White',
		'age' => 27
	]);
$client->insertOrUpdateUsers($usersBatch);

// Add interactions between users and items
$interactionsBatch = (new DataApi\Batch\InteractionsBatch())
	->addInteraction('johnId', 'carId', 'Like')
	->addInteraction('johnId', 'carId', 'Purchase')
	->addInteraction('johnId', 'fridgeId', 'Dislike')
	->addInteraction('sophiaId', 'carId', 'Detail view')
	->addInteraction('sophiaId', 'fridgeId', 'Purchase');
$client->insertInteractions($interactionsBatch);

// And finally obtain ten recommendations for Sophia and car item!
$recommendations = $client->getRecommendations('sophiaId', 'carId', 10);

// If you want to send more recommendation requests at once, you can use recommendations batch
$batchRecommendations = $client->getRecommendationsBatch((new DataApi\Batch\RecommendationsBatch())
	->requestRecommendations('req1', 10, 'johnId', 'fridgeId', 20)
	->requestRecommendationsForUser('req2', 5, 'sophiaId', 15)
	->requestRecommendationsForItem('req3', 1, 'fridgeId', 10)
);
```

---

[DataBreakers](https://databreakers.com) – we are your data sense

###  Health Score

34

—

LowBetter than 75% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity66

Established project with proven stability

 Bus Factor1

Top contributor holds 96.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~58 days

Recently: every ~120 days

Total

14

Last Release

3123d ago

Major Versions

v1.2.8 → v2.0.02017-06-19

PHP version history (2 changes)v1.0.1PHP &gt;=5.4.0

v2.0.0PHP &gt;=5.5.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3398651?v=4)[Jan Veselý](/maintainers/janveselynet)[@janveselynet](https://github.com/janveselynet)

---

Top Contributors

[![janveselynet](https://avatars.githubusercontent.com/u/3398651?v=4)](https://github.com/janveselynet "janveselynet (101 commits)")[![jakubkratina](https://avatars.githubusercontent.com/u/712021?v=4)](https://github.com/jakubkratina "jakubkratina (3 commits)")[![semerak-michal](https://avatars.githubusercontent.com/u/6069348?v=4)](https://github.com/semerak-michal "semerak-michal (1 commits)")

### Embed Badge

![Health badge](/badges/databreakers-php-data-api-client/health.svg)

```
[![Health](https://phpackages.com/badges/databreakers-php-data-api-client/health.svg)](https://phpackages.com/packages/databreakers-php-data-api-client)
```

###  Alternatives

[statamic/cms

The Statamic CMS Core Package

4.8k3.6M962](/packages/statamic-cms)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M46](/packages/tencentcloud-tencentcloud-sdk-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k38](/packages/neuron-core-neuron-ai)[avalara/avataxclient

Client library for Avalara's AvaTax suite of business tax calculation and processing services. Uses the REST v2 API.

528.5M7](/packages/avalara-avataxclient)[files.com/files-php-sdk

Files.com PHP SDK

2481.1k](/packages/filescom-files-php-sdk)[aimeos/prisma

A powerful PHP package for integrating media related Large Language Models (LLMs) into your applications

1933.1k5](/packages/aimeos-prisma)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
