Class: Vk::API::Messages::Methods::GetHistory

Inherits:
Schema::Method
  • Object
show all
Defined in:
lib/vk/api/messages/methods/get_history.rb

Overview

Returns message history for the specified user or group chat.

Arguments collapse

Instance Method Summary collapse

Methods inherited from Schema::Method

#call, #method, #to_hash

Constructor Details

#initialize(arguments) ⇒ Messages::Methods::GetHistory

Parameters:

  • arguments (Hash)

Options Hash (arguments):

  • :offset (Integer)

    Offset needed to return a specific subset of messages.

  • :count (Integer)

    Number of messages to return.

  • :user_id (String)

    ID of the user whose message history you want to return.

  • :peer_id (Integer)
  • :start_message_id (Integer)

    Starting message ID from which to return history.

  • :rev (Integer)

    Sort order:; '1' — return messages in chronological order.; '0' — return messages in reverse chronological order.



# File 'lib/vk/api/messages/methods/get_history.rb', line 15

Instance Method Details

#countInteger

Returns Number of messages to return.

Returns:

  • (Integer)

    Number of messages to return.



30
# File 'lib/vk/api/messages/methods/get_history.rb', line 30

attribute :count, API::Types::Coercible::Int.optional.default(20)

#offsetInteger

Returns Offset needed to return a specific subset of messages.

Returns:

  • (Integer)

    Offset needed to return a specific subset of messages.



28
# File 'lib/vk/api/messages/methods/get_history.rb', line 28

attribute :offset, API::Types::Coercible::Int.optional.default(nil)

#peer_idInteger



34
# File 'lib/vk/api/messages/methods/get_history.rb', line 34

attribute :peer_id, API::Types::Coercible::Int.optional.default(nil)

#revInteger

Returns Sort order:; '1' — return messages in chronological order.; '0' — return messages in reverse chronological order.

Returns:

  • (Integer)

    Sort order:; '1' — return messages in chronological order.; '0' — return messages in reverse chronological order.



38
# File 'lib/vk/api/messages/methods/get_history.rb', line 38

attribute :rev, API::Types::Coercible::Int.optional.default(nil)

#start_message_idInteger

Returns Starting message ID from which to return history.

Returns:

  • (Integer)

    Starting message ID from which to return history.



36
# File 'lib/vk/api/messages/methods/get_history.rb', line 36

attribute :start_message_id, API::Types::Coercible::Int.optional.default(nil)

#user_idString

Returns ID of the user whose message history you want to return.

Returns:

  • (String)

    ID of the user whose message history you want to return.



32
# File 'lib/vk/api/messages/methods/get_history.rb', line 32

attribute :user_id, API::Types::Coercible::String.optional.default(nil)