Module: ZaloAPI::OfficalAccount::Information
- Included in:
- ZaloAPI::OA
- Defined in:
- lib/zalo_api/offical_account/information.rb
Instance Method Summary collapse
-
#followers(offset = 0, count = 5) ⇒ Faraday::Response
Get a list of followers.
-
#get_conversation_with_user(user_id, offset = 0, count = 5) ⇒ Faraday::Response
Get a list of messages with interested people.
-
#get_user_profile(user_id) ⇒ Object
Get profile of follower.
-
#me ⇒ Object
Get Offical Account profile.
-
#recent_chat(offset = 0, count = 5) ⇒ Object
Get a list of the most recent messages.
Instance Method Details
#followers(offset = 0, count = 5) ⇒ Faraday::Response
Get a list of followers
30 31 32 33 |
# File 'lib/zalo_api/offical_account/information.rb', line 30 def followers(offset = 0, count = 5) param = { offset: offset, count: count } @client.connection.get "#{base_url}/oa/getfollowers", { data: param.to_json } end |
#get_conversation_with_user(user_id, offset = 0, count = 5) ⇒ Faraday::Response
Get a list of messages with interested people
105 106 107 108 |
# File 'lib/zalo_api/offical_account/information.rb', line 105 def get_conversation_with_user(user_id, offset = 0, count = 5) param = { user_id: user_id, offset: offset, count: count } @client.connection.get "#{base_url}/oa/conversation", { data: param.to_json } end |
#get_user_profile(user_id) ⇒ Object
Get profile of follower
67 68 69 |
# File 'lib/zalo_api/offical_account/information.rb', line 67 def get_user_profile(user_id) @client.connection.get "#{base_url}/oa/getprofile", { data: { user_id: user_id }.to_json } end |
#me ⇒ Object
Get Offical Account profile
5 6 7 |
# File 'lib/zalo_api/offical_account/information.rb', line 5 def me @client.connection.get "#{base_url}/oa/getoa" end |
#recent_chat(offset = 0, count = 5) ⇒ Object
Get a list of the most recent messages
36 37 38 39 |
# File 'lib/zalo_api/offical_account/information.rb', line 36 def recent_chat(offset = 0, count = 5) param = { offset: offset, count: count } @client.connection.get "#{base_url}/oa/listrecentchat", { data: param.to_json } end |