Agent setup

Codex Twitter setup for saving X media to Google Drive or Dropbox.

Copy this into Codex, OpenClaw, Hermes, or Claude so it can choose the browser extension for human use or Tweety CLI for terminal workflows, connect Twitter Google Drive integration or Twitter Dropbox integration, then test a public Twitter/X media save.

Codex Twitter quick answer

Ask Codex to install Tweet Media Archive from the official browser store or Tweety CLI installer, choose Google Drive, Dropbox, or Downloads, and test one public X/Twitter media URL before batch saves. For cloud storage, use Twitter Google Drive integration setup when the destination is Drive, or Twitter Dropbox integration setup when the destination is Dropbox. If you want the shorter landing page for this query, use the Codex Twitter media archive setup guide.

Twitter Google Drive and Dropbox setup

For Twitter Google Drive integration, connect Google Drive in Tweet Media Archive, choose the Drive folder, then paste one X/Twitter post, bookmark, or profile-media URL to verify the upload. For Twitter Dropbox integration, connect Dropbox, choose the Dropbox folder, then test the same way. After one successful save, use batch/profile/bookmark workflows for repeated archiving.

Related setup guides

Questions

Can Codex install Tweet Media Archive?

Yes. This setup page gives agent-ready instructions for Codex, Claude Code, OpenClaw, Hermes, and similar agents to install the browser extension or native Tweety CLI.

Should agents download a ZIP from the website?

No. For normal setup, agents should use the official Chrome Web Store or Firefox Add-ons listing. Manual ZIP or unpacked setup is only for explicit development requests.

Can agents help test Dropbox or Google Drive saving?

Yes. After install, agents can help configure the selected destination and verify with one public media URL before batch work.

What should I ask Codex for Twitter media saves?

Ask Codex to install Tweet Media Archive from the official store or CLI installer, choose Google Drive, Dropbox, or Downloads, and test one public X/Twitter media URL before batch saves.

Copy prompt
Use these instructions to install, configure, test, or troubleshoot Tweet Media Archive.

Pick the right product:
- For a human who wants to click in the browser: install the Tweet Media Archive browser extension from the official browser store.
- For OpenClaw, Hermes, Codex, Claude Code, or another terminal/agent workflow: install the native Tweety CLI.

Tweety CLI install for macOS or Linux:
curl -fsSL https://tzhgta2ij2.ufs.sh/f/oJWt3WrKF74p9WvwsCI1NQjLODYZ73XbxFGlKTB4p5VCowrq | sh

After CLI install:
1. Run tweety --help to inspect commands.
2. Run tweety to open the keyboard TUI.
3. Run tweety login google-drive, tweety login dropbox, tweety login x, tweety login instagram, tweety login reddit, or tweety login license to connect storage and website sessions.
4. For agents, prefer machine-readable commands such as tweety save --json <url> or tweety save --stdin --ndjson when available.
5. Verify with one public media URL before batch work.

Use the official browser store install by default for browser-extension setup: Chrome Web Store for Chrome/Chromium browsers, and Firefox Add-ons for Firefox or Zen Browser. Do not look for or download a ZIP from tweetmediaarchive.com unless the user explicitly asks for a manual/unpacked build.

Chrome Web Store: https://chromewebstore.google.com/detail/ojicpdlgnoidfggebaifkbcifhamahff
Firefox Add-ons: https://addons.mozilla.org/en-US/firefox/addon/tweet-media-archive/

Install from Firefox Add-ons:
1. Open Firefox or Zen Browser.
2. Open the Firefox Add-ons listing:
   https://addons.mozilla.org/en-US/firefox/addon/tweet-media-archive/
3. Click Add to Firefox.
4. Confirm Add.
5. Open about:addons and confirm Tweet Media Archive is installed and enabled.
6. Open the extension Preferences or Options page.

No website ZIP, unzip, build, Developer mode, or Load unpacked step is required for normal setup.

Choose storage:
The extension saves resolved media to Dropbox, Google Drive, or local Downloads. Pick one provider in Options, save the setting, then connect that provider if it uses OAuth.

Local Downloads setup:
1. Choose Local in Options.
2. Save changes.
3. Optional: edit the local folder name. The default is Downloads/Tweet Media Archive.
4. No OAuth is required for Local.

Before configuring OAuth, ask the user which setup path they want:
1. Built-in/default OAuth - easier and faster. Use the OAuth client IDs already included in the extension where possible.
2. Custom OAuth - for users who want their own Dropbox app key, Google OAuth client, or production-owned cloud setup.

