PHPackages                             ninjacto/ortc-php - 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. ninjacto/ortc-php

ActiveLibrary[API Development](/categories/api)

ninjacto/ortc-php
=================

PHP SDK wrapper for ORTC (Realtime pub/sub framework from RealTime.co)

06HTML

Since Nov 12Pushed 9y ago3 watchersCompare

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

READMEChangelogDependenciesVersions (2)Used By (0)

ORTC-PHP
========

[](#ortc-php)

[![Latest Version on Packagist](https://camo.githubusercontent.com/faf58ca5c3acb16478f285586e0c09e8b8c639383f06c31dd0d719327777ff21/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6e696e6a6163746f2f6f7274632d7068702e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/ninjacto/ortc-php)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/1a1bf1d603e50f7ad36a0dbc7f6afebbf0c93d6ced72da5a89f5d0b793a37020/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6e696e6a6163746f2f6f7274632d7068702f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/ninjacto/ortc-php)[![Coverage Status](https://camo.githubusercontent.com/e5af6f4cba4d2044ad52ff8d5625202c5205ac541ddb2e3adafd2da8d3f8a751/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f6e696e6a6163746f2f6f7274632d7068702e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/ninjacto/ortc-php/code-structure)[![Quality Score](https://camo.githubusercontent.com/a5013a5198e3380cae366e8231c31209de5d9ea11f1abc0578b62ae3eaf1182e/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f6e696e6a6163746f2f6f7274632d7068702e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/ninjacto/ortc-php)[![Total Downloads](https://camo.githubusercontent.com/e56df0f839be686fe4daa143f36a3db02ac46822029f9675f0b8303d56ed24a7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6e696e6a6163746f2f6f7274632d7068702e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/ninjacto/ortc-php)

A modern PHP client for ORTC (Open Real-Time Connectivity, realtime &amp; cloud-based pub/sub framework from realtime.co for PHP 5.5+).

Install
-------

[](#install)

Via Composer

```
$ composer require ninjacto/ortc-php
```

Usage
-----

[](#usage)

```
$ortcConfig = new OrtcConfig();
$ortcConfig->setApplicationKey('YOUR_APPLICATION_KEY');
$ortcConfig->setPrivateKey('YOUR_PRIVATE_KEY');
$ortcConfig->setVerifySsl(false);
$url = 'http://ortc-developers.realtime.co/server/2.1'; // ORTC server URL
$authToken = 'YOUR_AUTHENTICATION_TOKEN';
$channels = [];
$testChannel = new Channel();
$testChannel->setName('CHANNEL_NAME');
$testChannel->setPermission(Channel::PERMISSION_READ);
$channels[] = $testChannel;
$ortc = new Ortc($ortcConfig);
$authRequest = new AuthRequest();
$authRequest->setAuthToken($authToken);
$authRequest->setExpireTime(61);
$authRequest->setPrivate(true);
$authRequest->setChannels($channels);
$authResponse = $ortc->authenticate($authRequest);
```

Change log
----------

[](#change-log)

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

Testing
-------

[](#testing)

```
$ composer test
```

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

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) and [CONDUCT](CONDUCT.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Ramin Farmani](https://github.com/ninjacto)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 97.1% 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/c52a0ea2a11e9895de9fd3cafa31e78eea938fb2038e4e0080e63b12ef538eee?d=identicon)[farmani](/maintainers/farmani)

---

Top Contributors

[![farmani](https://avatars.githubusercontent.com/u/1329580?v=4)](https://github.com/farmani "farmani (33 commits)")[![scrutinizer-auto-fixer](https://avatars.githubusercontent.com/u/6253494?v=4)](https://github.com/scrutinizer-auto-fixer "scrutinizer-auto-fixer (1 commits)")

### Embed Badge

![Health badge](/badges/ninjacto-ortc-php/health.svg)

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

###  Alternatives

[exsyst/swagger

A php library to manipulate Swagger specifications

35916.4M7](/packages/exsyst-swagger)[hubspot/api-client

Hubspot API client

24016.2M18](/packages/hubspot-api-client)[pocketmine/bedrock-protocol

An implementation of the Minecraft: Bedrock Edition protocol in PHP

172437.8k11](/packages/pocketmine-bedrock-protocol)[botman/driver-telegram

Telegram driver for BotMan

93459.5k6](/packages/botman-driver-telegram)

PHPackages © 2026

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