{"id":28254995,"url":"https://github.com/chargebee/blog-starter","last_synced_at":"2025-08-28T04:40:12.043Z","repository":{"id":171214498,"uuid":"647268351","full_name":"chargebee/blog-starter","owner":"chargebee","description":"Notion-powered blog starter with @chargebee and @vercel https://www.chargebee.com/tutorials/chargebee-notion-blog-starter/","archived":false,"fork":false,"pushed_at":"2023-06-26T09:03:26.000Z","size":3005,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":16,"default_branch":"main","last_synced_at":"2025-06-16T06:47:14.133Z","etag":null,"topics":["medium","plg"],"latest_commit_sha":null,"homepage":"","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/chargebee.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,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-05-30T12:20:13.000Z","updated_at":"2024-09-08T15:42:30.000Z","dependencies_parsed_at":"2024-03-30T23:15:16.781Z","dependency_job_id":null,"html_url":"https://github.com/chargebee/blog-starter","commit_stats":null,"previous_names":["chargebee/cb-blog-starter","chargebee/blog-starter"],"tags_count":0,"template":true,"template_full_name":null,"purl":"pkg:github/chargebee/blog-starter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chargebee%2Fblog-starter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chargebee%2Fblog-starter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chargebee%2Fblog-starter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chargebee%2Fblog-starter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chargebee","download_url":"https://codeload.github.com/chargebee/blog-starter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chargebee%2Fblog-starter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272439646,"owners_count":24935422,"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","status":"online","status_checked_at":"2025-08-28T02:00:10.768Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","plg"],"created_at":"2025-05-19T20:16:42.358Z","updated_at":"2025-08-28T04:40:12.000Z","avatar_url":"https://github.com/chargebee.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Chargebee Notion Blog Starter\n\nThis is sample Next.js starter site that uses Notion as CMS and Chargebee for managing membership subscriptions.\n\n[Learn how to get started with this template in an in-depth tutorial!.](https://www.chargebee.com/tutorials/chargebee-notion-blog-starter/)\n\nAuthentication and user profile information is stored in [Supabase](https://supabase.com/) (PostgreSQL).\n\n## Screenshot\n\n\u003cimg src=\"https://github.com/chargebee/blog-starter/blob/main/meta/bharathvaj.png?raw=true\"\u003e\n\n**Demo**: https://chargebee-blog-starter.vercel.app/\n\n## Features\n\n🚀 Fast and responsive\n\n- Fast page render and responsive design\n- Fast static and server side generation with efficient compiler\n\n🔥 Membership\n\n- Manage membership with Chargebee subscription easily\n\n🤖 Deploy instantly\n\n- Deploy on Vercel/Netlify in minutes\n- Incremental regeneration and no need to redeploy after update the content in notion\n\n🚙 Fully functional\n\n- Comments, full width page, quick search and tag filter\n- RSS, analytics, web vital... and much more\n\n🎨 Easy for customization\n\n- Rich config options, support English \u0026 Chinese interface\n- Built with Tailwind CSS, easy for customization\n\n🕸 Pretty URLs and SEO friendly\n\n- Automatic OG image generation\n- Meta tag generation to unfurl meta information on social platforms\n\n## Built With\n\n- [Next.js](https://nextjs.org/) – Framework\n- [Tailwind CSS](https://tailwindcss.com/) - Styling\n- [Notion](https://www.notion.so/) – Content\n- [Chargebee](https://www.chargebee.com/) – Subscription Management\n- [Supabase](https://supabase.com/) - Database \u0026 Authentication\n\n## Getting Started\n\nThis project requires a recent version of Node.js (we recommend \u003e= 16).\n\n- Star this repo 😉\n- Duplicate [this Notion template](https://bharathvaj-ganesan.notion.site/d51a395709e74a9eaae9f2cd3895f98c?v=1d2ea9e6652e4d508439ed5a9a73e08d). Make sure it is not public.\n- Fork this project by clicking on `Use this template` action.\n- Customize [blog.config.js](https://github.com/chargebee/blog-starter/blob/main/blog.config.js). All config is defined in this file.\n- (Optional) Replace favicon.png in /public folder with your own.\n- For local development, run `cp .env.example .env.local` and update the following env properties.\n\n### Configuration\n\n| **Env Property**              | **How to get it ?**                                                                                            |\n| ----------------------------- | -------------------------------------------------------------------------------------------------------------- |\n| NOTION_PAGE_ID                | The ID of the Notion page you previously shared to the web, usually has 32 digits after your workspace address |\n| NOTION_ACCESS_TOKEN           | Notion Access Token                                                                                            |\n| SUPABASE_SERVICE_KEY          | Supabase Admin Key                                                                                             |\n| NEXT_PUBLIC_SUPABASE_URL      | Supabase project public URL.                                                                                   |\n| NEXT_PUBLIC_SUPABASE_ANON_KEY | Supabase anonymous key.                                                                                        |\n| NEXT_PUBLIC_CHARGEBEE_DOMAIN  | Chargebee Domain name.                                                                                         |\n| CHARGEBEE_API_KEY             | Chargebee's Full access key.                                                                                   |\n| DEFAULT_PLAN                  | Your default item plan id. - Eg. free                                                                          |\n| API_ROUTE_SECRET              | Admin Secret Key to access our API                                                                             |\n\n\u003cdetails\u003e\u003csummary\u003eHow to get Notion related envs\u003c/summary\u003e\n\u003cimg src=\"https://github.com/chargebee/blog-starter/blob/main/meta/Notion-page-id.png?raw=true\"\u003e\n\u003cimg src=\"https://github.com/chargebee/blog-starter/blob/main/meta/Notion-token.png?raw=true\"\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eHow to get Supabase related envs\u003c/summary\u003e\n\u003cimg src=\"https://github.com/chargebee/blog-starter/blob/main/meta/Supabase.png?raw=true\"\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eHow to get Chargebee related envs\u003c/summary\u003e\n\u003cimg src=\"https://github.com/chargebee/blog-starter/blob/main/meta/Chargebee.png?raw=true\"\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eHow to get API Route secret\u003c/summary\u003e\nRun this terminal command and use the value.\n\n`openssl rand -base64 32`\n\n\u003c/details\u003e\n\n- Run this following seed command once to setup Chargebee.\n  `pnpm seed`\n\n  This will create product catalog configuration needed for this blog starter to work. You can customize generated product catalog as per your preference.\n\n- That's it! Easy-peasy? You now have blog running locally.\n- Now you can deploy to Vercel using the following button and update the env property values.\n\n[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/git/external?repository-url=https://github.com/chargebee/blog-starter/tree/main\u0026project-name=chargebee-notion-blog\u0026repository-name=chargebee-notion-blog)\n\n- Configure Supabase.\n\n  - Copy the [seed.sql](https://github.com/chargebee/blog-starter/blob/main/supabase/seed.sql) and in a freshly created Supabase project. Go to SQL Editor and run this sql script. This will create required tables, triggers and functions.\n  - You also need to create a webhook in Supabase that watches the row insertions and triggers a HTTP call to our application to create new customer in Chargebee.\n  - Finally configure Supabase Auth. You can add social SSO based on your requirement easily from Supabase console.\n\n- Configure Chargebee\n\n  - Create new webhook with path `{REPLACE_YOUR_BASE_URL}/api/webhooks`. This will allow Chargebee to inform our application about the subscription changes happening at their end.\n  - \u003cdetails\u003e\u003csummary\u003eHow does it will look like\u003c/summary\u003e\n    \u003cimg src=\"https://github.com/chargebee/blog-starter/blob/main/meta/Chargebee-webhook.png?raw=true\"\u003e\n    \u003c/details\u003e\n\n    \u003cdetails\u003e\u003csummary\u003eHow to create ?\u003c/summary\u003e\n    1. Webhook Name: create_chargebee_customer\n    2. Conditions: Table - profiles; Event - insert \n    3. Type of Webhook - HTTP POST\n    4. Headers \n      - Content-type: application/json\n      - x-api-secret: {{REPLACE_WITH_API_ROUTE_SECRET}}\n    5. Create\n    \u003c/details\u003e\n\n- Awesome. It's your time to write content. 🎉\n\n\u003cdetails\u003e\u003csummary\u003eHow to set the pricing for a blog content ? - Free / Premium\u003c/summary\u003e\n  Simply set the pricing column of the blog content to be either free / premium. Please note that these are plan names configured in Chargebee's account.\n  \u003c/details\u003e\n\n## Contributing\n\nWe love our contributors! Here's how you can contribute:\n\n[Open an issue](https://github.com/chargebee/blog-starter/issues/new) if you believe you've encountered a bug.\n[Make a pull request](https://github.com/chargebee/blog-starter/pulls) to add new features/make quality-of-life improvements/fix bugs.\n\n### How can this be taken forward ?\n\n- **Caching**\n\n  Currently, we are pulling information directly from Notion via API (This might cause latency issue). We can add caching layer with cache bursting strategy to reflect the latest information from Notion Database.\n\n- **Personalization**\n\n  Showing personalized blog posts similar to [Medium.com](https://medium.com/)\n\n## License\n\nInspired by [Notion Blog](https://github.com/chargebee/blog-starter), this starter is open-source under the MIT. You can find it [here](https://github.com/chargebee/blog-starter/blob/main/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchargebee%2Fblog-starter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchargebee%2Fblog-starter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchargebee%2Fblog-starter/lists"}