frankandoak/smooch-api

Smooch API Client

v0.1.0 2016-04-29 20:21 UTC

This package is not auto-updated.

Last update: 2024-11-01 21:38:53 UTC


README

Build Status

Smooch API Client

A library to handle Smooch REST API methods conform to current spec

Installation

Use composer to manage your dependencies and download Smooch API Client:

composer require frankandoak/smooch-api

Usage

       $message = new Smooch\Model\Message([
           'text' => 'MESSAGE_CONTENT',
           'role' => 'appMaker'
       ]);

       $smoochClient = new Smooch\Client();
       $smoochClient->setCredentials('SECRET', 'KEY_ID');

       $smoochClient
           ->getAppUser('USER_ID_OR_SMOOCH_ID')
           ->conversation
           ->add($message);