PHPackages                             krichprollsch/truffade - 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. krichprollsch/truffade

AbandonedArchivedProject[API Development](/categories/api)

krichprollsch/truffade
======================

Programmable API mock server

0.1.3(8y ago)47191MITPHP

Since Mar 27Pushed 7y ago1 watchersCompare

[ Source](https://github.com/krichprollsch/truffade)[ Packagist](https://packagist.org/packages/krichprollsch/truffade)[ RSS](/packages/krichprollsch-truffade/feed)WikiDiscussions master Synced 4w ago

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

Truffade
========

[](#truffade)

Truffade is an API mock server. It helps you to mock the third party API.

Install
-------

[](#install)

The recommended way to install Truffade is through [Composer](http://getcomposer.org/):

```
$ composer require krichprollsch/truffade

```

Usage
-----

[](#usage)

### Start the server

[](#start-the-server)

First you need to start the server

```
php ./vendor/bin/truffade --admin-port=8081 --mock-port=8080

```

### Configure the mock responses

[](#configure-the-mock-responses)

Now you can configure any mock response you want the server returns using the admin port.

```
$ curl -XPOST http://127.0.0.1:8081 --data '{"body":{"foo":"bar"}}'
{"total":1,"next":0}

$ curl -XPOST http://127.0.0.1:8081 --data '{"body":{"foo":"baz"}}'
{"total":2,"next":0}

```

### Request the mock server

[](#request-the-mock-server)

Then you can use the mock server through you application. The responses will be return into the order of the configuration time.

```
$ curl -XGET http://127.0.0.1:8080/foo/bar
{"foo":"bar"}

$ curl -XPOST http://127.0.0.1:8080/what/you/want --data '{"foo"}'
{"foo":"baz"}

```

If there is no more responses configures, an error is returned.

```
$ curl -XPOST http://127.0.0.1:8080/yoohoo
{"err":"not configured yet"}

```

### Consult the requests

[](#consult-the-requests)

The admin server allow you to check the requests send by you application.

```
curl -XGET http://127.0.0.1:8081/0
{
    "request": {
        "body": null,
        "headers": {
            "Accept": [
                "*/*"
            ],
            "Host": [
                "127.0.0.1:8080"
            ],
            "User-Agent": [
                "curl/7.50.1"
            ]
        },
        "json": null,
        "method": "GET",
        "path": "/foo/bar",
        "query": "",
        "request": {}
    },
    "response": {
        "foo": "bar"
    }
}

```

Run test
--------

[](#run-test)

```
// TODO

```

Truffade?
---------

[](#truffade-1)

> Truffade is a rural dish traditionally associated with Auvergne in France. [see Wikipedia](https://en.wikipedia.org/wiki/Truffade)

License
-------

[](#license)

Truffade is released under the MIT License. See the bundled LICENSE file for details.

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

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

Total

3

Last Release

3245d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/03b34baa5c7073b98dbf5c67e621f8467aa6178ccb84305e9e67090391f1fd99?d=identicon)[krichprollsch](/maintainers/krichprollsch)

---

Top Contributors

[![krichprollsch](https://avatars.githubusercontent.com/u/562696?v=4)](https://github.com/krichprollsch "krichprollsch (9 commits)")[![lunika](https://avatars.githubusercontent.com/u/767834?v=4)](https://github.com/lunika "lunika (6 commits)")

### Embed Badge

![Health badge](/badges/krichprollsch-truffade/health.svg)

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

###  Alternatives

[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.5k5.8M715](/packages/sylius-sylius)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.4M526](/packages/shopware-core)[eliashaeussler/cache-warmup

Composer package to warm up website caches, based on a given XML sitemap

75419.2k9](/packages/eliashaeussler-cache-warmup)[open-dxp/opendxp

Content &amp; Product Management Framework (CMS/PIM)

9417.2k56](/packages/open-dxp-opendxp)

PHPackages © 2026

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