Skip to content
Twexapi
English
Esc
↑↓navigate↵open⌘Jpreview

Check Follow Relationship

Check whether source_user_name follows target_user_name (following) and whether target_user_name follows source_user_name (followed_by). One request returns both directions, plus both screen names and user IDs. $0.05/1000 calls.

Back to API Reference
/Followers & Following Endpoints
GET/twitter/user/check_follow_relationship
Authorization
AuthorizationBearer token · headerrequired
Global API Bearer Token for TwexAPI. Included as: Authorization: Bearer <YOUR_TWEXAPI_KEY>.
Query Parameters
source_user_namestringrequired
Screen name of the source user (with or without @).
matches ^\s*@?[A-Za-z0-9_]{1,15}\s*$
target_user_namestringrequired
Screen name of the target user (with or without @).
matches ^\s*@?[A-Za-z0-9_]{1,15}\s*$
Responses
200Follow relationship in both directions
codeintegerrequired
msgstringrequired
dataCheckFollowRelationshipDatarequired
Show properties
source_user_namestringrequired
Screen name of the source user, as returned by X.
source_user_idstring | anyrequired
User ID of the source user.
Show properties
Any of:
string
string
any
any
target_user_namestringrequired
Screen name of the target user, as returned by X.
target_user_idstring | anyrequired
User ID of the target user.
Show properties
Any of:
string
string
any
any
followingbooleanrequired
Whether the source user follows the target user.
followed_bybooleanrequired
Whether the target user follows the source user.
400Missing or invalid screen name
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
401Authentication failed
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
403A user is suspended, or authentication or quota was denied
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
404One of the users was not found
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
429Rate limit exceeded
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
500Server error
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
502Upstream service error
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
503Service temporarily unavailable
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
504Upstream request timed out
codeintegerrequired
msgstringrequired
dataany[] | anyrequired
Show properties
Any of:
any[]
Array of any
any
any
any
⚡Interactive ConsoleGET
⚡Interactive Console / Try APIGET
Live Console
🌐Target Server:https://api.twexapi.io
● Production Ready
🔍
Public Data Read (TwexAPI Key Only, No Twitter Cookie Required)

This endpoint queries public Twitter data — no Twitter account or Cookie required! Simply enter your TwexAPI Platform Key (Bearer Token) in the "API Authorization" section below to test.

🔑API Authorization
⚙️Parameters (2)
📡
No Response Yet

Configure parameters in the Request tab and click Send Request below.

Request
curl -X GET "https://api.twexapi.io/twitter/user/check_follow_relationship?source_user_name=elonmusk&target_user_name=X" \
  -H "Authorization: Bearer YOUR_TOKEN"
Response
{
  "code": 200,
  "msg": "success",
  "data": {
    "source_user_name": "elonmusk",
    "source_user_id": "44196397",
    "target_user_name": "X",
    "target_user_id": "783214",
    "following": true,
    "followed_by": false
  }
}