module Pushbullet::SecretAPI
Public Instance Methods
contacts()
click to toggle source
# File lib/pushbullet/secret_api.rb, line 3 def contacts get('/v2/contacts') end
push_address_to(target_email, title, address)
click to toggle source
# File lib/pushbullet/secret_api.rb, line 15 def push_address_to(target_email, title, address) push_to :address, target_email, title: title, address: address end
push_link_to(target_email, title, url)
click to toggle source
# File lib/pushbullet/secret_api.rb, line 11 def push_link_to(target_email, title, url) push_to :link, target_email, title: title, url: url end
push_list_to(target_email, title, items)
click to toggle source
FIXME Now, can send only one item
# File lib/pushbullet/secret_api.rb, line 20 def push_list_to(target_email, title, items) push_to :list, target_email, title: title, items: items end
push_note_to(target_email, title, body)
click to toggle source
# File lib/pushbullet/secret_api.rb, line 7 def push_note_to(target_email, title, body) push_to :note, target_email, title: title, body: body end
Private Instance Methods
push_to(type, target_email, payload)
click to toggle source
# File lib/pushbullet/secret_api.rb, line 26 def push_to(type, target_email, payload) post '/api/pushes', payload.merge(target_email: target_email, type: type) end