kevin-kibet / laravel-mongooseim by kevin-kibet

Mongoose API Wrapper for Laravel/lumen
33
1
2
Package Data
Maintainer Username: kevin-kibet
Maintainer Contact: kevynkybet@gmail.com (kevin-kibet)
Package Create Date: 2019-02-14
Package Last Update: 2022-10-18
Language: PHP
License: MIT
Last Refreshed: 2025-02-06 15:02:53
Package Statistics
Total Downloads: 33
Monthly Downloads: 0
Daily Downloads: 0
Total Stars: 1
Total Watchers: 2
Total Forks: 0
Total Open Issues: 0

MongooseIm Admin API wrapper for Laravel/Lumen 5.*

MongooseIm Admin API

Installation

composer require kevin-kibet/laravel-mongooseim

Configuration

You can publish the configuration file using this command

$ php artisan vendor:publish --provider="MongooseIm\Providers\MongooseImServiceProvider"

Sample configuration

<?php
return [
    'api' => env('MONGOOSE_IM_API', 'http://conversations.im:8088/api'),
    'domain' => env('MONGOOSE_IM_DOMAIN', 'conversations.im'),
    'muc_domain' => env('MONGOOSE_IM_MUC_DOMAIN', 'muc.conversations.im'),
    'muc_light_domain' => env('MONGOOSE_IM_MUC_LIGHT_DOMAIN', 'muclight.conversations.im'),
    'debug' => env('MONGOOSE_IM_DEBUG', true)
];

Laravel

Register the service provider: In your config/app.php

'providers' => [
    // Other Service Providers

    MongooseIm\Providers\MongooseImServiceProvider::class
],

Lumen

To load the configuration, in your bootstrap/app.php

$app->configure('mongoose-im')

Register the service provider

$app->register(MongooseIm\Providers\MongooseImServiceProvider::class);

Examples

Send message

Send message to a user or room

$send_message = new SendMessage($to, $from, $body);
$response = MongooseImFacade::execute($send_message);

Others

Coming soon