cURL
curl --request POST \ --url https://api.x.com/2/users/{id}/dm/block \ --header 'Authorization: Bearer <token>'
{ "data": { "blocked": true }, "errors": [ { "detail": "<string>", "status": 123, "title": "<string>", "type": "<string>" } ] }
Blocks direct messages to or from a specific User by their ID for the authenticated user.
Show child attributes
1