PHPackages                             emilh91/groupme-api-client - 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. emilh91/groupme-api-client

ActiveLibrary[API Development](/categories/api)

emilh91/groupme-api-client
==========================

GroupMe API Client

2.1.1(2y ago)2651[1 issues](https://github.com/emilh91/groupme-api-client/issues)MITPHPPHP &gt;=5.3.0

Since Jun 5Pushed 2y agoCompare

[ Source](https://github.com/emilh91/groupme-api-client)[ Packagist](https://packagist.org/packages/emilh91/groupme-api-client)[ Docs](https://github.com/emilh91/groupme-api-client)[ RSS](/packages/emilh91-groupme-api-client/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (6)Dependencies (1)Versions (8)Used By (0)

GroupMe API Client
==================

[](#groupme-api-client)

This library is an unofficial PHP wrapper for the [GroupMe v3 API](https://dev.groupme.com/).

### Installation

[](#installation)

Install using Composer: `"emilh91/groupme-api-client": "dev-master"`

### Boilerplate

[](#boilerplate)

Your GroupMe API key can be found on the page mentioned above once you are logged in. You do not need to specify an API key if you only plan to use this library for **sending bot messages**.

```
require 'vendor/autoload.php';
$c = new GroupMeApi\Client('API-KEY');
```

### Client methods

[](#client-methods)

All the methods in the following sub-sections should be invoked on the newly created client object.

##### Bot methods

[](#bot-methods)

```
public function getMyBots()
public function createBot($bot_name, $group_id, $avatar_url='', $callback_url='')
public function sendBotMessage($bot_id, $text, array $attachments=array())
public function parseBotMessage($bot_id, $text)
public function destroyBot($bot_id)
```

##### Direct Message methods

[](#direct-message-methods)

```
public function getDirectMessageChats($page=1, $per_page=10)
public function getLatestDirectMessages($other_user_id, $limit=20)
public function getDirectMessagesBefore($other_user_id, $message_id)
public function getDirectMessagesSince($other_user_id, $message_id)
public function sendDirectMessage($other_user_id, $text, array $attachments=array(), $source_guid=null)
public function parseDirectMessage($other_user_id, $text, $source_guid=null)
public function likeDirectMessage($other_user_id, $message_id)
public function unlikeDirectMessage($other_user_id, $message_id)
```

##### Group methods

[](#group-methods)

```
public function getAllGroups()
public function getGroups($page = 1, $per_page = 10)
public function getGroupByName($name)
public function getGroupById($group_id)
public function getFormerGroups()
public function createGroup($name, $description='', $image_url='', $share=false)
public function getGroupDetails($group)
public function updateGroupDetails($group_id, array $payload)
public function destroyGroup($group_id)
public function joinGroup($group_id, $share_token)
public function rejoinGroup($group_id)
public function getLeaderboard($group_id, $period='day')
public function getLeaderboardForDay($group_id)
public function getLeaderboardForWeek($group_id)
public function getLeaderboardForMonth($group_id)
public function getMyLikes($group_id)
public function getMyHits($group_id)
public function addMembersToGroup($group_id, array $members)
public function getAddMembersToGroupResult($group_id, $results_id)
public function getGroupMembers($group_id)
public function updateMyGroupMembership($group_id, $nickname)
public function removeGroupMember($group_id, $user_id)
public function getLatestGroupMessages($group_id, $limit=20)
public function getGroupMessagesBefore($group_id, $message_id, $limit=20)
public function getGroupMessagesAfter($group_id, $message_id, $limit=20)
public function getGroupMessagesSince($group_id, $message_id, $limit=20)
public function getGroupNameById($group_id)
public function getGroupIdByName($group_name)
public function isMemberOfGroup($group_id)
public function sendGroupMessage($group_id, $text, array $attachments=array(), $source_guid=null)
public function parseGroupMessage($group_id, $text, $source_guid=null)
```

##### User methods

[](#user-methods)

```
public function getMyDetails()
public function updateMyDetails(array $payload)
public function enableSmsMode($duration, $registration_id)
public function disableSmsMode()
```

### Attachments

[](#attachments)

When sending messages (bot, direct, or group), you can specify an array of attachments. A factory class exists to easily create attachments: `GroupMeApi\AttachmentUtils`.

```
public static function makeLocationAttachment($lat, $lng, $name='')
public static function makeImageAttachment($image_url)
public static function makeMentionsAttachment($users, $strpos)
public static function makeSplitAttachment()
public static function makeEmojiAttachment(array $charmap)
```

### Emojis

[](#emojis)

Aah, the pinnacle of modern communication... To send emojis in GroupMe, you need to specify a charmap (character map) when creating the attachment. For this purpose, another factory class exists: `GroupMeApi\EmojiUtils`. To send emojis without dealing with charmaps and placeholders, just write them inline and use the `parse*Message(...)` methods to send them.

```
require 'vendor/autoload.php';
$c = new GroupMeApi\Client('API-KEY');
$c->parseBotMessage('BOT-ID', 'Awaiting instructions... :frustrated_face:');
$c->parseDirectMessage('OTHER-USER-ID', 'Hello :cool_guy_face::cigar_face:');
$c->parseGroupMessage('GROUP-ID', 'Hello everyone! :smiley_face::content_face:');
```

### Image Service

[](#image-service)

Before using local images in messages you have to upload an image to GroupMe's image service.

```
require 'vendor/autoload.php';
$c = new GroupMeApi\Client('API-KEY');
$res = $c->uploadImage('my_image_file.png', 'image/png', 'testpic');
```

If the upload was successful, the return variable contains the image url in `$res['payload']['url']` or an error message in `$res['error'][]`. Thanks to user [rgaida](https://github.com/rgaida) for fixing the image service!

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance10

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 53.3% 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 ~499 days

Recently: every ~719 days

Total

7

Last Release

1002d ago

Major Versions

0.2.0 → 1.0.02015-10-03

1.1.0 → 2.0.02015-10-08

### Community

Maintainers

![](https://www.gravatar.com/avatar/e60ad6f583fe4578d50b0b0d29a3bbdc08ff8d2e2ead68b9ba9fd03db41113d9?d=identicon)[emilh91](/maintainers/emilh91)

---

Top Contributors

[![emilh91](https://avatars.githubusercontent.com/u/5722492?v=4)](https://github.com/emilh91 "emilh91 (8 commits)")[![rgaida](https://avatars.githubusercontent.com/u/1970218?v=4)](https://github.com/rgaida "rgaida (7 commits)")

---

Tags

apiclientwrappergroupme

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/emilh91-groupme-api-client/health.svg)

```
[![Health](https://phpackages.com/badges/emilh91-groupme-api-client/health.svg)](https://phpackages.com/packages/emilh91-groupme-api-client)
```

###  Alternatives

[deepseek-php/deepseek-php-client

deepseek PHP client is a robust and community-driven PHP client library for seamless integration with the Deepseek API, offering efficient access to advanced AI and data processing capabilities.

47073.9k5](/packages/deepseek-php-deepseek-php-client)[swader/diffbot-php-client

A PHP wrapper for using Diffbot's API

5328.5k](/packages/swader-diffbot-php-client)[opensaucesystems/lxd

PHP-based API wrapper for LXD REST API.

305.8k](/packages/opensaucesystems-lxd)[dhope0000/lxd

PHP-based API wrapper for LXD REST API.

136.2k](/packages/dhope0000-lxd)

PHPackages © 2026

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