If the user is unsure, recommend built-in/default OAuth first because it is the fastest path to testing the extension.

Dropbox setup:
For built-in/default setup, use the Dropbox app key already shown in the extension UI if available, then connect Dropbox from Options.

For custom OAuth:
1. Open the Dropbox App Console: https://www.dropbox.com/developers/apps
2. Create an app with Scoped access.
3. Choose Full Dropbox.
4. Add this redirect URI exactly:
   https://ojicpdlgnoidfggebaifkbcifhamahff.chromiumapp.org/dropbox
   If the user explicitly loaded the source as an unpacked development extension, use:
   https://mjcnbjnemgoimodoenpnohfianlgnidc.chromiumapp.org/dropbox
5. Copy the Dropbox app key.
6. In extension Options, paste it into Dropbox app key.
7. Save OAuth settings.
8. Click Connect Dropbox.
9. Approve the Dropbox auth window.

Do not ask for or store a Dropbox app secret. The extension uses the public app key with the Chrome identity redirect flow.

Google Drive setup:
For built-in/default setup, use the checked-in Google OAuth client IDs. For most users:
1. Choose Google Drive in Options.
2. Click Save changes.
3. Click Connect Google Drive.
4. Approve the Google sign-in window.

For custom OAuth with a fresh Google Cloud project:
1. Enable the Google Drive API.
2. Create an OAuth client with application type Chrome Extension.
3. Use extension ID ojicpdlgnoidfggebaifkbcifhamahff for the Chrome Web Store install.
   Use mjcnbjnemgoimodoenpnohfianlgnidc only if the user explicitly loads the source as an unpacked development extension.
4. Put the Chrome Extension OAuth client ID in manifest.json under oauth2.client_id.
5. If a Chromium shell cannot complete chrome.identity.getAuthToken(), create a Web Application OAuth client and add this redirect URI:
   https://ojicpdlgnoidfggebaifkbcifhamahff.chromiumapp.org/
6. Put that public Web client ID in GOOGLE_DRIVE_WEB_CLIENT_ID in background.js.

Never put a Google OAuth client secret in the extension.

Optional account access:
For private or login-gated media:
1. Sign into x.com, twitter.com, or instagram.com in the same browser profile.
2. Open the extension setup/options UI.
3. Use Connect my X account or Connect my Instagram account.

Saved account cookies stay in extension-local browser storage. Do not copy these tokens into source, logs, issues, or support messages.

How to use:
1. Open the extension popup.
2. Paste an x.com, twitter.com, Instagram, bookmark, profile media, or direct media URL.
3. Choose or confirm the destination folder.
4. Start the upload.
5. Open Past uploads to verify what was saved.

Supported source types include X/Twitter posts, X bookmarks, X profile media pages, Instagram posts/reels, and direct media URLs.

Validate setup:
After setup, test with one public X/Twitter media post first.

Check:
- Popup shows a storage provider connected.
- Upload status reaches a completed state.
- The file appears in Dropbox, Google Drive, or local Downloads.
- Past uploads lists the pasted URL and saved filename.

For code edits, run:
node --check background.js
node --check popup.js
node --check options.js
node --check history.js

Common problems:
- Dropbox auth fails: verify the redirect URI exactly matches https://ojicpdlgnoidfggebaifkbcifhamahff.chromiumapp.org/dropbox for the Chrome Web Store install.
- Firefox auth fails: do not reuse Chrome-only extension IDs or chromiumapp.org redirect URIs blindly. Inspect the installed Firefox build/source for its Gecko ID and identity redirect URL before changing OAuth provider settings.
- Google auth returns access denied: ensure the Google Auth Platform audience is External and publishing status is In production.
- Google Drive uploads fail after auth: confirm the Drive API is enabled and the OAuth client ID belongs to this extension ID.
- Private X/Instagram media fails: refresh the saved account session from the extension setup UI after signing into the site in the same browser.
- Payment restore fails: confirm the ExtensionPay project for tweet-to-dropbox is configured.

Safety rules:
- Do not commit OAuth secrets, refresh tokens, cookies, Dropbox tokens, Google tokens, or user media.
- Do not replace the checked-in extension key unless the user wants a new development extension ID and new OAuth redirect URIs.
- Do not download, package, or upload release zips unless the user asks for a manual/unpacked build.
- Do not remove existing user changes in the working tree.
- Treat public OAuth client IDs and the ExtensionPay app ID as identifiers, not secrets.