PHPackages                             hbsolutions/swoole-slim-app - 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. hbsolutions/swoole-slim-app

ActiveLibrary[API Development](/categories/api)

hbsolutions/swoole-slim-app
===========================

Basis for REST API application on Slim 4 and Swoole Server.

0874PHP

Since Nov 28Pushed 3y ago1 watchersCompare

[ Source](https://github.com/hbsolutions-ru/swoole-slim-app)[ Packagist](https://packagist.org/packages/hbsolutions/swoole-slim-app)[ RSS](/packages/hbsolutions-swoole-slim-app/feed)WikiDiscussions main Synced 2d ago

READMEChangelogDependenciesVersions (1)Used By (0)

swoole-slim-app
===============

[](#swoole-slim-app)

Basis for REST API application on Slim 4 and Swoole Server.

> The library is in development so interfaces may change: do not use in production!

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

[](#installation)

`composer require hbsolutions/swoole-slim-app`

Usage
-----

[](#usage)

App constructor takes the same parameters as [PHP-DI](https://php-di.org/doc/php-definitions.html)'s Container Builder method `addDefinitions`.

```
use HBS\SwooleSlimApp\App;
use Slim\App as SlimApp;
use Swoole\WebSocket\Server;

$swooleSlimApp = new App(
    'path/to/your/php-di/definitions/config.php',
    [
        'some-definitions' => 'in-array',
    ]
);

$swooleSlimApp->init(
    function (SlimApp $app) {
        // Add some Slim middleware here
    },
    function (SlimApp $app) {
        // Add some Slim routes here
    },
    [
        App::OPTION_WITH_REQUEST_LOGGER => true,
    ]
);

// Get Swoole Server and register some events if needed
$swooleServer = $swooleSlimApp->getServer();

$swooleServer->on('start', function(Server $server)
{
    echo "Swoole Server is started!\n";
});

// Start the Server
$swooleSlimApp->startServer();
```

### Demo project

[](#demo-project)

See [Demo project](https://github.com/hbsolutions-ru/swoole-slim-example) for more use cases.

###  Health Score

17

—

LowBetter than 6% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity24

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/11571133?v=4)[hbsolutions](/maintainers/hbsolutions)[@HBSolutions](https://github.com/HBSolutions)

---

Top Contributors

[![hbsolutions-ru](https://avatars.githubusercontent.com/u/77727227?v=4)](https://github.com/hbsolutions-ru "hbsolutions-ru (34 commits)")

### Embed Badge

![Health badge](/badges/hbsolutions-swoole-slim-app/health.svg)

```
[![Health](https://phpackages.com/badges/hbsolutions-swoole-slim-app/health.svg)](https://phpackages.com/packages/hbsolutions-swoole-slim-app)
```

###  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)
