Module: Pinterest::Client::User
- Included in:
- Pinterest::Client
- Defined in:
- lib/pinterest/client/user.rb
Instance Method Summary collapse
- #follow_board(board_id) ⇒ Object
- #follow_interest(interest_id) ⇒ Object
- #follow_user(user) ⇒ Object
- #get_boards(options = {}) ⇒ Object
- #get_followed_boards(options = {}) ⇒ Object
- #get_followed_interests(options = {}) ⇒ Object
- #get_followed_users(options = {}) ⇒ Object
- #get_followers(options = {}) ⇒ Object
- #get_likes(options = {}) ⇒ Object
- #get_pins(options = {}) ⇒ Object
- #get_user(user, options = {}) ⇒ Object
- #me(options = {}) ⇒ Object
- #unfollow_board(board_id) ⇒ Object
- #unfollow_interest(interest_id) ⇒ Object
- #unfollow_user(user) ⇒ Object
Instance Method Details
#follow_board(board_id) ⇒ Object
41 42 43 |
# File 'lib/pinterest/client/user.rb', line 41 def follow_board(board_id) post('me/following/boards', board: board_id) end |
#follow_interest(interest_id) ⇒ Object
49 50 51 |
# File 'lib/pinterest/client/user.rb', line 49 def follow_interest(interest_id) post('me/following/interests', interest: interest_id) end |
#follow_user(user) ⇒ Object
33 34 35 |
# File 'lib/pinterest/client/user.rb', line 33 def follow_user(user) post('me/following/users', user: user) end |
#get_boards(options = {}) ⇒ Object
17 18 19 |
# File 'lib/pinterest/client/user.rb', line 17 def get_boards(={}) get("me/boards", ) end |
#get_followed_boards(options = {}) ⇒ Object
21 22 23 |
# File 'lib/pinterest/client/user.rb', line 21 def get_followed_boards(={}) get("me/following/boards", ) end |
#get_followed_interests(options = {}) ⇒ Object
29 30 31 |
# File 'lib/pinterest/client/user.rb', line 29 def get_followed_interests(={}) get("me/following/interests", ) end |
#get_followed_users(options = {}) ⇒ Object
25 26 27 |
# File 'lib/pinterest/client/user.rb', line 25 def get_followed_users(={}) get("me/following/users", ) end |
#get_followers(options = {}) ⇒ Object
9 10 11 |
# File 'lib/pinterest/client/user.rb', line 9 def get_followers(={}) get("me/followers", ) end |
#get_likes(options = {}) ⇒ Object
13 14 15 |
# File 'lib/pinterest/client/user.rb', line 13 def get_likes(={}) get("me/likes", ) end |
#get_pins(options = {}) ⇒ Object
57 58 59 60 |
# File 'lib/pinterest/client/user.rb', line 57 def get_pins(={}) [:query] ||= '*' get('me/search/pins', ) end |
#get_user(user, options = {}) ⇒ Object
67 68 69 |
# File 'lib/pinterest/client/user.rb', line 67 def get_user(user, ={}) get("users/#{user}", ) end |
#me(options = {}) ⇒ Object
5 6 7 |
# File 'lib/pinterest/client/user.rb', line 5 def me(={}) get('me', ) end |
#unfollow_board(board_id) ⇒ Object
45 46 47 |
# File 'lib/pinterest/client/user.rb', line 45 def unfollow_board(board_id) delete("me/following/boards/#{board_id}") end |
#unfollow_interest(interest_id) ⇒ Object
53 54 55 |
# File 'lib/pinterest/client/user.rb', line 53 def unfollow_interest(interest_id) delete("me/following/interests/#{interest_id}") end |
#unfollow_user(user) ⇒ Object
37 38 39 |
# File 'lib/pinterest/client/user.rb', line 37 def unfollow_user(user) delete("me/following/users/#{user}") end |