Class: Vk::API::Wall::Methods::Post
- Inherits:
-
Schema::Method
- Object
- Dry::Struct
- Schema::Method
- Vk::API::Wall::Methods::Post
- Defined in:
- lib/vk/api/wall/methods/post.rb
Overview
Adds a new post on a user wall or community wall. Can also be used to publish suggested or scheduled posts.
Arguments collapse
-
#attachments ⇒ Array
(Required if 'message' is not set.) List of objects attached to the post, in the following format:; "
, "; '' — Type of media attachment:; 'photo' — photo; 'video' — video; 'audio' — audio; 'doc' — document; 'page' — wiki-page; 'note' — note; 'poll' — poll; 'album' — photo album; ' ' — ID of the media application owner. -
#friends_only ⇒ Boolean
'1' — post will be available to friends only; '0' — post will be available to all users (default).
-
#from_group ⇒ Boolean
For a community:; '1' — post will be published by the community; '0' — post will be published by the user (default).
- #guid ⇒ String
-
#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).
- #mark_as_ads ⇒ Boolean
-
#message ⇒ String
(Required if 'attachments' is not set.) Text of the post.
-
#owner_id ⇒ Integer
User ID or community ID.
-
#place_id ⇒ Integer
ID of the location where the user was tagged.
-
#post_id ⇒ Integer
Post ID.
-
#publish_date ⇒ Integer
Publication date (in Unix time).
-
#services ⇒ String, 'facebook'
List of services or websites the update will be exported to, if the user has so requested.
-
#signed ⇒ Boolean
Only for posts in communities with 'from_group' set to '1':; '1' — post will be signed with the name of the posting user; '0' — post will not be signed (default).
Instance Method Summary collapse
- #initialize(arguments) ⇒ Wall::Methods::Post constructor
Methods inherited from Schema::Method
Constructor Details
Instance Method Details
#attachments ⇒ Array
Returns (Required if 'message' is not set.) List of objects attached to the post, in the following format:; "
44 |
# File 'lib/vk/api/wall/methods/post.rb', line 44 attribute :attachments, API::Types::Coercible::Array.member(API::Types::Coercible::String).optional.default(nil) |
#friends_only ⇒ Boolean
Returns '1' — post will be available to friends only; '0' — post will be available to all users (default).
38 |
# File 'lib/vk/api/wall/methods/post.rb', line 38 attribute :friends_only, API::Types::Form::Bool.optional.default(nil) |
#from_group ⇒ Boolean
Returns For a community:; '1' — post will be published by the community; '0' — post will be published by the user (default).
40 |
# File 'lib/vk/api/wall/methods/post.rb', line 40 attribute :from_group, API::Types::Form::Bool.optional.default(nil) |
#guid ⇒ String
60 |
# File 'lib/vk/api/wall/methods/post.rb', line 60 attribute :guid, API::Types::Coercible::String.optional.default(nil) |
#lat ⇒ Number
Returns Geographical latitude of a check-in, in degrees (from -90 to 90).
52 |
# File 'lib/vk/api/wall/methods/post.rb', line 52 attribute :lat, API::Types::Coercible::Int.optional.default(nil) |
#long ⇒ Number
Returns Geographical longitude of a check-in, in degrees (from -180 to 180).
54 |
# File 'lib/vk/api/wall/methods/post.rb', line 54 attribute :long, API::Types::Coercible::Int.optional.default(nil) |
#mark_as_ads ⇒ Boolean
62 |
# File 'lib/vk/api/wall/methods/post.rb', line 62 attribute :mark_as_ads, API::Types::Form::Bool.optional.default(false) |
#message ⇒ String
Returns (Required if 'attachments' is not set.) Text of the post.
42 |
# File 'lib/vk/api/wall/methods/post.rb', line 42 attribute :message, API::Types::Coercible::String.optional.default(nil) |
#owner_id ⇒ Integer
Returns User ID or community ID. Use a negative value to designate a community ID.
36 |
# File 'lib/vk/api/wall/methods/post.rb', line 36 attribute :owner_id, API::Types::Coercible::Int.optional.default(nil) |
#place_id ⇒ Integer
Returns ID of the location where the user was tagged.
56 |
# File 'lib/vk/api/wall/methods/post.rb', line 56 attribute :place_id, API::Types::Coercible::Int.optional.default(nil) |
#post_id ⇒ Integer
Returns Post ID. Used for publishing of scheduled and suggested posts.
58 |
# File 'lib/vk/api/wall/methods/post.rb', line 58 attribute :post_id, API::Types::Coercible::Int.optional.default(nil) |
#publish_date ⇒ Integer
Returns Publication date (in Unix time). If used, posting will be delayed until the set time.
50 |
# File 'lib/vk/api/wall/methods/post.rb', line 50 attribute :publish_date, API::Types::Coercible::Int.optional.default(nil) |
#services ⇒ String, 'facebook'
Returns List of services or websites the update will be exported to, if the user has so requested. Sample values: 'twitter', 'facebook'.
46 |
# File 'lib/vk/api/wall/methods/post.rb', line 46 attribute :services, API::Types::Coercible::String.optional.default(nil) |
#signed ⇒ Boolean
Returns Only for posts in communities with 'from_group' set to '1':; '1' — post will be signed with the name of the posting user; '0' — post will not be signed (default).
48 |
# File 'lib/vk/api/wall/methods/post.rb', line 48 attribute :signed, API::Types::Form::Bool.optional.default(nil) |