PHPackages                             list-interop/convertkit-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. list-interop/convertkit-client

ActiveLibrary[API Development](/categories/api)

list-interop/convertkit-client
==============================

An API Client for ConvertKit

0.4.0(2y ago)08.1k[9 PRs](https://github.com/list-interop/convertkit-client/pulls)MITPHPPHP ~8.1 || ~8.2CI passing

Since May 5Pushed 2mo agoCompare

[ Source](https://github.com/list-interop/convertkit-client)[ Packagist](https://packagist.org/packages/list-interop/convertkit-client)[ Docs](https://github.com/list-interop/convertkit-client)[ RSS](/packages/list-interop-convertkit-client/feed)WikiDiscussions 0.5.x Synced 1mo ago

READMEChangelog (4)Dependencies (19)Versions (18)Used By (0)

ConvertKit PHP API Client
=========================

[](#convertkit-php-api-client)

[![Build Status](https://github.com/list-interop/convertkit-client/workflows/Continuous%20Integration/badge.svg)](https://github.com/list-interop/convertkit-client/actions?query=workflow%3A%22Continuous+Integration%22)

[![codecov](https://camo.githubusercontent.com/b01f220c83fc5652966442fe65616d42c26cfe5038b87e0b659ce33402737bb9/68747470733a2f2f636f6465636f762e696f2f67682f6c6973742d696e7465726f702f636f6e766572746b69742d636c69656e742f6272616e63682f6d61696e2f67726170682f62616467652e737667)](https://codecov.io/gh/list-interop/convertkit-client)[![Psalm Type Coverage](https://camo.githubusercontent.com/93b0652cc5a8c7d5927121e4b2fd18b6690b57afce31f699616c72d6dfdf1aed/68747470733a2f2f73686570686572642e6465762f6769746875622f6c6973742d696e7465726f702f636f6e766572746b69742d636c69656e742f636f7665726167652e737667)](https://shepherd.dev/github/list-interop/convertkit-client)

[![Latest Stable Version](https://camo.githubusercontent.com/8db568a0a7d202c6c8ae6475cbf709feed8b881e6589f9e4e9c8bb3534dc02c7/68747470733a2f2f706f7365722e707567782e6f72672f6c6973742d696e7465726f702f636f6e766572746b69742d636c69656e742f762f737461626c65)](https://packagist.org/packages/list-interop/convertkit-client)[![Total Downloads](https://camo.githubusercontent.com/50569f5028fcfa2b81732e2e136e41d8ff18ba55154682c10c9a7c2f5ac5cefa/68747470733a2f2f706f7365722e707567782e6f72672f6c6973742d696e7465726f702f636f6e766572746b69742d636c69656e742f646f776e6c6f616473)](https://packagist.org/packages/list-interop/convertkit-client)

Introduction
------------

[](#introduction)

This is an API Client for the [ConvertKit](https://convertkit.com) mailing list service for PHP versions 8.0 and up

There are several clients available on Packagist, but the main motivation here is being agnostic to the HTTP client in use.

The client uses PSR17 and 18 standards, so you can bring your own preferred libs.

Implemented Features
--------------------

[](#implemented-features)

- Retrieve form by id
- Subscribe to a form *(Custom fields are not yet available)*
- List and find tags
- Create Tags
- List custom fields
- Crud for custom fields
- Fetch form subscriber
- Other Crud operations for subscribers
- Tagging subscribers post subscribe.
- Stuff regarding webhooks and purchases…

Roadmap
-------

[](#roadmap)

It'd be nice to work up the rest of the available features in the API, but it probably won't happen very quickly, I'm more likely to work on different implementations first to firm up the spec there so that stable releases can be made. Shipping a caching client using a psr cache pool would be handy for those aspects of the API that rarely change. It would also be quite trivial to implement.

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

[](#installation)

Composer is the only supported installation method…

As previously mentioned, you'll need a [PSR-18 HTTP Client](https://packagist.org/providers/psr/http-client-implementation) first and also [PSR-7 and PSR-17 implementations](https://packagist.org/providers/psr/http-factory-implementation). For example:

```
composer require php-http/curl-client
composer require laminas/laminas-diactoros
```

You'll then be able to install this with:

```
composer require list-interop/convertkit-client
```

Usage
-----

[](#usage)

Docs are admittedly thin on the ground.

The lib ships with a PSR11 factory that you can integrate with your container of choice. It falls back to discovery for whatever PSR-7/17/18 stuff that you have installed.

Ultimately, you'll need API Keys to get going, and assuming you can provide the `Client` constructor with its required constructor dependencies, you'll be able to start issuing commands and getting results:

### Add a subscriber…

[](#add-a-subscriber)

```
use ListInterop\ConvertKit\Client;
use ListInterop\ConvertKit\Exception\ApiError;
use ListInterop\ConvertKit\Exception\ConvertKitError;
use ListInterop\ConvertKit\Exception\RequestFailure;

assert($client instanceof Client);

$formId = 123; // Retrieve this from the dashboard or by inspecting the forms returned by the api.

try {
    $client->subscribeToForm($formId, 'me@example.com', 'Fred', ['tag 1', 'tag 2']);
} catch (RequestFailure $error) {
    // Network error - can't reach ConvertKit
} catch (ApiError $error) {
    // Something was wrong with the values provided, or your API key was wonky
    // i.e. The API rejected your request
} catch (ConvertKitError $error) {
    // Generic Error, Assertion failed etc.
    // All exceptions implement this interface, Providing an invalid email address will get you here.
}
```

You should find that exceptions are consistent and meaningful, but for now, to find out what those are, you'll need to look at the source.

Contributions
-------------

[](#contributions)

Are most welcome, but please make sure that pull requests include relevant tests. There's a handy composer script you can run locally:

```
composer check
```

… which will check coding standards, run psalm and phpunit in order.

License
-------

[](#license)

[MIT Licensed](LICENSE.md).

###  Health Score

39

—

LowBetter than 86% of packages

Maintenance58

Moderate activity, may be stable

Popularity18

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 69% 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 ~201 days

Recently: every ~307 days

Total

8

Last Release

61d ago

PHP version history (4 changes)0.1.0PHP ^7.3 || ~8.0 || ~8.1

0.2.0PHP ^7.4 || ~8.0 || ~8.1

0.3.0PHP ~8.0 || ~8.1 || ~8.2

0.4.0PHP ~8.1 || ~8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/7c3d0f9e99be5b2d177609f468c0455012f52740803855788b604058b1c18fb7?d=identicon)[list-interop](/maintainers/list-interop)

---

Top Contributors

[![renovate[bot]](https://avatars.githubusercontent.com/in/2740?v=4)](https://github.com/renovate[bot] "renovate[bot] (207 commits)")[![gsteel](https://avatars.githubusercontent.com/u/2803720?v=4)](https://github.com/gsteel "gsteel (78 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (15 commits)")

---

Tags

convertkitconvertkit-apiphp

###  Code Quality

TestsPHPUnit

Static AnalysisPsalm

Type Coverage Yes

### Embed Badge

![Health badge](/badges/list-interop-convertkit-client/health.svg)

```
[![Health](https://phpackages.com/badges/list-interop-convertkit-client/health.svg)](https://phpackages.com/packages/list-interop-convertkit-client)
```

###  Alternatives

[openai-php/client

OpenAI PHP is a supercharged PHP API client that allows you to interact with the Open AI API

5.8k22.6M232](/packages/openai-php-client)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[getbrevo/brevo-php

Official Brevo provided RESTFul API V3 php library

963.1M35](/packages/getbrevo-brevo-php)[swisnl/json-api-client

A PHP package for mapping remote JSON:API resources to Eloquent like models and collections.

211473.2k12](/packages/swisnl-json-api-client)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28137.8k](/packages/phpro-http-tools)[opensearch-project/opensearch-php

PHP Client for OpenSearch

15024.3M65](/packages/opensearch-project-opensearch-php)

PHPackages © 2026

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