Warning
This Cloudflare Worker codebase is from 2021. Many of the API endpoints may have changed since then. Cloudflare Workers have evolved significantly from that time to today. Although I believe this code should still work, I do not recommend using it in production.
If you want to use it in production, I am not going to update the code myself, you may fork the repository and apply your changes.
GET /?username=twitterapi| Parameter | Type | Description |
|---|---|---|
username |
string |
Required. The twitter username of the account that you're looking for. |
GET /?username=twitterapi&lookup=likes| Parameter | Type | Description |
|---|---|---|
username |
string |
Required. The twitter username of the account that you're looking for. |
lookup |
string |
Required. Type likes to get the likes. |
count |
number |
Optional. Specifies the number of records to retrieve. Must be less than or equal to 200; defaults to 20. |
since_id |
number |
Optional. Returns results with an ID greater than (that is, more recent than) the specified ID. |
max_id |
number |
Optional. Returns results with an ID less than (that is, older than) or equal to the specified ID. |
You need to install Cloudflare Wrangler and Node.js to initialize this worker locally.
wrangler generate cloudflare-worker-twitter https://github.com/ardasoyturk/cloudflare-worker-twitterYou can use wrangler dev command to test the worker locally and use wrangler publish to publish your worker to Cloudflare Workers.
If you run into issues with this specific project, please feel free to file an issue here. If the problem is with Wrangler, please file an issue here.