Hi r/computerforensics, I had a matter recently where I needed to forensically collect a user's entire ChatGPT history, projects, conversations, generated images, the whole thing. So I built a toolkit that attaches to a Chrome session via CDP, extracts the auth token, and hits ChatGPT's backend API directly. Every conversation gets saved as an individual JSON file with a SHA-256 hash recorded in a CSV manifest. There's a separate verification script that recomputes all hashes, post-collection, and flags any mismatches, missing files, or untracked artifacts.
A few things that made this harder than expected:
ChatGPT only shows ~5 "pinned" projects in the sidebar API. The rest are hidden, so I had to build a multi-phase discovery process that paginates the sidebar endpoint AND scans the full conversation list to find project IDs the sidebar doesn't return.
Conversations are stored as tree structures (not flat lists) with branch points for edits and regenerations. The tool walks the active branch from current_node back to root.
Team/Enterprise workspaces require a separate account ID header or you only see personal data.
Rate limiting is aggressive, so I built in exponential backoff with automatic retry.
I've also included a script to convert the JSON exports to formatted PDFs (useful for handing off to counsel). It also supports resume, so if it crashes or gets rate-limited mid-run, you re-run and it picks up where it left off.
Open-source for the community: https://github.com/loucdg/chatgpt-forensic-exporter
Even if you don't have a forensic use case right now, it's worth having for backing up your own ChatGPT data. OpenAI has a 24-48 hour delay and the format it exports in is not as usable as this.
This is my first time releasing a tool like this publicly. And yes, I heavily leveraged "vibe coding" to get it done but I've been happy with the results. I have a few other python scripts that I've used during matters that I will upload if there's interest.
Happy to answer questions or take feedback.