Skip to main content

Export all VS Code GitHub Copilot Chat conversations to JSON and Markdown.

Project description

copilotexport

Export all of your VS Code GitHub Copilot Chat conversations — including full tool-call history — to JSON and Markdown. Mirrors the layout of ChatGPT and Claude exports.

Installation

pip install copilotexport

Usage

CLI

# Export everything to ./_copilot/ and create CopilotExport.zip
copilotexport

# Custom source and output
copilotexport --src /path/to/Code/User/workspaceStorage --out ~/my-export

# Skip Markdown rendering (index + raw JSON only, much faster)
copilotexport --no-markdown

# Skip the zip file
copilotexport --no-zip

# Skip copying raw VS Code JSON (markdown + index only)
copilotexport --no-raw

# Bundle every session into a single zip ready to upload to AGiXT's
# /v1/conversation/import endpoint (auto-detected as the 'copilot' source).
copilotexport --agixt-zip ~/CopilotForAGiXT.zip

Importing into AGiXT

--agixt-zip PATH writes a zip containing a single conversations.json — a JSON array of raw VS Code session dicts. Upload it through the Import Conversations control on the AGiXT settings page, or POST it directly:

curl -F file=@CopilotForAGiXT.zip -F agent_name=XT \
     -H "Authorization: $JWT" \
     http://localhost:7437/v1/conversation/import

AGiXT detects the format as copilot, prefixes imported conversations with [Copilot], and renders Copilot tool invocations as [SUBACTIVITY] blocks in the chat UI.

Python API

from copilotexport import export, default_workspace_storage
from pathlib import Path

summary = export(
    src=default_workspace_storage(),
    out=Path("_copilot"),
    write_markdown=True,
    make_zip=True,
    copy_raw=True,
)
print(summary)

Output layout

_copilot/
├── export_info.json                         # run summary
├── index.json                               # flat metadata for all sessions
├── workspaces.json                          # wsHash → folder URI map
├── sessions/
│   └── <workspace_label>/
│       └── <sessionId>.json                 # verbatim VS Code session file
└── markdown/
    └── <workspace_label>/
        └── <YYYY-MM-DD>_<title>_<id8>.md   # human-readable transcript

Each Markdown transcript includes:

  • Session metadata (title, session ID, timestamps, model, agent)
  • User messages
  • Assistant responses with prose rendered inline
  • Tool calls rendered as structured blocks showing the tool name, request summary, result summary, and any file paths touched

Platform support

VS Code's workspaceStorage is auto-detected on Linux, macOS, and Windows.

OS Default path
Linux ~/.config/Code/User/workspaceStorage
macOS ~/Library/Application Support/Code/User/workspaceStorage
Windows %APPDATA%\Code\User\workspaceStorage

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

copilotexport-0.0.2.tar.gz (10.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

copilotexport-0.0.2-py3-none-any.whl (10.4 kB view details)

Uploaded Python 3

File details

Details for the file copilotexport-0.0.2.tar.gz.

File metadata

  • Download URL: copilotexport-0.0.2.tar.gz
  • Upload date:
  • Size: 10.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for copilotexport-0.0.2.tar.gz
Algorithm Hash digest
SHA256 97d7acbbc0368d9d5617388e5f74ab4c2228f85ee6fd92d250640fae9897da50
MD5 b3873d190170b16b87f4a5fb55b08604
BLAKE2b-256 51e652d0fea156ee0704571c4d6c1a8619177b702a8c415039c0ce5877b4a722

See more details on using hashes here.

File details

Details for the file copilotexport-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: copilotexport-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 10.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for copilotexport-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 f9214a4555b6dfcc09f1a8a59c5e971c797bc8d2c30a994830dcc8a5473dbbe9
MD5 75e56f8360e2c379594c2667ae8fdb33
BLAKE2b-256 be848f57d5323278953eac9c7cf74ac9cbc6f8f9f7a6bba3efc48c66ba038c62

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page