PHPackages                             nimiq-community/php-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. [HTTP &amp; Networking](/categories/http)
4. /
5. nimiq-community/php-client

AbandonedArchivedLibrary[HTTP &amp; Networking](/categories/http)

nimiq-community/php-client
==========================

Nimiq RPC Client for PHP

v1.0(5y ago)051MITPHPPHP &gt;=7.1CI passing

Since Jun 19Pushed 10mo agoCompare

[ Source](https://github.com/nimiq-community/php-client)[ Packagist](https://packagist.org/packages/nimiq-community/php-client)[ Docs](https://github.com/nimiq-community/php-client)[ RSS](/packages/nimiq-community-php-client/feed)WikiDiscussions master Synced 6d ago

READMEChangelog (1)Dependencies (3)Versions (2)Used By (0)

Nimiq PHP Client
================

[](#nimiq-php-client)

> PHP implementation of the Nimiq RPC client specs.

This repository is archived: Nimiq PoS has been launched and this RPC client only supports the old PoW RPC specification. As of now, there is no PHP RPC client implementation. Please [contact us](mailto:community@nimiq.com) if you are interested in implementing and supporting the Nimiq ecosystem for PHP.

Usage
-----

[](#usage)

Send requests to a Nimiq node using a `NimiqCommunity\RpcClient\NimiqClient` object.

```
$config = [
    'scheme' => 'http',
    'host' => '127.0.0.1',
    'port' => 8648,
    'user' => 'luna',
    'password' => 'moon',
    'timeout' => false,
];

$client = new \NimiqCommunity\RpcClient\NimiqClient($config);
```

Once we have the client, we can start communicating with the Nimiq node. If no `$config` object is given in constructor it will use same defaults as the Nimiq node defaults.

```
$client = new \NimiqCommunity\RpcClient\NimiqClient();

// make rpc call to get the block number
$blockNumber = $client->getBlockNumber();

echo $blockNumber; // displays the block number, for example 748883
```

API
---

[](#api)

The complete [API documentation](docs) is available in the `/docs` folder.

Check out the [Nimiq RPC specs](https://github.com/nimiq/core-js/wiki/JSON-RPC-API) for behind the scene RPC calls.

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

[](#installation)

The recommended way to install Nimiq PHP Client is with Composer. Composer is a dependency management tool for PHP that allows you to declare the dependencies your project needs and installs them into your project.

```
# Install Composer
curl -sS https://getcomposer.org/installer | php
```

You can add Nimiq PHP Client as a dependency using the composer.phar CLI:

```
php composer.phar require nimiq-community/php-client
```

Alternatively, you can specify it as a dependency in your project's existing composer.json file:

```
{
    "require": {
        "nimiq-community/php-client": "^1.0"
    }
}
```

After installing, you need to require Composer's autoloader:

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

You can find out more on how to install Composer, configure autoloading, and other best-practices for defining dependencies at [getcomposer.org](https://getcomposer.org).

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

[](#contributions)

This implementation was originally contributed by [mariofriz](https://github.com/mariofriz/).

Please send your contributions as pull requests. Refer to the [issue tracker](https://github.com/nimiq-community/php-client/issues) for ideas.

### Develop

[](#develop)

After cloning the repository, install the dependencies:

```
php composer.phar install
```

All done, happy coding!

### Testing

[](#testing)

Tests are stored in the `/tests` folder and can be run using phpunit:

```
php composer.phar run-script test
```

To run the tests and generate HTML coverage report:

```
php composer.phar run-script coverage
```

This will generate the report in `/coverage` folder. [Xdebug](https://xdebug.org/docs/install) is required to generate the coverage report.

### Documentation

[](#documentation)

The documentation in the `/docs` folder can generated from the source code:

```
php composer.phar run-script docs
```

It will generate a `README.md` in Github Markdown format.

License
-------

[](#license)

[Apache 2.0](LICENSE.md)

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance39

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

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

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2158d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1634484?v=4)[Mario](/maintainers/mariofriz)[@mariofriz](https://github.com/mariofriz)

---

Top Contributors

[![svub](https://avatars.githubusercontent.com/u/2807999?v=4)](https://github.com/svub "svub (8 commits)")[![mariofriz](https://avatars.githubusercontent.com/u/1634484?v=4)](https://github.com/mariofriz "mariofriz (5 commits)")[![jsdanielh](https://avatars.githubusercontent.com/u/2374448?v=4)](https://github.com/jsdanielh "jsdanielh (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/nimiq-community-php-client/health.svg)

```
[![Health](https://phpackages.com/badges/nimiq-community-php-client/health.svg)](https://phpackages.com/packages/nimiq-community-php-client)
```

###  Alternatives

[spatie/crawler

Crawl all internal links found on a website

2.8k16.3M52](/packages/spatie-crawler)[omniphx/forrest

A Laravel library for Salesforce

2724.4M8](/packages/omniphx-forrest)[akamai-open/edgegrid-client

Implements the Akamai {OPEN} EdgeGrid Authentication specified by https://developer.akamai.com/introduction/Client\_Auth.html

482.5M6](/packages/akamai-open-edgegrid-client)[muhammadhuzaifa/telescope-guzzle-watcher

Telescope Guzzle Watcher provide a custom watcher for intercepting http requests made via guzzlehttp/guzzle php library. The package uses the on\_stats request option for extracting the request/response data. The watcher intercept and log the request into the Laravel Telescope HTTP Client Watcher.

98239.8k1](/packages/muhammadhuzaifa-telescope-guzzle-watcher)[onesignal/onesignal-php-api

A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com

34170.2k2](/packages/onesignal-onesignal-php-api)[ory/hydra-client-php

Documentation for all of Ory Hydra's APIs.

1710.8k](/packages/ory-hydra-client-php)

PHPackages © 2026

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