PHPackages                             aubruz/mainframe-bot-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. aubruz/mainframe-bot-api

ActiveLibrary[API Development](/categories/api)

aubruz/mainframe-bot-api
========================

API to communicate with the mainframe bot api easily

v1.0.7(8y ago)0144MITPHPPHP &gt;=5.6

Since Aug 22Pushed 8y ago1 watchersCompare

[ Source](https://github.com/aubruz/mainframe-bot-api-php)[ Packagist](https://packagist.org/packages/aubruz/mainframe-bot-api)[ Docs](https://github.com/aubruz/mainframe-bot-api)[ RSS](/packages/aubruz-mainframe-bot-api/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (10)Dependencies (1)Versions (27)Used By (0)

[![Latest Stable Version](https://camo.githubusercontent.com/2a816f3ec5d66230ec4839ca8317d5a49555b400fccbb7cca632c40e7a0d328d/68747470733a2f2f706f7365722e707567782e6f72672f61756272757a2f6d61696e6672616d652d626f742d6170692f762f737461626c65)](https://packagist.org/packages/aubruz/mainframe-bot-api)[![Total Downloads](https://camo.githubusercontent.com/e2bba2fa5cefbfb6c48d7b59e372f670876d773ef5b100f0052a15fb3679e369/68747470733a2f2f706f7365722e707567782e6f72672f61756272757a2f6d61696e6672616d652d626f742d6170692f646f776e6c6f616473)](https://packagist.org/packages/aubruz/mainframe-bot-api)[![Latest Unstable Version](https://camo.githubusercontent.com/5e4cf7a8156622575e1319a42e5199abf6e3910548759ff571041870ee03e66a/68747470733a2f2f706f7365722e707567782e6f72672f61756272757a2f6d61696e6672616d652d626f742d6170692f762f756e737461626c65)](https://packagist.org/packages/aubruz/mainframe-bot-api)[![License](https://camo.githubusercontent.com/6668a495b0a234e3c592c911bf8dafecc71fddf70635e6d438e1fa03eaec4689/68747470733a2f2f706f7365722e707567782e6f72672f61756272757a2f6d61696e6672616d652d626f742d6170692f6c6963656e7365)](https://packagist.org/packages/aubruz/mainframe-bot-api)

mainframe-bot-api
=================

[](#mainframe-bot-api)

A package to use the mainframe bot api easily

You can find the documentation of the mainframe API [here](http://developer.mainframe.com/?http#mainframe-server-api).

If you find any bug or problem feel free to fork the project and make a PR. Or you can write me an email to .

How to install it
-----------------

[](#how-to-install-it)

With composer: `composer require aubruz/mainframe-bot-api`Add `use Aubruz\Mainframe\MainframeClient;` in your project.

How to use it
-------------

[](#how-to-use-it)

### Create client

[](#create-client)

```
$mainframeClient = new MainframeClient($botSecret);

```

You can specify the API url if you want to use another one. The default one is "".

```
$mainframeClient = new MainframeClient($botSecret, 'https://api-staging.mainframe.com/bots/v1/');

```

### Send message

[](#send-message)

```
$mainframeClient->sendMessage($conversationID, 'Hello World!!');

```

### Setup subscription

[](#setup-subscription)

```
$mainframeClient->setupSubscription($subscriptionToken, $label);

```

### Edit subscription

[](#edit-subscription)

```
$mainframeClient->editSubscription($subscriptionToken, $label);

```

### Delete subscription

[](#delete-subscription)

```
$mainframeClient->deleteSubscription($conversationID, $subscriptionID);

```

You can add an optional message to post to the conversation (to explain the reason for removal)

```
$mainframeClient->deleteSubscription($conversationID, $subscriptionID, $message);

```

Response
--------

[](#response)

The mainframe-bot-api package uses guzzlehttp/guzzle to perform the requests. Each call returns a response object from that library. You can find the documentation [here](http://docs.guzzlephp.org/en/stable/quickstart.html#using-responses).

```
$response = mainframeClient->setupSubscription($subscriptionToken, $label);
$response = json_decode($response->getBody());
if($response->getStatusCode() === 200 && $response->success){
    // Do something
}

```

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity68

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

Total

26

Last Release

3215d ago

Major Versions

v0.5.8 → v1.0.02017-09-06

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/12184920?v=4)[Jack Wire](/maintainers/aubruz)[@aubruz](https://github.com/aubruz)

---

Top Contributors

[![aubruz](https://avatars.githubusercontent.com/u/12184920?v=4)](https://github.com/aubruz "aubruz (1 commits)")

---

Tags

apibotmainframe

### Embed Badge

![Health badge](/badges/aubruz-mainframe-bot-api/health.svg)

```
[![Health](https://phpackages.com/badges/aubruz-mainframe-bot-api/health.svg)](https://phpackages.com/packages/aubruz-mainframe-bot-api)
```

###  Alternatives

[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M46](/packages/tencentcloud-tencentcloud-sdk-php)[resend/resend-php

Resend PHP library.

617.2M37](/packages/resend-resend-php)[checkout/checkout-sdk-php

Checkout.com SDK for PHP

563.6M12](/packages/checkout-checkout-sdk-php)[files.com/files-php-sdk

Files.com PHP SDK

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

Wildberries OpenAPI clients (generated).

252.5k](/packages/eslazarev-wildberries-sdk)[bushlanov-dev/max-bot-api-client-php

Max Bot API Client library

464.7k](/packages/bushlanov-dev-max-bot-api-client-php)

PHPackages © 2026

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