Skip to content

z3ppelin/ymclient

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ymclient v1.0

###A PHP client for Yahoo! Messenger API
Build Status Coverage Status

Features

  • login
  • logout
  • avatar retreival
  • groups with contacts list retrieval
  • notifications retrieval (messages, buddy requests...)
  • messages sending
  • authorizing buddies
  • checking yahoo session & keeping it alive

Installation

  1. Using Composer

Add the following to your composer.json file located in the root directory of your project.

{
       "require": {
           "bogcon/ymclient": "1.0"
       }
}

Then you can run the Composer install/update command from the directory containing the composer.json file

# download composer (skip the next command if you already have composer)
$ curl -sS https://getcomposer.org/installer | php

# install dependencies
$ php composer.phar install
$ php composer.phar update
  1. Using GIT
git clone https://github.com/z3ppelin/ymclient.git
  1. Download the ZIP archive from here here

Usage

try {
    // initialize client
    $objYMClient = new \bogcon\ymclient\Engine('myYahooUsername', 'myYahooPass', 'app_key', 'app_secret');
    // send a quick message to a friend
    $objYMClient->logIn(\bogcon\ymclient\Engine::USER_IS_OFFLINE) // login as Invisible
        ->sendMessage('Hello...Just entered to remind you about our meeting from tomorrow. Bye, see ya.', 'myBuddyId')
        ->logOut();
    echo 'Successfully transmitted message to my friend.';
} catch (\bogcon\ymclient\Exception $objEx) {
    echo 'Something went bad: ' . $objEx->getMessage();
}

Yahoo API documentation

http://developer.yahoo.com/messenger/guide/ch02.html

License

ymclient is released under the BSD 3-Clause License. You can find a copy of this license in LICENSE.txt.

About

A PHP client for Yahoo! Messenger API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages