Skip to content

blockUser(sourceUserId_targetUserId_)

daneden edited this page Apr 3, 2022 · 5 revisions

blockUser(sourceUserId:targetUserId:)

Causes the source user to block the target user. The source user ID must match the currently authenticated user ID.

public func blockUser(sourceUserId: User.ID, targetUserId: User.ID)

Equivalent to POST /2/users/:id/blocking

Parameters

  • sourceUserId: The user ID who you would like to initiate the block on behalf of. It must match the user ID of the currently authenticated user.
  • targetUserId: The user ID of the user you would like the source user to block.

Returns

A BlockResponse indicating the blocked status.

Types
Global Variables
Global Functions
Extensions
Clone this wiki locally