osm_create_user_block {osmapiR} | R Documentation |
Create a user block
Description
Create a user block
Usage
osm_create_user_block(
user_id,
reason,
period,
needs_view = FALSE,
format = c("R", "xml", "json")
)
Arguments
user_id |
Blocked user id. |
reason |
Reason for block shown to the blocked user (markdown text). |
period |
Block duration in hours between 0 and maximum block period, currently 87660. |
needs_view |
If |
format |
Format of the output. Can be |
Value
Same format as osm_get_user_blocks()
See Also
Other user blocks' functions:
osm_get_user_blocks()
,
osm_list_active_user_blocks()
Other functions for moderators:
osm_delete_note()
,
osm_hide_comment_changeset_discussion()
,
osm_redaction_object()
Examples
## Not run:
set_osmapi_connection("testing") # use the testing server
my_user_id <- osm_details_logged_user()$user["id"]
osm_create_user_block(user_id = my_user_id, reason = "Not really evil, just testing.", period = 0)
## End(Not run)
[Package osmapiR version 0.2.3 Index]