Please note
We recently released blocks lookup, a Twitter API v2 endpoint that has similar functionality to this one. The new version is currently in development and serves adequate access for the majority of developers on our platform. While elevated levels of access are coming soon, developers in need of higher levels of access should continue to use this endpoint along with the Twitter API v2 version.
GET blocks/ids
Returns an array of numeric user ids the authenticating user is blocking.
Important This method is cursored, meaning your app must make multiple requests in order to receive all blocks correctly. See Using cursors to navigate collections for more details on how cursoring works.
Resource URL¶
https://api.twitter.com/1.1/blocks/ids.json
Resource Information¶
Response formats | JSON |
Requires authentication? | Yes (user context only) |
Rate limited? | Yes |
Requests / 15-min window (user auth) | 15 |
Parameters¶
Name | Required | Description | Default Value | Example |
---|---|---|---|---|
stringify_ids | optional | Many programming environments will not consume Twitter IDs due to their size. Provide this option to have IDs returned as strings instead. Read more about Twitter IDs . | true |
|
cursor | semi-optional | Causes the list of IDs to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filtered out after connections are queried. If no cursor is provided, a value of The response from the API will include a |
-1 |
12893764510938 |
Example Request¶
GET https://api.twitter.com/1.1/blocks/ids.json?stringify_ids=true&cursor=-1
Example Response¶
{
"ids": [
"123"
],
"next_cursor": 0,
"next_cursor_str": "0",
"previous_cursor": 0,
"previous_cursor_str": "0"
}