PHPackages                             siujyu/nsqclient - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. siujyu/nsqclient

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

siujyu/nsqclient
================

Yet another NSQ library.

1.0(6mo ago)011MITPHPPHP &gt;=7.1

Since Oct 23Pushed 6mo agoCompare

[ Source](https://github.com/allen1706/nsqclient)[ Packagist](https://packagist.org/packages/siujyu/nsqclient)[ RSS](/packages/siujyu-nsqclient/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (2)Used By (1)

NSQClient
=========

[](#nsqclient)

Yet another PHP client for [NSQ](http://nsq.io)

### Installation (via composer)

[](#installation-via-composer)

```
composer require moolex/nsqclient dev-master

```

### Usage

[](#usage)

#### Publish

[](#publish)

```
$topic = 'my_topic';
$endpoint = new \NSQClient\Access\Endpoint('http://127.0.0.1:4161');
$message = new \NSQClient\Message\Message('hello world');
$result = \NSQClient\Queue::publish($endpoint, $topic, $message);
```

#### Publish (deferred)

[](#publish-deferred)

```
$topic = 'my_topic';
$endpoint = new \NSQClient\Access\Endpoint('http://127.0.0.1:4161');
$message = (new \NSQClient\Message\Message('hello world'))->deferred(5);
$result = \NSQClient\Queue::publish($endpoint, $topic, $message);
```

#### Publish (batch)

[](#publish-batch)

```
$topic = 'my_topic';
$endpoint = new \NSQClient\Access\Endpoint('http://127.0.0.1:4161');
$message = \NSQClient\Message\Bag::generate(['msg data 1', 'msg data 2']);
$result = \NSQClient\Queue::publish($endpoint, $topic, $message);
```

#### Subscribe

[](#subscribe)

```
$topic = 'my_topic';
$channel = 'my_channel';
$endpoint = new \NSQClient\Access\Endpoint('http://127.0.0.1:4161');
\NSQClient\Queue::subscribe($endpoint, $topic, $channel, function (\NSQClient\Contract\Message $message) {
    echo 'GOT ', $message->id(), "\n";
    // make done
    $message->done();
    // make retry immediately
    // $message->retry();
    // make retry delayed in 10 seconds
    // $message->delay(10);
});
```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance66

Regular maintenance activity

Popularity1

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity30

Early-stage or recently created project

 Bus Factor1

Top contributor holds 68% 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

208d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ee7389b103d060e7e9b038880b00e863906064bd114f287b784b197307c751ee?d=identicon)[allen1706](/maintainers/allen1706)

---

Top Contributors

[![moolex](https://avatars.githubusercontent.com/u/1132321?v=4)](https://github.com/moolex "moolex (17 commits)")[![wanganfu](https://avatars.githubusercontent.com/u/12389683?v=4)](https://github.com/wanganfu "wanganfu (5 commits)")[![allen1706](https://avatars.githubusercontent.com/u/34757825?v=4)](https://github.com/allen1706 "allen1706 (1 commits)")[![xiezhenye](https://avatars.githubusercontent.com/u/2225688?v=4)](https://github.com/xiezhenye "xiezhenye (1 commits)")[![xxvholic](https://avatars.githubusercontent.com/u/5485134?v=4)](https://github.com/xxvholic "xxvholic (1 commits)")

---

Tags

nsq

### Embed Badge

![Health badge](/badges/siujyu-nsqclient/health.svg)

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

###  Alternatives

[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

728272.9k20](/packages/civicrm-civicrm-core)[j0k3r/php-readability

Automatic article extraction from HTML

186808.8k6](/packages/j0k3r-php-readability)[moolex/nsqclient

2230.1k1](/packages/moolex-nsqclient)[spomky-labs/pwa-bundle

Progressive Web App Manifest Generator Bundle for Symfony.

6144.4k1](/packages/spomky-labs-pwa-bundle)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)[llm/mcp-server

PHP SDK for building MCP servers

431.1k](/packages/llm-mcp-server)

PHPackages © 2026

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