Documentation Index
Fetch the complete documentation index at: https://generaltranslation.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
このガイドでは、キーワードで Spaces を検索する方法を説明します。
キーワードに一致するスペースを検索します:
curl "https://api.x.com/2/spaces/search?\
query=AI&\
space.fields=title,host_ids,participant_count,state&\
state=live" \
-H "Authorization: Bearer $BEARER_TOKEN"
{
"data": [
{
"id": "1DXxyRYNejbKM",
"state": "live",
"title": "Discussing AI and the Future",
"host_ids": ["2244994945"],
"participant_count": 245
},
{
"id": "1YqJDqWYNQDGW",
"state": "live",
"title": "AI in Healthcare",
"host_ids": ["783214"],
"participant_count": 89
}
],
"meta": {
"result_count": 2
}
}
ライブ中またはスケジュール済みのスペースのみを検索します:
curl "https://api.x.com/2/spaces/search?query=tech&state=live" \
-H "Authorization: Bearer $BEARER_TOKEN"
curl "https://api.x.com/2/spaces/search?query=tech&state=scheduled" \
-H "Authorization: Bearer $BEARER_TOKEN"
ホストユーザーのデータを展開します:
curl "https://api.x.com/2/spaces/search?\
query=AI&\
space.fields=title,host_ids,state&\
expansions=host_ids&\
user.fields=username,verified" \
-H "Authorization: Bearer $BEARER_TOKEN"
| パラメーター | 説明 |
|---|
query | 検索クエリ (必須) |
state | フィルター:live、scheduled、または all |
max_results | 返す結果数 (1〜100) |
space.fields | レスポンスに含める Space のフィールド |
expansions | レスポンスに含める関連オブジェクト |
user.fields | レスポンスに含める User のフィールド |
Space ルックアップ
id で Space を取得する
APIリファレンス
エンドポイントの詳細ドキュメント