PHPackages                             yesllc/dadjokes - 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. yesllc/dadjokes

ActiveLibrary[API Development](/categories/api)

yesllc/dadjokes
===============

Dad jokes microservice used for testing of Kubernetes, Kong, Istio, Kuma, Nginx, Apigee, Mulesoft, etc

20250316(1y ago)109621[3 issues](https://github.com/yesinteractive/dadjokes/issues)[1 PRs](https://github.com/yesinteractive/dadjokes/pulls)MITPHPPHP &gt;=8.0

Since Jan 15Pushed 1y ago6 watchersCompare

[ Source](https://github.com/yesinteractive/dadjokes)[ Packagist](https://packagist.org/packages/yesllc/dadjokes)[ Docs](https://github.com/yesinteractive/dadjokes)[ RSS](/packages/yesllc-dadjokes/feed)WikiDiscussions master Synced 5d ago

READMEChangelog (10)DependenciesVersions (14)Used By (0)

Dad Jokes Microservice
======================

[](#dad-jokes-microservice)

[![Dad Jokes As A Microservice](https://raw.githubusercontent.com/yesinteractive/dad-jokes_microservice/master/public/dadjokes-microservice.png)](https://raw.githubusercontent.com/yesinteractive/dad-jokes_microservice/master/public/dadjokes-microservice.png)

[![Docker Pulls](https://camo.githubusercontent.com/f6e23ae15d1c07bc8a97b725151d9ce662314efe66234bf8c5d4799406861f57/68747470733a2f2f696d672e736869656c64732e696f2f646f636b65722f70756c6c732f796573696e7465726163746976652f6461646a6f6b65733f7374796c653d666f722d7468652d6261646765)](https://hub.docker.com/r/yesinteractive/dadjokes)[![GitHub stars](https://camo.githubusercontent.com/ffee5d1e127395e1b1de618e5dfd42253a279047e0776e475d0493905ccd1c7e/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f796573696e7465726163746976652f6461646a6f6b65733f7374796c653d666f722d7468652d6261646765)](https://github.com/yesinteractive/dad-jokes_microservice)[![GitHub release](https://camo.githubusercontent.com/4852e68a8f06f5162547bf9ba4acf33151c37f825c146d60cda2802c287bb7f8/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f796573696e7465726163746976652f6461646a6f6b65733f7374796c653d666f722d7468652d6261646765)](https://github.com/yesinteractive/dad-jokes_microservice)[![MIT](https://camo.githubusercontent.com/daa52099573be5a50c320c4387496400f2f722e49f86a42db8d5778130d3582d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d677265656e3f7374796c653d666f722d7468652d6261646765)](https://camo.githubusercontent.com/daa52099573be5a50c320c4387496400f2f722e49f86a42db8d5778130d3582d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d677265656e3f7374796c653d666f722d7468652d6261646765)

Just a sample humurous microservice or echo service used for testing API Gateways such as Kong, Kubernetes K8s, Openshift, Docker, Service meshes such as Kuma or Istio, etc. as an alternative to httpbin. Feel free to [add your own jokes](https://github.com/yesinteractive/dadjokes/blob/master/controllers/jokes.txt)to this repo as well. In addition to a dad joke, the service will optionally echo back information about the incoming request. This is helpful for testing and troubleshooting things like API gateways or proxies. See below for instructions on how to enable echoing per request or by default.

Hosted Service / Demo
---------------------

[](#hosted-service--demo)

Access  to see the service in action.

Usage
-----

[](#usage)

**Endpoint URI** : `/`

**Method** : `GET` `POST` `PUT` `PATCH` `DELETE`

**Parameters** : optional

**Successful Response** : `200 OK`

```
{
  "Joke": {
    "Opener": "What did one wall say to the other wall?",
    "Punchline": "I'll meet you at the corner.",
    "Processing Time": "0.000537"
  },
  "DadJokesInfo": {
    "SourceCode": "https://github.com/yesinteractive/dadjokes",
    "Version": "20250315"
  }
}
```

### ENABLING THE ECHO FEATURE

[](#enabling-the-echo-feature)

To enable the echoing of in the incoming request back into the response, simply add the docker environment variable `DADJOKES_NOECHO=FALSE` to your configuration or simply use the `/echo` anywhere in your request calls or as part of a query string. For example:

**Endpoint URI** : `/echo/abc/efg/`

**Method** : `GET` `POST` `PUT` `PATCH` `DELETE`

**Parameters** : optional

**Successful Response** : `200 OK`

```
{
  "Joke": {
    "Opener": "What do you call a deer with no eyes?",
    "Punchline": "No idea!",
    "Processing Time": "0.000434"
  },
  "RequestEcho": {
    "Headers": {
      "Host": "somehost.com",
      "Connection": "keep-alive",
      "sec-ch-ua": "\"Chromium\";v=\"134\", \"Not:A-Brand\";v=\"24\", \"Google Chrome\";v=\"134\"",
      "sec-ch-ua-mobile": "?0",
      "sec-ch-ua-platform": "\"Windows\"",
      "DNT": "1",
      "Upgrade-Insecure-Requests": "1",
      "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36",
      "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7",
      "Accept-Encoding": "gzip, deflate, br, zstd",
      "Accept-Language": "en-US,en;q=0.9",
      "Cookie": "mycooking=myvalue;"
    },
    "Method": "GET",
    "Origin": "123.45.67.123",
    "URI": "/echo/abc/efg/",
    "Arguments": {
      "uri": "/echo/abc/efg/"
    },
    "Data": "",
    "URL": "https://somehost.com/echo/abc/efg/"
  },
  "DadJokesInfo": {
    "SourceCode": "https://github.com/yesinteractive/dadjokes",
    "Version": "20250315"
  }
}
```

### BEHIND REVERSE PROXY CONFIGURATION

[](#behind-reverse-proxy-configuration)

If behind an API gateway or reverse proxy, you may wish to have only the URI of the original request echoed back and not the URI of the upstream proxy target. To do this you may add the docker environment variable `DADJOKES_BEHIND_PROXY=TRUE` to your configuration or set the global `behind_proxy`configuration to true in the `config/fsl_config.php` file.

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

[](#installation)

### Deployment Examples

[](#deployment-examples)

See usage examples for Kubernetes, Kong for Kubernetes Ingress Controller, and docker-compose in the [examples directory folder.](https://github.com/yesinteractive/dad-jokes_microservice/blob/master/examples)

### With Docker

[](#with-docker)

Docker image is Alpine 3.11 based running PHP 7.3 on Apache. The containter exposes both ports 8100 (HTTP) an 8143 (HTTPS) with a self signed certificated. If you wish to alter the container configuration, feel free to use the Dockerfile in this repo ([https://github.com/yesinteractive/dad-jokes\_microservice/blob/master/Dockerfile](https://github.com/yesinteractive/dad-jokes_microservice/blob/master/Dockerfile)). Otherwise, you can pull the latest image from DockerHub with the following command:

```
docker pull yesinteractive/dadjokes

```

Typical basic usage (below example exposes dadjokes on host ports 8100 and 8143 and enables auto echo of request data):

```
$ docker run -d \
  -p 8100:8100 \
  -p 8143:8143 \
  -e DADJOKES_NOECHO=FALSE \
  yesinteractive/dadjokes

```

Typical usage in Dockerfile:

```
FROM yesinteractive/dadjokes
RUN echo

```

###  Health Score

40

—

FairBetter than 88% of packages

Maintenance44

Moderate activity, may be stable

Popularity21

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity69

Established project with proven stability

 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 ~157 days

Recently: every ~418 days

Total

13

Last Release

426d ago

PHP version history (2 changes)1.0PHP &gt;=5.5

20250316PHP &gt;=8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/7b7ff8ff590c395ca314b2353e1749eb5f78c99b66bb35912f5309a25176c9d7?d=identicon)[yesinteractive](/maintainers/yesinteractive)

---

Top Contributors

[![cybrrnick](https://avatars.githubusercontent.com/u/35073914?v=4)](https://github.com/cybrrnick "cybrrnick (82 commits)")

---

Tags

apiapi-gatewayapigeedad-jokesdevdevopsdockerecho-serverhttpbinistiojokesk8skongkuberneteskubernetes-deploymentkumamicroservicemulesoftphpservice-meshphpapimicrorouterdockermicroservicesfunhumorkubernetesservice meshistiokumadadjokes

### Embed Badge

![Health badge](/badges/yesllc-dadjokes/health.svg)

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

###  Alternatives

[renoki-co/php-k8s

Control your Kubernetes clusters with this PHP-based Kubernetes client. It supports any form of authentication, the exec API, and it has an easy implementation for CRDs.

321669.7k2](/packages/renoki-co-php-k8s)[kubernetes/php-client

Full Kubernetes API client

6097.5k2](/packages/kubernetes-php-client)

PHPackages © 2026

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