npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

twitter-archive-reader

v7.3.3

Published

Explore easily tweets, direct messages, medias and more from Twitter archives.

Downloads

454

Readme

twitter-archive-reader

Read data from classic Twitter archive and GDPR archive

Explore easily tweets, direct messages, medias and more from Twitter archives.

This is a JavaScript/TypeScript package available on npm that provides useful data structures concieved to manipulate Twitter archives. If you're looking for a graphical tool to explore archives without programming, take a look to Archive Explorer.

Features

For all types of archives

  • Access tweets using date selectors (by month, interval)
  • Search in tweets with custom filters
  • Get a single tweet by ID
  • Access user data stored in archive, like screen name, name or profile picture

For GDPR archives

  • Access direct messages with query selectors (conversation, date, content, context around one message)
  • Access images and videos stored in archive
  • List of favorites, blocks, mutes, followers and followings
  • Screen name history
  • Lots of user-related data like interests, age information and email addresses
  • Data from views and interactions with ads on Twitter website/mobile app
  • Twitter moments
  • Subscribed and created lists

What's a GDPR archive ?

Usage

This package can be used inside a browser or in Node.js.

Getting ready

Full documentation (version 6.x.x) is available on GitHub Wiki. Take a look !

Examples

You can find a bunch of usage examples in this file.

Linking archive files to twitter-archive-reader objects and properties

You can find a link between files and directories inside raw Twitter archives to this package data structures here. This can help you if you've found a intersting property in some file and you want to explore it with twitter-archive-reader !

Detailled type documentation

If you want to find a type definition quickly, or get a detailled view of a data structure, a automatically-generated documentation is available here.

About archive support

  • Classic archives are supported in every version of this module
    • Since 1.0.0:
      • Tweet read
      • Basic user info read
  • GDPR archives basic support since 1.0.0:
    • Since 1.0.0:
      • Tweet read
      • DM read
      • File size must be < 2 GB
    • Since 1.2.0:
      • Favorites
      • Mutes
      • Blocks
    • Since 1.3.0:
      • DM images
    • Since 1.4.1:
      • Support DM images nested in ZIP files (GDPR archives 1.1)
    • Since 2.0.0:
      • GDPR archives are streamed: file size is no longer a limit.
      • Screen name history
    • Since 4.0.0:
      • Extended favorites
      • Personalization data
      • Email addresses
      • Connected application
      • Many other user data
      • Ad data
    • Since 4.0.7:
      • Support GDPR 1.2 archives (created since January 2020)
    • Since 5.0.0:
      • Events in direct messages
      • Read every type of media available in GDPR archives

Old documentation

Wiki for 2.x.x is available here.

Wiki for 3.x.x is available here.

Wiki for 4.x.x is available here.

Documentation for 5.x.x is nearly the same as 6.0.0. Use current documentation for those versions.

Migrate from 2.x.x to 3.0.0

Migration guide is available here.

Migrate from 3.x.x to 4.0.0

Migration guide is available here.

Migrate from 4.0.x to 5.0.0

Migration guide is available here.