PHPackages                             robertasproniu/php-json-rpc - 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. robertasproniu/php-json-rpc

ActiveLibrary[API Development](/categories/api)

robertasproniu/php-json-rpc
===========================

1.0.0(8y ago)019MITPHPPHP &gt;=5.6

Since Jul 18Pushed 8y ago1 watchersCompare

[ Source](https://github.com/robertasproniu/php-json-rpc)[ Packagist](https://packagist.org/packages/robertasproniu/php-json-rpc)[ RSS](/packages/robertasproniu-php-json-rpc/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

PHP Simple JSON-RPC 2.0 server
==============================

[](#php-simple-json-rpc-20-server)

### Installation

[](#installation)

Use [Composer](https://getcomposer.org/)

```
"require" : {
    "robertasproniu/php-json-rpc": "~1.0"
}
```

### Initialize

[](#initialize)

```
require_once 'vendor/autoload.php';

use JsonRpc\Server;

$server = new Server();
```

### Define callbacks

[](#define-callbacks)

```
$server
    ->withCallback('add', function($a, $b) {
        return $a + $b;
    })
    // OR
    ->withCallback('substract', 'className', 'methodName');
```

### Define Middlewares

[](#define-middlewares)

```
$server
    ->withMiddleware(function($request, $response) {
        // add logic here

        return true; // will invalidate middleware
    });
```

### Run server

[](#run-server)

```
$server->execute(); // return json
// OR
$server->execute($payload); // pass json payload
```

###  Health Score

25

—

LowBetter than 35% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

3270d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0a8da193a37b7b0e1493d17401c51b6fdae1e7cb27a88fcad169bb041a20a100?d=identicon)[robert.asproniu](/maintainers/robert.asproniu)

---

Top Contributors

[![robertasproniu](https://avatars.githubusercontent.com/u/12408478?v=4)](https://github.com/robertasproniu "robertasproniu (10 commits)")

### Embed Badge

![Health badge](/badges/robertasproniu-php-json-rpc/health.svg)

```
[![Health](https://phpackages.com/badges/robertasproniu-php-json-rpc/health.svg)](https://phpackages.com/packages/robertasproniu-php-json-rpc)
```

###  Alternatives

[exsyst/swagger

A php library to manipulate Swagger specifications

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

Hubspot API client

24015.5M18](/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

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

PHPackages © 2026

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