跳转到主要内容
GET
/
v1
/
twitter
/
screennames
cURL
curl --request GET \
  --url 'https://api.keyapi.ai/v1/twitter/screennames?rest_ids=44196397,34743251' \
  --header 'Authorization: Bearer <YOUR_API_KEY>'
{
  "code": 0,
  "message": "success",
  "data": {
    "users": [
      {
        "status": "active",
        "profile": "elonmusk",
        "rest_id": "44196397",
        "blue_verified": true,
        "affiliates": {
          "label": {
            "badge": {
              "url": "https://pbs.twimg.com/profile_images/1955359038532653056/OSHY3ewP_bigger.jpg"
            },
            "description": "X",
            "url": {
              "url": "https://twitter.com/X",
              "urlType": "DeepLink"
            },
            "userLabelDisplayType": "Badge",
            "userLabelType": "BusinessLabel"
          }
        },
        "business_account": null,
        "avatar": "https://pbs.twimg.com/profile_images/2053244804520427520/m8mdWZCG_normal.jpg",
        "header_image": "https://pbs.twimg.com/profile_banners/44196397/1774145451",
        "desc": "https://t.co/dDtDyVssfm",
        "can_dm": false,
        "name": "Elon Musk",
        "protected": false,
        "location": "",
        "friends": 1325,
        "sub_count": 239954244,
        "favourites": 226857,
        "statuses_count": 102416,
        "media_count": 4487,
        "pinned_tweet_ids_str": null,
        "created_at": "Tue Jun 02 20:12:29 +0000 2009",
        "id": "44196397"
      },
      {
        "status": "active",
        "profile": "SpaceX",
        "rest_id": "34743251",
        "blue_verified": true,
        "affiliates": [],
        "business_account": null,
        "avatar": "https://pbs.twimg.com/profile_images/1697749409851985920/HbrI04tM_normal.jpg",
        "header_image": "https://pbs.twimg.com/profile_banners/34743251/1681251194",
        "desc": "SpaceX designs, manufactures and launches the world’s most advanced rockets and spacecraft",
        "can_dm": false,
        "name": "SpaceX",
        "website": "http://spacex.com",
        "protected": false,
        "location": "Earth",
        "friends": 123,
        "sub_count": 41661327,
        "favourites": 520,
        "statuses_count": 11299,
        "media_count": 4429,
        "pinned_tweet_ids_str": [
          "2054304050338750931"
        ],
        "created_at": "Thu Apr 23 21:53:30 +0000 2009",
        "id": "34743251"
      }
    ]
  },
  "requestId": "ab373346-4784-4d68-99fe-eaebf53e5b35"
}
🪙1 credit每次请求

Copy for AI

🤖 让 AI 帮你写调用代码

点击按钮复制一段结构化提示词,可直接交给 ChatGPT、Claude 或其他 AI 助手生成接口调用代码。

授权

Authorization
string
header
必填

接口鉴权凭证。请在请求 Header 中传入 Authorization: Bearer <YOUR_API_KEY>。 可在 Dashboard 获取你的 API Key。

查询参数

rest_ids
string
必填

用户ID 列表,多个 ID 可按接口约定分隔。

示例:

"44196397,34743251"

响应

请求成功

The response is of type object.