# ryanmcgrath/twython

Actively maintained, pure Python wrapper for the Twitter API. Supports both normal and streaming Twitter APIs.

Repository: https://github.com/ryanmcgrath/twython
Canonical: https://ross.abutalabs.com/products/twython
Homepage: http://stackoverflow.com/questions/tagged/twython
Language: Python
License: MIT
License Family: permissive
Last push: 2022-07-30T23:24:29+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 6362, "days_push": 1495, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1860, forks 391 (observed 2026-08-28T04:05:45.340235+00:00)

## What it is
Twython is a pure Python library wrapping the Twitter API, supporting both the standard REST endpoints and the streaming API, with OAuth 1 and OAuth 2 authentication. It provides easy access to user data, timelines, direct messages, and media uploading.

## Use cases
- post tweets from a python script
- stream tweets in real time
- fetch a user's twitter timeline
- upload images to twitter
- sign in users with twitter oauth
- search tweets via the twitter api

## When to choose
- you need a lightweight, pure-Python Twitter API client
- you want both REST and streaming API support in one library
- you need OAuth 1 user authentication or OAuth 2 app-only auth for Twitter

## When to avoid
- you need a library with active maintenance and recent Twitter API v2 support
- you need support for other social platforms
- your project requires guaranteed long-term updates, as the project has put out a call for maintainers

## Facets
- artifact type: library
- maturity: maintenance
- function: http-client, auth, streaming
- domain: apis, social-media, web-development
- platform: python, cross-platform
- tags: twitter-api, oauth, social-media-api, api-wrapper

## Member repositories
- ryanmcgrath/twython (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:45.340235+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:15:55.739959+00:00, confidence not recorded.
  - readme: https://github.com/ryanmcgrath/twython (fetched 2026-08-28T04:05:45.340235+00:00, sha 8fe029ff6629)
  - registry_pypi: https://pypi.org/pypi/twython/json (fetched 2026-08-29T10:55:03.259439+00:00, sha 50078413862e)
- Data as of 2026-08-30T08:39:29.467469+00:00.
