Closed gaeulbyul closed 5 years ago
Twitter has another API for block user: https://twitter.com/i/users/block_all. (Currently it is using for CSV blocklist import feature)
https://twitter.com/i/users/block_all
This API can block many (up to 800)¹ user in single request. It would be great for Twitter-block-chain extension.
Example Usage:
POST /i/users/block_all authenticity_token=0000000000000 user_ids[]=884033788858085377 user_ids[]=871952445361889280 user_ids[]=1000704020636360706 user_ids[]=831075168193695744
Response(JSON):
{ "result": { "blocked": [ "884033788858085377", "871952445361889280", "1000704020636360706", "831075168193695744" ], "failed": [] } }
¹ from twitter's code (https://abs.twimg.com/k/ko/2.pages_settings.ko.a848670d33a48950e987.js):
https://abs.twimg.com/k/ko/2.pages_settings.ko.a848670d33a48950e987.js
// ... this.defaultAttrs({ blockAllEndpoint: "/i/user/block_all", chunkSize: 800 }), this.blockAllUsers = function(t, e) { ... } // ...
very cool! sounds like it would work well for reducing network usage.
I think this API is not going to be available in the new PWA UI but hopefully they'll re-implement it soon.
Twitter has another API for block user:
https://twitter.com/i/users/block_all
. (Currently it is using for CSV blocklist import feature)This API can block many (up to 800)¹ user in single request. It would be great for Twitter-block-chain extension.
Example Usage:
Response(JSON):
¹ from twitter's code (
https://abs.twimg.com/k/ko/2.pages_settings.ko.a848670d33a48950e987.js
):