PHPackages                             contee/php-sdk - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. contee/php-sdk

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

contee/php-sdk
==============

Conteeapp PHP sdk.

00PHP

Since Mar 17Pushed 11y agoCompare

[ Source](https://github.com/marekgalovic/contee-php-sdk)[ Packagist](https://packagist.org/packages/contee/php-sdk)[ RSS](/packages/contee-php-sdk/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (0)

contee-sdk
==========

[](#contee-sdk)

Software development kit for Contee service. Allows to send newsletters, working with matched data and accessing API routes.

Instalation
-----------

[](#instalation)

Sdk is developed as composer package. To instal just run:

```
composer install

```

To access API routes, that require authorization you have to pass **client\_id** and **client\_secret** credentials by **app\_id** parameter.

```
$contee = new Contee\Contee(new Contee\Auth\ApiAuth("app_id", "client_id", "client_secret"));

```

Accessing API route
-------------------

[](#accessing-api-route)

Api routes are currently allowed from **Pro plan**. Sdk has method for accessing them. When the route has an option you can pass the parameter in options array and it will be automatically replaced. Every api call returns `Contee\Response\Response` object, which has methods to get content back as raw output, json string, array or object.

```
$contee->get("/site/visits/:option, array(":option"=>"perpage"))->toObject();

```

Serving content
---------------

[](#serving-content)

To match the right content for every one of your customers and rise your earns we need to get it first. The easiest way to do this is use this Sdk. Returns `Contee\Response\Response` which has methods to display as mentoied above.

```
$matched = $contee->createMatched();

$item = $contee->createItem();
$item->setTags(array("tag1", "tag2", "tag3")); //required item to correctly matching
$item->setData(array("name"=>"FOO")); //whatever data you want to get back and display

$matched->setItem($item);
$matched->setResource("email@service.com"); //if resource is not passed contee cookie is used or blank

$contee->getMatched($matched)->toObject();

```

Emails
------

[](#emails)

Matched emails are similar than the way of serving content mentoied above. Each of thoose emails has content perfectly matched for everyone of your customers. This funcionality requires authorization with **client\_id** and **client\_secret**.

```
$newsletter = $contee->createNewsletter();

$item = $contee->createItem();
$item->setTags(array("tag1", "tag2", "tag3")); //required item to correctly matching
$item->setData(array("name"=>"FOO")); //you can access this data in email template.

$message = $contee->createMessage();
$message->setCustom(array("message" => "Hi there."));
$message->setFromEmail("mail@server.com");
$message->setFromName("Jhon Doe");
$message->setReplyTo("mail@server.com");
$message->setSubject("Whatever subject you want.");
$message->setRecipients(array("recipient@server.com", "another@server.com"));
$message->setTemplate("basic"); //layout must be uploaded and selected.

$newsletter->setMessage($message);
$newsletter->setItem($item);

$contee->sendNewsletter($newsletter)->toObject();

```

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/4daf43523e0a11248e5f4cad639e375907f501c08ea59d754ea5aaee1d8f416a?d=identicon)[marekgalovic](/maintainers/marekgalovic)

---

Top Contributors

[![marekgalovic](https://avatars.githubusercontent.com/u/5927660?v=4)](https://github.com/marekgalovic "marekgalovic (5 commits)")

### Embed Badge

![Health badge](/badges/contee-php-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/contee-php-sdk/health.svg)](https://phpackages.com/packages/contee-php-sdk)
```

###  Alternatives

[phootwork/lang

Missing PHP language constructs

1228.2M8](/packages/phootwork-lang)[lakm/laravel-comments

Integrate seamless commenting functionality into your Laravel project.

40715.0k1](/packages/lakm-laravel-comments)

PHPackages © 2026

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