Project

hoiio

0.0
No commit activity in last 3 years
No release in over 3 years
This is an SDK for Hoiio API, a set of telephony API that integrate telephony services - phone calls, conference, IVR (Interactive Voice Responses), Fax and SMS - into your services and website easily.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.3.0
~> 0.9.0
~> 2.6.0

Runtime

> 0.6.0
> 1.4.0
 Project Readme

Hoiio

This is Ruby SDK for Hoiio API

Hoiio API is set of telephony API that integrate telephony services - phone calls, conference, IVR (Interactive Voice Responses), Fax and SMS - into your services and website easily.

Read the documentation at http://hoiio.readthedocs.org/

Installation

Add this line to your application's Gemfile:

gem 'hoiio'

And then execute:

$ bundle

Or install it yourself as:

$ gem install hoiio

Getting Started With Hoiio Ruby Gem

Setup

require 'hoiio-ruby'

# Hoiio Application Credentials
app_id = ''
access_token = ''

# create a client to cache the authentication detail and talk to Hoiio RESTful API
@client = Hoiio::Client.new app_id, access_token

Usage

After a @client object has been created, app_id and access_token are cached and used for subsequent API calls. Normally, app_id won't change, but you can modify the client's access_token by reassigning it to a new one.

All API's URIs specified in Hoiio Developer's website are included in this SDK and can be accessed conveniently.

For example, @client.sms will make all SMS APIs with the same name available, i.e: @client.sms.send will call /sms/send, @client.sms.query_status will fire a request to /sms/query_status (as specified here).

Send an SMS

# send an SMS using Hoiio
@client.sms.send({
  :dest => '+6591234567',
  :msg => 'Hello Steve',
  :notify_url => 'http://dev.example.com/sms/notify'
})

Make a call

# call a destination number using Hoiio
@client.voice.call({
  :dest2 => '+6591234567',
  :caller_id => 'private'
})

API References

Visit our API site to learn more about our powerful communication API.