Module: Tumblr::User
- Included in:
- Client
- Defined in:
- lib/tumblr/user.rb
Instance Method Summary collapse
- #dashboard(options = {}) ⇒ Object
- #follow(url) ⇒ Object
- #following(options = {}) ⇒ Object
- #info ⇒ Object
- #like(id, reblog_key) ⇒ Object
- #likes(options = {}) ⇒ Object
- #unfollow(url) ⇒ Object
- #unlike(id, reblog_key) ⇒ Object
Instance Method Details
#dashboard(options = {}) ⇒ Object
8 9 10 11 12 |
# File 'lib/tumblr/user.rb', line 8 def dashboard( = {}) valid_opts = [:limit, :offset, :type, :since_id, :reblog_info, :notes_info] (valid_opts, ) get('v2/user/dashboard', ) end |
#follow(url) ⇒ Object
24 25 26 |
# File 'lib/tumblr/user.rb', line 24 def follow(url) post('v2/user/follow', :url => url) end |
#following(options = {}) ⇒ Object
19 20 21 22 |
# File 'lib/tumblr/user.rb', line 19 def following( = {}) ([:limit, :offset], ) get('v2/user/following', ) end |
#info ⇒ Object
4 5 6 |
# File 'lib/tumblr/user.rb', line 4 def info get('v2/user/info') end |
#like(id, reblog_key) ⇒ Object
32 33 34 |
# File 'lib/tumblr/user.rb', line 32 def like(id, reblog_key) post('v2/user/like', :id => id, :reblog_key => reblog_key) end |
#likes(options = {}) ⇒ Object
14 15 16 17 |
# File 'lib/tumblr/user.rb', line 14 def likes( = {}) ([:limit, :offset], ) get('v2/user/likes', ) end |
#unfollow(url) ⇒ Object
28 29 30 |
# File 'lib/tumblr/user.rb', line 28 def unfollow(url) post('v2/user/unfollow', :url => url) end |
#unlike(id, reblog_key) ⇒ Object
36 37 38 |
# File 'lib/tumblr/user.rb', line 36 def unlike(id, reblog_key) post('v2/user/unlike', :id => id, :reblog_key => reblog_key) end |