{"id":19499504,"url":"https://github.com/stackbit/stackbit-medium-importer","last_synced_at":"2025-04-25T22:34:02.402Z","repository":{"id":43416010,"uuid":"175043047","full_name":"stackbit/stackbit-medium-importer","owner":"stackbit","description":"Stackbit Medium Importer","archived":false,"fork":false,"pushed_at":"2022-12-09T21:44:44.000Z","size":126,"stargazers_count":15,"open_issues_count":14,"forks_count":3,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-10-28T22:40:45.506Z","etag":null,"topics":["medium","stackbit"],"latest_commit_sha":null,"homepage":"https://www.stackbit.com/medium","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stackbit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-03-11T16:42:49.000Z","updated_at":"2021-08-31T15:29:10.000Z","dependencies_parsed_at":"2023-01-25T21:46:09.661Z","dependency_job_id":null,"html_url":"https://github.com/stackbit/stackbit-medium-importer","commit_stats":null,"previous_names":["stackbithq/stackbit-medium-importer"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackbit%2Fstackbit-medium-importer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackbit%2Fstackbit-medium-importer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackbit%2Fstackbit-medium-importer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackbit%2Fstackbit-medium-importer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stackbit","download_url":"https://codeload.github.com/stackbit/stackbit-medium-importer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224019619,"owners_count":17242176,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["medium","stackbit"],"created_at":"2024-11-10T22:04:38.468Z","updated_at":"2024-11-10T22:04:39.383Z","avatar_url":"https://github.com/stackbit.png","language":"JavaScript","readme":"# stackbit-medium-importer\n\nA small library to convert [medium export](https://medium.com/me/export) zip files to static-site-generator (SSG) friendly Markdown files.\n\n# Demo\n\nThe Medium importer can be seen in action on the [Stackbit website](https://www.stackbit.com/medium).\n\n# Install\n\n```\nnpm install @stackbit/stackbit-medium-importer\n```\n\n# How to use\n\nThe module comes with a utility to invoke the importer directly.\n\n```\n$ medium-importer\nUsage: medium-importer --input-file=\u003cinput-file\u003e --output-dir=\u003coutput-dir\u003e --concurrency=\u003cconcurrency\u003e --download-images=\u003cdownload-images\u003e --import-drafts=\u003cimport-drafts\u003e\n\nOptions:\n  --help                 Show help  [boolean]\n  --version              Show version number  [boolean]\n  --input-file, -i       medium export zip file  [required]\n  --output-dir, -o       target folder for the converted files  [required]\n  --concurrency, -c      number of posts to process in parallel [default: 1]\n  --download-images, -d  should images be downloaded [default: true]\n  --import-drafts, -r    should drafts be imported [default: true]\n\nExamples:\n  medium-importer -i medium-export.zip -o output/\n  ```\n\n# Importer output\n\nThe output directory is populated with the imported data, following a structure that makes it straightforward to later use with an SSG. For certain SSG's (like Hugo) it's possible to point the utility directly at your project.\n\nThe output directories can be configured when working with the library directly.\n\n### `content/posts`\n\nMarkdown pages representing imported Medium posts.\n\n```yaml\n---\ntemplate: post\ntitle: My Blog Post\ndate: 2018-10-08T15:01:02.452Z\nsubtitle: \u003e-\n  This post is a posty post, and this is its subtitle.\nexcerpt: \u003e-\n  An excerpt of the post\nthumb_img_path: \u003e-\n  images/My-Blog-Post/image.jpeg\ncontent_img_path: \u003e-\n  images/My-Blog-Post/splash.jpeg\n---\n\n# My Post\n\nMarkdown content goes **HERE**\n```\n\n### `static/images`\n\n* Per-post images organized in directories with the post's slug.\n* Global images extracted from the Medium export: `avatar.png` if available.\n\n\n### `data/data.json`\n\nExtraced information in `JSON` format:\n\n```json\n{\n  \"author\": {\n    \"name\": \"My Name\",\n    \"email\": \"email@example.com\",\n    \"avatar\": \"images/avatar.png\"\n  },\n  \"social\": {\n    \"twitter\": {\n      \"username\": \"@myuser\",\n      \"url\": \"https://twitter.com/@myuser\"\n    }\n  }\n```\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstackbit%2Fstackbit-medium-importer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstackbit%2Fstackbit-medium-importer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstackbit%2Fstackbit-medium-importer/lists"}