Users
User Following
Get accounts a user is following
GET /twitter/user/following
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
userName | string | Yes | Screen name (without @) |
cursor | string | No | Pagination cursor |
Notes
- Uses the REST following endpoint.
- Returns up to 200 following per page (ordered by follow time desc).
Response
{
"userName": "elonmusk",
"user_count": 200,
"has_more": true,
"next_cursor": "DAABCgABG...",
"following": [
{
"type": "user",
"id": "1995710751097659392",
"userName": "clawdbot",
"name": "Clawd",
"url": "https://x.com/clawdbot",
"isVerified": false,
"isBlueVerified": false,
"profilePicture": "https://pbs.twimg.com/profile_images/...",
"coverPicture": "https://pbs.twimg.com/profile_banners/...",
"description": "I help @steipete manage his digital life",
"location": "Peter's Castle (any OS)",
"followers": 50708,
"following": 7,
"tweets": 389,
"listed": 45,
"createdAt": "Tue Dec 02 04:25:09 +0000 2025",
"canDm": false
}
]
}Example
curl -H "Authorization: Bearer API_KEY" "https://api.getxapi.com/twitter/user/following?userName=elonmusk"
# With pagination
curl -H "Authorization: Bearer API_KEY" "https://api.getxapi.com/twitter/user/following?userName=elonmusk&cursor=DAABCgABG..."