PHPackages                             dutchie027/thinq - 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. dutchie027/thinq

ActiveLibrary[API Development](/categories/api)

dutchie027/thinq
================

Thinq PHP API

00[3 issues](https://github.com/dutchie027/thinq-php/issues)[3 PRs](https://github.com/dutchie027/thinq-php/pulls)PHP

Since Aug 30Pushed 3y ago1 watchersCompare

[ Source](https://github.com/dutchie027/thinq-php)[ Packagist](https://packagist.org/packages/dutchie027/thinq)[ RSS](/packages/dutchie027-thinq/feed)WikiDiscussions main Synced 6d ago

READMEChangelogDependenciesVersions (4)Used By (0)

thinq-php
=========

[](#thinq-php)

[![Latest Stable Version](https://camo.githubusercontent.com/711854f5660f994c4b7e312eb2e15da2f7e0c469d18b8735029447307ec01fe4/68747470733a2f2f706f7365722e707567782e6f72672f647574636869653032372f7468696e712f76)](//packagist.org/packages/dutchie027/thinq)[![Total Downloads](https://camo.githubusercontent.com/c0f2301c1fd9c88ad5f0d601cf4dc1c9478556dd375b475b17d9089f7c80888f/68747470733a2f2f706f7365722e707567782e6f72672f647574636869653032372f5468696e712f646f776e6c6f616473)](//packagist.org/packages/dutchie027/thinq)[![License](https://camo.githubusercontent.com/1ae279536edae194b95ebb969966c4853594c63f0b5cb71b26cfdb6bf6599edf/68747470733a2f2f706f7365722e707567782e6f72672f647574636869653032372f7468696e712f6c6963656e7365)](//packagist.org/packages/dutchie027/thinq)[![CodeFactor](https://camo.githubusercontent.com/aae4e5c4afcfe751ec8ea545737242217b00d532cb7182ef49e494809be662be/68747470733a2f2f7777772e636f6465666163746f722e696f2f7265706f7369746f72792f6769746875622f647574636869653032372f7468696e712d7068702f6261646765)](https://www.codefactor.io/repository/github/dutchie027/thinq-php)

PHP Library Intended to Interact with [Thinq's API](https://apidocs.thinq.com/)

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

[](#installation)

```
composer require dutchie027/thinq
```

Usage
-----

[](#usage)

```
// require the composer library
require_once ('vendor/autoload.php');

//make the connction to the API for use
$api = new dutchie027\Thinq\API(THINQ_USER, THINQ_TOKEN);

...
```

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

[](#requirements)

The libarary assumes you have three defined variables:

```
define ('THINQ_USER', 'myUserName');
define ('THINQ_TOKEN', '867530986753098675309');
define ('THINQ_ACCOUNT_ID', '12345678');
```

in order to work properly. `THINQ_USER` and `THINQ_TOKEN` are fed to the API as parameters for login and header information. `THINQ_ACCOUNT_ID` is used in making URLs on the back end. These constants can be defined in your script or they can be imported or included in a constant file (preferred).

General Information
-------------------

[](#general-information)

### Class Listing

[](#class-listing)

The library has the following classes:

- [API](/docs/API.md)
- [CNAM](/docs/CNAM.md)
- [Inbound](/docs/Inbound.md)
- [LRN](/docs/LRN.md)
- [Outbound](/docs/Outbound.md)
- [Text](/docs/Text.md)

Class Information
-----------------

[](#class-information)

### API

[](#api)

The main connection requires at minimum, a username and token.

Once you have a user and token, you can simply connect with it or you can add options

```
// Ensure we have the composer libraries
require_once ('vendor/autoload.php');

// Instantiate with defaults
$api = new dutchie027\Thinq\API(THINQ_USER, THINQ_TOKEN);

// Instantiate without defaults, this allows you to change things
// like log location, directory, the tag and possible future settings.
$settings = [
  'log_dir' => '/tmp',
  'log_name' => 'thinqi',
  'log_tag' => 'thinq-api',
  'log_level' => 'error'
];

$api = new dutchie027\Thinq\API(THINQ_USER, THINQ_TOKEN, $settings);
```

#### Settings

[](#settings)

The default settings are fine, however you might want to override the defaults or use your own.**NOTE: All settings are optional and you don't need to provide any**.

FieldTypeDescriptionDefault Value`log_dir`stringThe directory where the log file is stored[sys\_get\_temp\_dir()](https://www.php.net/manual/en/function.sys-get-temp-dir.php)`log_name`stringThe name of the log file that is created in `log_dir`. If you don't put .log at the end, it will append it6 random characters + [time()](https://www.php.net/manual/en/function.time.php) + .log`log_tag`stringIf you share this log file with other applications, this is the tag used in the log file`thinq``log_level`stringThe level of logging the application will do. This must be either `debug`, `info`, `notice`, `warning`, `critical` or `error`. If it is not one of those values it will fail to the default`warning`To-Do
-----

[](#to-do)

- Bring in more of the function(s) from Thinq
- Document the class(es) with proper doc blocks better
- Clean up the code a bit more
- Stuff I'm obviously missing...

Contributing
------------

[](#contributing)

If you're having problems, spot a bug, or have a feature suggestion, [file an issue](https://github.com/dutchie027/thinq-php/issues). If you want, feel free to fork the package and make a pull request. This is a work in progresss as I get more info and further test the API.

###  Health Score

15

—

LowBetter than 3% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity0

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity29

Early-stage or recently created project

 Bus Factor1

Top contributor holds 63.9% 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/6424f66fa0ca243cf585d30e65d4dbecb0272ecee4397df15b5d9a6fab448c6b?d=identicon)[dutchie027](/maintainers/dutchie027)

---

Top Contributors

[![dutchie027](https://avatars.githubusercontent.com/u/6707999?v=4)](https://github.com/dutchie027 "dutchie027 (23 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (13 commits)")

### Embed Badge

![Health badge](/badges/dutchie027-thinq/health.svg)

```
[![Health](https://phpackages.com/badges/dutchie027-thinq/health.svg)](https://phpackages.com/packages/dutchie027-thinq)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

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