Create a post
create_post.RdCreates a new post using the CreatePost RPC. Supports replies, quoted
posts, media attachments, content masks, and publishing type settings.
Usage
create_post(
client,
text,
in_reply_to_post_id = NULL,
quoted_post_id = NULL,
media_id_list = NULL,
post_mask = NULL,
publishing_type = NULL
)Arguments
- client
A
mixi2_clientobject created bymixi2_client().- text
Post body text (max 149 characters).
- in_reply_to_post_id
Post ID to reply to. Cannot be combined with
quoted_post_id.- quoted_post_id
Post ID to quote. Cannot be combined with
in_reply_to_post_id.- media_id_list
Character vector of media IDs to attach (max 4).
- post_mask
A named list with
maskType("POST_MASK_TYPE_SENSITIVE"or"POST_MASK_TYPE_SPOILER") and optionallycaption.- publishing_type
One of
"POST_PUBLISHING_TYPE_UNSPECIFIED"(default, visible on follower timelines) or"POST_PUBLISHING_TYPE_NOT_PUBLISHING"(profile only).
Examples
if (FALSE) { # \dontrun{
client <- mixi2_client()
# Basic post
create_post(client, "Hello, mixi2!")
# Reply
create_post(client, "Thanks!", in_reply_to_post_id = "some_post_id")
# Spoiler mask
create_post(client, "Movie spoiler...",
post_mask = list(
maskType = "POST_MASK_TYPE_SPOILER",
caption = "Spoiler warning"
)
)
} # }