PHPackages                             cjrasmussen/mastodon-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. cjrasmussen/mastodon-api

ActiveLibrary[API Development](/categories/api)

cjrasmussen/mastodon-api
========================

Simple helper for interacting with Mastodon's API

1.2.2(1y ago)01161MITPHPPHP &gt;=7.4.0

Since Nov 8Pushed 1y ago1 watchersCompare

[ Source](https://github.com/cjrasmussen/MastodonApi)[ Packagist](https://packagist.org/packages/cjrasmussen/mastodon-api)[ Docs](https://cjr.dev)[ RSS](/packages/cjrasmussen-mastodon-api/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (9)Used By (1)

MastodonApi
===========

[](#mastodonapi)

Simple class for making requests to the Mastodon API.

Usage
-----

[](#usage)

```
use cjrasmussen\MastodonApi\MastodonApi;

$mastodon = new MastodonApi($server);

// SEND A TOOT WITH BEARER TOKEN
$mastodon->setBearerToken($bearer_token);
$response = $mastodon->request('POST', 'v1/statuses', ['status' => 'Toot text']);
```

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

[](#installation)

Simply add a dependency on cjrasmussen/mastodon-api to your composer.json file if you use [Composer](https://getcomposer.org/) to manage the dependencies of your project:

```
composer require cjrasmussen/mastodon-api
```

Although it's recommended to use Composer, you can actually include the file(s) any way you want.

License
-------

[](#license)

MastodonApi is [MIT](http://opensource.org/licenses/MIT) licensed.

###  Health Score

29

—

LowBetter than 60% of packages

Maintenance36

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity51

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

Recently: every ~108 days

Total

8

Last Release

588d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0225f44837a665c8a143afa50a34a406a769c523dba31e4cdf73fd0530dede45?d=identicon)[cjrasmussen](/maintainers/cjrasmussen)

---

Top Contributors

[![cjrasmussen](https://avatars.githubusercontent.com/u/15007730?v=4)](https://github.com/cjrasmussen "cjrasmussen (14 commits)")

---

Tags

mastodon

### Embed Badge

![Health badge](/badges/cjrasmussen-mastodon-api/health.svg)

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

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M475](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M270](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M452](/packages/google-gax)

PHPackages © 2026

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