PHPackages                             cobak78/rancher-api - 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. cobak78/rancher-api

ActiveLibrary[API Development](/categories/api)

cobak78/rancher-api
===================

Rancher API client

v0.1.3(9y ago)237GNUPHPPHP &gt;=7.0

Since Feb 21Pushed 8y ago1 watchersCompare

[ Source](https://github.com/cobak78/rancher-api)[ Packagist](https://packagist.org/packages/cobak78/rancher-api)[ Docs](http://github.com/cobak78/rancher-api)[ RSS](/packages/cobak78-rancher-api/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (4)Dependencies (4)Versions (6)Used By (0)

rancher-api
===========

[](#rancher-api)

[![Scrutinizer Code Quality](https://camo.githubusercontent.com/f6ad90a343312c17be71859014d6b336535eb4d80be32f88c5c3e95f143c484d/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f636f62616b37382f72616e636865722d6170692f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/cobak78/rancher-api/?branch=master)

Rancher api client with php7 and PSR7 specification, to execute bash actions on deployed containers

#### Install via composer:

[](#install-via-composer)

```
composer require cobak78/rancher-api

```

#### Docker

[](#docker)

Rancher-api includes a base image with test dependencies installed in. Use docker-compose file to stand up a fpm container with the app code mounted.

#### Usage

[](#usage)

Create an script to use api.

```
define('DOCUMENT_ROOT', dirname(__FILE__));

require_once DOCUMENT_ROOT . '/vendor/autoload.php';

use Dotenv\Dotenv;
use Cobak78\RancherApi\Clients\HttpClient;
use Cobak78\RancherApi\Clients\WSClient;
use Cobak78\RancherApi\RancherApi;

$dotenv = new Dotenv(DOCUMENT_ROOT);
$dotenv->load();

$client = new HttpClient();
$wsClient = new WSClient();

$rancherApi = new RancherApi($client, $wsClient, $argv, $argc);

$rancherApi->execute();
```

If you need to execute the same script on all deployed containers, modify script.

```
$rancherApi->execute(true);
```

this api expects at least three arguments:

1. project name
2. container name
3. command to execute
4. command parameters \[optional\]

```
php execute.php project-api fpm bin/console c:c
```

##### What it does

[](#what-it-does)

Rancher api, look for projects, service and containers deployed on rancher. If the connection need a web socket to execute bash action, retrieve token from rancher and creates a connection. Then decode and show the response on console.

###  Health Score

25

—

LowBetter than 36% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 62.5% 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 ~10 days

Total

4

Last Release

3385d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/15340473?v=4)[Jaime](/maintainers/cobak78)[@cobak78](https://github.com/cobak78)

---

Top Contributors

[![jaimeMerino](https://avatars.githubusercontent.com/u/16133214?v=4)](https://github.com/jaimeMerino "jaimeMerino (10 commits)")[![cobak78](https://avatars.githubusercontent.com/u/15340473?v=4)](https://github.com/cobak78 "cobak78 (6 commits)")

---

Tags

apiclientrancher

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/cobak78-rancher-api/health.svg)

```
[![Health](https://phpackages.com/badges/cobak78-rancher-api/health.svg)](https://phpackages.com/packages/cobak78-rancher-api)
```

###  Alternatives

[openai-php/laravel

OpenAI PHP for Laravel is a supercharged PHP API client that allows you to interact with the Open AI API

3.7k8.8M83](/packages/openai-php-laravel)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3661.2M46](/packages/tencentcloud-tencentcloud-sdk-php)[telnyx/telnyx-php

Official Telnyx PHP SDK — APIs for Voice, SMS, MMS, WhatsApp, Fax, SIP Trunking, Wireless IoT, Call Control, and more. Build global communications on Telnyx's private carrier-grade network.

35729.6k2](/packages/telnyx-telnyx-php)[resend/resend-php

Resend PHP library.

596.2M35](/packages/resend-resend-php)[mozex/anthropic-laravel

Laravel integration for the Anthropic API: facade, config publishing, install command, testing fakes, messages, streaming, tool use, thinking, and batches.

72287.1k1](/packages/mozex-anthropic-laravel)[files.com/files-php-sdk

Files.com PHP SDK

2478.1k](/packages/filescom-files-php-sdk)

PHPackages © 2026

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