Social listening API

Social Listening API for X (Twitter)

Prices checked:

Quick Answer

A social listening API returns the posts that mention your brand, products or keywords as JSON, so you can run alerts, sentiment and dashboards in your own stack. For X (Twitter), TwexAPI’s search API costs about $0.05 per 1,000 posts, with no monthly plan. Listening tools that include API access cost more: Brand24 lists API access as an extra $149 on its Pro plan ($399 a month, billed annually), and Awario includes it only on its Enterprise plan ($249 a month billed annually, or $399 monthly). Those tools also cover news, blogs and other networks; TwexAPI covers X only. Prices as read on November 27, 2026.

What you can track on X with the API

Listening taskExample queryEndpoint
Brand mentions("acme" OR @acme) -from:acme -filter:retweetsPOST /twitter/advanced_search/page
Competitor mentions(globex OR initech) lang:en -filter:retweetsPOST /twitter/advanced_search/page
Complaints and support requestsacme (refund OR broken OR "not working")POST /twitter/advanced_search/page
Influential posts on a topic"ai agents" min_faves:500POST /twitter/advanced_search/page
Campaign hashtags#blackfridayPOST /twitter/hashtags
Stock and crypto tickers$TSLAPOST /twitter/cashtags
Replies to your own postsA post IDPOST /twitter/tweets/{tweet_id}/replies/page

Every search operator from X’s own search works in the query, including OR, exclusions, lang:, min_faves: and date ranges. The advanced search guide lists them all.

Social listening API vs social listening tools

OptionPriceMentions includedAPI accessSources
TwexAPI~$0.05 per 1,000 posts, pay as you goNo monthly cap; you pay for what you fetchYes (it is an API)X only
Brand24 Pro$399 a month, billed annually40,000 a month, 12 keywordsExtra $149X plus news, blogs, Reddit, YouTube and more
Brand24 Business$599 a month, billed annually100,000 a month, 25 keywordsExtra $149X plus news, blogs, Reddit, YouTube and more
Awario Enterprise$249 a month billed annually, or $399 monthly1,000,000 new mentions a month, 100 topicsIncludedSocial networks, news and the web
Official X API (pay-per-use)$5.00 per 1,000 post readsCapped at 3 million post reads a monthYesX only

Brand24 includes API access on its Enterprise plan, from $1,499 a month. Its cheaper Individual ($199) and Team ($299) plans, and Awario’s Starter ($29–$49) and Pro ($89–$149) plans, do not offer it.

Listening tools come with dashboards, sentiment scores, alerts and reports, and they cover more than X. An API suits teams that want X data inside their own product, warehouse or alerting, run their own sentiment model, or need more volume than a plan includes.

What a month of X listening costs on TwexAPI

WorkloadCredits a monthCost a month
One brand, about 200 mentions a day, checked every 15 minutesUp to 44,400Under $0.50
10 keyword queries checked every 5 minutes, about 3,000 new posts a dayUp to 882,000Under $9
A research dashboard collecting 50,000 posts a day7,500,000About $75
A one-time backfill of 100,000 past posts on a topic500,000About $5

TwexAPI bills 5 Credits per post returned, at 100,000 Credits per $1. A check that finds no new posts costs 5 Credits, and requests that fail with an error are free. Add since_id: with the newest post ID you have saved, so each check only returns, and bills, posts you have not seen.

How to build social listening on the API

  • Write one search query per topic: your brand, each competitor, campaign hashtags or product names.
  • Check each query on a schedule with sortBy set to Latest and since_id: set to the newest post you have stored.
  • Save posts to your database and deduplicate on tweet_id.
  • Score sentiment and topics with your own model or an LLM, then send alerts to Slack, Discord or email.
  • Test with the 20,000 free Credits you get on signup, about 4,000 posts, before connecting production systems.

Python mention monitor example

This script checks a brand query every 5 minutes and prints new mentions, or posts them to Slack when SLACK_WEBHOOK_URL is set. Each page returns up to 20 posts; if a query gets more than that between checks, check more often or follow next_cursor.

mention_monitor.py
import os
import time

import requests

API_KEY = os.environ["TWEXAPI_KEY"]
SLACK_WEBHOOK_URL = os.environ.get("SLACK_WEBHOOK_URL")
URL = "https://api.twexapi.io/twitter/advanced_search/page"
QUERY = '("acme" OR @acme) -from:acme -filter:retweets'


def new_mentions(since_id):
    query = f"{QUERY} since_id:{since_id}" if since_id else QUERY
    res = requests.post(
        URL,
        headers={"Authorization": f"Bearer {API_KEY}"},
        json={"searchTerms": [query], "sortBy": "Latest"},
        timeout=30,
    )
    res.raise_for_status()
    return [t for t in res.json().get("data", []) if t]


since_id = None
while True:
    posts = new_mentions(since_id)
    for t in reversed(posts):  # oldest first
        line = f'@{(t.get("user") or {}).get("screen_name")}: {t.get("text")}'
        print(line)
        if SLACK_WEBHOOK_URL:
            requests.post(SLACK_WEBHOOK_URL, json={"text": line}, timeout=10)
    if posts:
        since_id = max(int(t["tweet_id"]) for t in posts)
    time.sleep(300)
Start with 20,000 free CreditsBuild a listening query

FAQ

What is a social listening API?

An API that returns public posts mentioning a brand, product, person or keyword, so a program can collect them instead of a person reading a dashboard. Teams use it to feed alerts, sentiment models, BI dashboards and AI agents.

Which social listening tools have an API?

On November 27, 2026, Brand24 listed API access as an extra $149 on its Pro ($399 a month) and Business ($599 a month) plans, billed annually, and included it on Enterprise (from $1,499 a month). Awario included it only on its Enterprise plan ($249 a month billed annually, or $399 monthly). Their cheaper plans did not offer API access.

Does the API include sentiment analysis?

No. TwexAPI returns each post’s text, author, time and engagement counts, and you score sentiment yourself, for example with an open-source model or an LLM. Listening tools such as Brand24 and Awario include sentiment in their dashboards.

Is it real time?

Near real time. TwexAPI does not push posts to a webhook; you check the search endpoint on a schedule, so new mentions arrive within your checking interval, for example every minute or every 5 minutes.

Does TwexAPI cover Instagram, Reddit or news sites?

No. TwexAPI covers public X (Twitter) data only. For other networks you need another source or a multi-network listening tool.

Is TwexAPI affiliated with X?

No. TwexAPI is an independent third-party provider of public social data and is not affiliated with or endorsed by X Corp.

Related Guides

Sources

Prices change. Confirm current rates on each provider’s pricing page before you buy. TwexAPI is an independent provider and is not affiliated with or endorsed by X Corp.