PHP code example of coxlr / laravel-ringcentral

1. Go to this page and download the library: Download coxlr/laravel-ringcentral library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

coxlr / laravel-ringcentral example snippets


RingCentral::sendMessage([
    'to'   => '18042221111',
    'text' => 'Using the facade to send a message.'
]);

$ringcentral = app('ringcentral');

$ringcentral->sendMessage([
    'to'   => '18042221111',
    'text' => 'Using the instance to send a message.'
]);

RingCentral::getExtensions();

$ringcentral = app('ringcentral');

$ringcentral->getExtensions();

RingCentral::getOperatorMessages();

$ringcentral = app('ringcentral');

$ringcentral->getOperatorMessages();

RingCentral::getOperatorMessages((new \DateTime())->modify('-1 hours'));

RingCentral::getMessagesForExtensionId(12345678);

$ringcentral = app('ringcentral');

$ringcentral->getMessagesForExtensionId(12345678);

RingCentral::getMessagesForExtensionId(12345678, (new \DateTime())->modify('-1 hours'));

RingCentral::getMessageAttachmentById(12345678, 910111213, 45678910);

$ringcentral = app('ringcentral');

$ringcentral->getMessageAttachmentById(12345678, 910111213, 45678910);
bash
php artisan vendor:publish --provider="Coxlr\RingCentral\RingCentralServiceProvider" --tag="config"