Module: Imwukong::Api::User
- Defined in:
- lib/imwukong/api-obsolete/user.rb
Instance Method Summary collapse
-
#profile(open_id) ⇒ Object
@return, i.e.
-
#profiles(open_ids) ⇒ Object
User profiles in an array.
-
#update_profile(params) ⇒ Object
i.e.
- #update_tag(open_id, tag, op) ⇒ Object
Instance Method Details
#profile(open_id) ⇒ Object
@return, i.e.
"avatar":"http://laiwang.wukong.com/tianfeng.png"
9 10 11 12 |
# File 'lib/imwukong/api-obsolete/user.rb', line 9 def profile(open_id) params = {openId: open_id.to_i} wk_get('user', 'profile/get', params) end |
#profiles(open_ids) ⇒ Object
Returns user profiles in an array.
23 24 25 26 27 |
# File 'lib/imwukong/api-obsolete/user.rb', line 23 def profiles(open_ids) fail 'Invalid [profiles get] parameters' unless open_ids.is_a?(Array) params = {openIds: open_ids} wk_post('user', 'profiles/get', params) end |
#update_profile(params) ⇒ Object
i.e. avatar: “”, birthday:651337200000,gender: 1,
isActive: true, nick: "u1", nickPinyin: "testpinyin", openid: 1, ver: 1
17 18 19 |
# File 'lib/imwukong/api-obsolete/user.rb', line 17 def update_profile(params) wk_post('user', 'profile/update', params) end |
#update_tag(open_id, tag, op) ⇒ Object
29 30 31 32 33 34 35 36 |
# File 'lib/imwukong/api-obsolete/user.rb', line 29 def update_tag(open_id, tag, op) params = { openId: open_id, tag: tag, op: op } wk_post('user', 'tag/update', params) end |