Class: Vk::API::Messages::Methods::Send
- Inherits:
-
Schema::Method
- Object
- Dry::Struct
- Schema::Method
- Vk::API::Messages::Methods::Send
- Defined in:
- lib/vk/api/messages/methods/send.rb
Overview
Sends a message.
Arguments collapse
-
#attachment ⇒ String
(Required if 'message' is not set.) List of objects attached to the message, separated by commas, in the following format:; "
_ "; '' — Type of media attachment:; 'photo' — photo; 'video' — video; 'audio' — audio; 'doc' — document; 'wall' — wall post; ' ' — ID of the media attachment owner.; ' ' — media attachment ID.; ; Example:; "photo100172_166443618". -
#chat_id ⇒ Integer
ID of conversation the message will relate to.
-
#domain ⇒ String
User's short address (for example, 'illarionov').
-
#forward_messages ⇒ String
ID of forwarded messages, separated with a comma.
-
#lat ⇒ Number
Geographical latitude of a check-in, in degrees (from -90 to 90).
-
#long ⇒ Number
Geographical longitude of a check-in, in degrees (from -180 to 180).
-
#message ⇒ String
(Required if 'attachments' is not set.) Text of the message.
-
#notification ⇒ Boolean
'1' if the message is a notification (for community messages).
-
#peer_id ⇒ Integer
Destination ID.; ; "For user:; 'User ID', e.g.
-
#random_id ⇒ Integer
Unique identifier to avoid resending the message.
-
#sticker_id ⇒ Integer
Sticker id.
-
#user_id ⇒ Integer
User ID (by default — current user).
-
#user_ids ⇒ Array
IDs of message recipients (if new conversation shall be started).
Instance Method Summary collapse
- #initialize(arguments) ⇒ Messages::Methods::Send constructor
Methods inherited from Schema::Method
Constructor Details
#initialize(arguments) ⇒ Messages::Methods::Send
|
# File 'lib/vk/api/messages/methods/send.rb', line 15
|
Instance Method Details
#attachment ⇒ String
Returns (Required if 'message' is not set.) List of objects attached to the message, separated by commas, in the following format:; "
53 |
# File 'lib/vk/api/messages/methods/send.rb', line 53 attribute :attachment, API::Types::Coercible::String.optional.default(nil) |
#chat_id ⇒ Integer
Returns ID of conversation the message will relate to.
43 |
# File 'lib/vk/api/messages/methods/send.rb', line 43 attribute :chat_id, API::Types::Coercible::Int.optional.default(nil) |
#domain ⇒ String
Returns User's short address (for example, 'illarionov').
41 |
# File 'lib/vk/api/messages/methods/send.rb', line 41 attribute :domain, API::Types::Coercible::String.optional.default(nil) |
#forward_messages ⇒ String
Returns ID of forwarded messages, separated with a comma. Listed messages of the sender will be shown in the message body at the recipient's.; ; Example:; "123,431,544".
55 |
# File 'lib/vk/api/messages/methods/send.rb', line 55 attribute :forward_messages, API::Types::Coercible::String.optional.default(nil) |
#lat ⇒ Number
Returns Geographical latitude of a check-in, in degrees (from -90 to 90).
49 |
# File 'lib/vk/api/messages/methods/send.rb', line 49 attribute :lat, API::Types::Coercible::Int.optional.default(nil) |
#long ⇒ Number
Returns Geographical longitude of a check-in, in degrees (from -180 to 180).
51 |
# File 'lib/vk/api/messages/methods/send.rb', line 51 attribute :long, API::Types::Coercible::Int.optional.default(nil) |
#message ⇒ String
Returns (Required if 'attachments' is not set.) Text of the message.
47 |
# File 'lib/vk/api/messages/methods/send.rb', line 47 attribute :message, API::Types::Coercible::String.optional.default(nil) |
#notification ⇒ Boolean
Returns '1' if the message is a notification (for community messages).
59 |
# File 'lib/vk/api/messages/methods/send.rb', line 59 attribute :notification, API::Types::Form::Bool.optional.default(nil) |
#peer_id ⇒ Integer
Returns Destination ID.; ; "For user:; 'User ID', e.g. '12345'.; ; For chat:; '2000000000' + 'chat_id', e.g. '2000000001'.; ; For community:; '- community ID', e.g. '-12345'.; ".
39 |
# File 'lib/vk/api/messages/methods/send.rb', line 39 attribute :peer_id, API::Types::Coercible::Int.optional.default(nil) |
#random_id ⇒ Integer
Returns Unique identifier to avoid resending the message.
37 |
# File 'lib/vk/api/messages/methods/send.rb', line 37 attribute :random_id, API::Types::Coercible::Int.optional.default(nil) |
#sticker_id ⇒ Integer
Returns Sticker id.
57 |
# File 'lib/vk/api/messages/methods/send.rb', line 57 attribute :sticker_id, API::Types::Coercible::Int.optional.default(nil) |