A simple script to export your articles from Omnivore into a CSV format.
Install dependencies, using Bun:
bun installRename the .env.example file to .env:
mv .env.example .envAnd replace the XXXs on the .env file with your Omnivore API Key.
To get and export to CSV all your articles, run the following command:
bun run index.tsYou can pass a Omnivore search query to filter the articles that will be exported:
bun run index.ts --search-query "label:Cooking,Fitness"This is useful if you're going to import the articles to another service, and want to easily know which items came from this export:
bun run index.ts --add-tag "your_tag_name_here"If you want to get the data in JSON format too:
bun run index.ts --save-intermediate-filesThis is will only include the title, url, labels, creation date and description of the articles.
Saved in a format that can be imported to Raindrop:
bun run index.ts --full-data falseYou can use and combine all options at once:
bun run index.ts --save-intermediate-files --full-data false --add-tag "your_tag_name_here" --search-query "label:Cooking,Fitness"