X Trends for Openclaw

A specialized skill for retrieving real-time trending topics and hashtags from X (Twitter) based on specific geographic locations.

terryds
v1.0.0
Mar 30, 2026
1
760
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install x-trends-api

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install x-trends-api using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is X Trends?

The X Trends skill provides a streamlined interface for developers to access live data from the X platform via the official API. By integrating this capability into Openclaw Skills, users can programmatically monitor what is happening globally or in specific regions. This tool is essential for those who need to track viral content, breaking news, or local sentiment without manually browsing the platform.

Built on top of a robust Python architecture, the skill handles the complexities of location mapping (WOEID) and API authentication. It allows users to query trends for worldwide or city-specific results, delivering structured data that includes trend names and tweet volumes when available.

X Trends Use Cases

  • Tracking viral hashtags for real-time digital marketing campaigns.
  • Monitoring regional news and breaking events in specific cities or countries.
  • Analyzing social media engagement levels for specific topics over time.
  • Automating competitive research by observing trending discussions in niche markets.

How X Trends Works

  1. The user provides a valid X Bearer Token to authenticate the session through the Openclaw Skills environment.
  2. The user identifies a specific location using the WOEID (Where On Earth ID) lookup script.
  3. The skill sends a request to the X API trends endpoint for the specified geographic location.
  4. The script processes the raw API response and formats the trending topics into a readable list, including tweet counts where available.

X Trends Setup

To get started with this skill, follow these installation and configuration steps:

  1. Obtain your Bearer Token from the X Developer Portal.
  2. Ensure Python 3 is installed on your system.
  3. Set your environment variable to authorize the Openclaw Skills agent:
export X_BEARER_TOKEN="your-bearer-token-here"
  1. Alternatively, you can store your credentials in your local config file at ~/.openclaw/openclaw.json:
{
  "skills": {
    "x-trends": {
      "apiKey": "your-bearer-token-here"
    }
  }
}

X Trends Data Schema & Taxonomy

The skill utilizes a combination of local mapping files and dynamic API data. Below is the structure of the data processed by the skill:

Component Type Description
woeid.json Local File A comprehensive mapping of cities and countries to their respective WOEID identifiers.
Trend Name String The name of the trending topic or hashtag.
Tweet Volume Integer The number of tweets for the trend within the last 24 hours (if available).
WOEID Integer The location code used for the query (e.g., 1 for Worldwide).

X Trends Advanced Features

  • Intelligent WOEID lookup that supports partial matches and case-insensitive searches for cities and countries.
  • Adjustable result density allowing users to limit the output from 1 to 50 results per query.
  • Seamless integration with the broader ecosystem of Openclaw Skills for cross-platform data analysis.
  • Command-line flexibility for quick trend snapshots without a browser.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*