PHPackages                             mhndev/slim-file-response - 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. mhndev/slim-file-response

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

mhndev/slim-file-response
=========================

Slim File Response

0.1.1(9y ago)122.6k2[2 issues](https://github.com/mhndev/slim-file-response/issues)[1 PRs](https://github.com/mhndev/slim-file-response/pulls)MITPHPPHP &gt;=5.5.0

Since Jun 24Pushed 5y ago1 watchersCompare

[ Source](https://github.com/mhndev/slim-file-response)[ Packagist](https://packagist.org/packages/mhndev/slim-file-response)[ RSS](/packages/mhndev-slim-file-response/feed)WikiDiscussions develop Synced 1w ago

READMEChangelogDependencies (1)Versions (4)Used By (0)

Simple Slim Framework File Response
-----------------------------------

[](#simple-slim-framework-file-response)

using this package you can simply make http file response. so what FileResponse class does is, set needed http headers for file response and also getResponse method has an optional third parameter which you can provide when you want http client save file as a name other than the name which stored on server.

Sample usage
------------

[](#sample-usage)

```
$app->get('/test/image',function($request, $response){

    $filePath = '/path/to/your/image/file';

    return mhndev\slimFileResponse\FileResponse::getResponse($response, $filePath);
});

$app->get('/test/pdf',function($request, $response){

    $filePath = '/path/to/your/pdf/file';

    return mhndev\slimFileResponse\FileResponse::getResponse($response, $filePath ,'myDocument');
});

```

###  Health Score

28

—

LowBetter than 51% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity25

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity50

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

Every ~244 days

Total

2

Last Release

3462d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5c3e5d182214e2e6b989a2230bcae80b2107b088da1c6dbea6f6f8d28702e272?d=identicon)[majidphpdeveloper](/maintainers/majidphpdeveloper)

---

Top Contributors

[![mhndev](https://avatars.githubusercontent.com/u/5164182?v=4)](https://github.com/mhndev "mhndev (6 commits)")

---

Tags

file-responsehttp-responseslimslim3httpresponseslimfiledownloadDownload filephp downloadhttp-file-response

### Embed Badge

![Health badge](/badges/mhndev-slim-file-response/health.svg)

```
[![Health](https://phpackages.com/badges/mhndev-slim-file-response/health.svg)](https://phpackages.com/packages/mhndev-slim-file-response)
```

###  Alternatives

[psr/http-message

Common interface for HTTP messages

7.0k1.1B7.9k](/packages/psr-http-message)[aplus/http

Aplus Framework HTTP Library

2401.6M10](/packages/aplus-http)[diversen/http-send-file

Sends a file to a client, with support for (multiple) range requests. It is also able to throttle the download.

57357.9k](/packages/diversen-http-send-file)[chadicus/slim-oauth2-http

Bridge components for PSR-7 and bshaffer's OAuth2 Server http messages.

18467.4k8](/packages/chadicus-slim-oauth2-http)[yiisoft/response-download

The package provides a factory to help forming file download PSR-7 response.

1110.6k](/packages/yiisoft-response-download)

PHPackages © 2026

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