-
Notifications
You must be signed in to change notification settings - Fork 0
APIs
brandon-dacrib edited this page Jul 29, 2013
·
12 revisions
The /say API basically takes a text input, and says it audibly by using the google translate api. sample usage:
ruby
require 'net/http'
result = Net::HTTP.get(URI.parse('http://yourserver:4567'), '/say/hello%20world')bash
curl http://yourserver:4567/say/hello%20worldpython
import httplib2
resp, content = httplib2.Http().request("http://yourserver:4567/say/hello%20world")All of the actions that make a change in the physical world such as toggling a light or switch are listed under the do API. More documentation on supported devices and calls to come.
status curl http://yourserver:4567/do/nodeid/status
on "wget -O /dev/null http://yourserver:4567/do/nodeid/1"
off "wget -O /dev/null http://yourserver:4567/do/nodeid/0"Send notifications via any of the supported methods below.
- sms
- growl
You must configure the following directives in your cloverleaf.conf
- from_email
- google_voice_user
- google_voice_pass