メインコンテンツへスキップ
GET
/
2
/
communities
/
{id}
ID でコミュニティを取得
curl --request GET \
  --url https://api.x.com/2/communities/{id} \
  --header 'Authorization: Bearer <token>'
{
  "errors": [
    {
      "title": "<string>",
      "type": "<string>",
      "detail": "<string>",
      "status": 123
    }
  ]
}

承認

Authorization
string
header
必須

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

パスパラメータ

id
string
必須

Community の ID。 このコミュニティの一意の識別子。

Pattern: ^[0-9]{1,19}$
:

"1146654567674912769"

クエリパラメータ

community.fields
enum<string>[]

表示対象の Community フィールドをカンマ区切りで指定するリスト。 Community オブジェクトで使用可能なフィールド。

Minimum array length: 1
利用可能なオプション:
access,
created_at,
description,
id,
join_policy,
member_count,
name
:
[
  "access",
  "created_at",
  "description",
  "id",
  "join_policy",
  "member_count",
  "name"
]

レスポンス

リクエストは成功しました。

data
object

X コミュニティは、厳選された投稿のグループです。

errors
object[]
Minimum array length: 1

IETF RFC 7807 (https://tools.ietf.org/html/rfc7807) で定義された HTTP Problem Details オブジェクト。