Saltar al contenido principal
GET
/
2
/
trends
/
by
/
woeid
/
{woeid}
Obtener tendencias por WOEID
curl --request GET \
  --url https://api.x.com/2/trends/by/woeid/{woeid} \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "trend_name": "<string>",
      "tweet_count": 123
    }
  ],
  "errors": [
    {
      "title": "<string>",
      "type": "<string>",
      "detail": "<string>",
      "status": 123
    }
  ]
}

Autorizaciones

Authorization
string
header
requerido

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

Parámetros de ruta

woeid
integer<int32>
requerido

El WOEID del lugar para el que se quieren obtener tendencias.

Parámetros de consulta

El número máximo de resultados.

Rango requerido: 1 <= x <= 50
trend.fields
enum<string>[]

Una lista de campos de Trend, separados por comas, que se mostrarán. Los campos disponibles para un objeto Trend.

Minimum array length: 1
Opciones disponibles:
trend_name,
tweet_count
Ejemplo:
["trend_name", "tweet_count"]

Respuesta

La solicitud se completó correctamente.

data
object[]
Minimum array length: 1
errors
object[]
Minimum array length: 1

Un objeto HTTP Problem Details, tal como se define en el IETF RFC 7807 (https://tools.ietf.org/html/rfc7807).