{"id":19312147,"url":"https://github.com/bigcommerce/subscription-foundation","last_synced_at":"2025-04-22T15:32:03.471Z","repository":{"id":37718967,"uuid":"485524627","full_name":"bigcommerce/subscription-foundation","owner":"bigcommerce","description":"Foundation for building custom subscription applications w/ BigCommerce","archived":false,"fork":false,"pushed_at":"2023-10-07T01:25:26.000Z","size":2188,"stargazers_count":11,"open_issues_count":8,"forks_count":41,"subscribers_count":11,"default_branch":"main","last_synced_at":"2024-05-28T21:23:52.745Z","etag":null,"topics":["bigcommerce","stripe","subscriptions"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/bigcommerce.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-04-25T20:27:01.000Z","updated_at":"2024-05-28T21:23:52.746Z","dependencies_parsed_at":"2023-02-09T08:46:55.750Z","dependency_job_id":null,"html_url":"https://github.com/bigcommerce/subscription-foundation","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bigcommerce%2Fsubscription-foundation","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bigcommerce%2Fsubscription-foundation/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bigcommerce%2Fsubscription-foundation/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bigcommerce%2Fsubscription-foundation/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bigcommerce","download_url":"https://codeload.github.com/bigcommerce/subscription-foundation/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223900360,"owners_count":17222028,"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":["bigcommerce","stripe","subscriptions"],"created_at":"2024-11-10T00:33:13.888Z","updated_at":"2024-11-10T00:33:14.656Z","avatar_url":"https://github.com/bigcommerce.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BigCommerce Subscription Foundation\n\n🚀 Fast track builds of custom subscription experiences on the BigCommerce platform. Save 100s of hours.\n\n💰 **Pre-integrated into Stripe Billing**, including authentication, merchant onboarding, subscription product management, subscription creation, and customer-facing subscription management.\n\n💅 Utilizes the Channels Toolkit to provide a natively integrated subscription channel that fits nicely within the BigCommerce control panel.\n\n| Product Management                       | Storefront Widget                     |\n| ---------------------------------------- | ------------------------------------- |\n| ![App Preview](sample-control-panel.png) | ![App Preview](sample-storefront.png) |\n\n## Get started\n\nHead to the [Subscription Foundation](https://developer.bigcommerce.com/docs/ae2455ab4d3d8-subscription-foundation) article to begin!\n\n## Deploy with Vercel\n\n[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fbigcommerce%2Fsubscription-foundation\u0026env=NEXT_PUBLIC_APP_URL,DATABASE_URL,NEXT_PUBLIC_BC_APP_ID,BC_APP_CLIENT_ID,BC_APP_SECRET,NEXT_PUBLIC_STRIPE_CLIENT_ID,STRIPE_SECRET_KEY\u0026envDescription=View%20the%20Subscription%20Foudation%20docs%20for%20information%20on%20each%20ENV%20variable.\u0026envLink=https%3A%2F%2Fdeveloper.bigcommerce.com%2Fdocs%2Fae2455ab4d3d8-subscription-foundation\u0026project-name=bigcommerce-subscription-foundation\u0026demo-title=Subscription%20Foundation\u0026demo-description=Helps%20create%20custom%20subscription%20experiences%20for%20BigCommerce.\u0026demo-url=https%3A%2F%2Fgithub.com%2Fbigcommerce%2Fsubscription-foundation%2Fraw%2Fmain%2Fsample-storefront.png\u0026demo-image=https%3A%2F%2Fgithub.com%2Fbigcommerce%2Fsubscription-foundation%2Fraw%2Fmain%2Fsample-storefront.png)\n\n## Key areas of codebase\n\n- `/backend`\n  - Where the auth and various API services live. These are used within the internal API endpoints to keep routes secure and reach out to external APIs.\n- `/prisma`\n  - Where the DB models and initial seed data live. Prisma uses this to generate DB clients for the app.\n- `/shared`\n  - Where the types and helper utilities are located.\n- `/src/pages`\n  - Where the sections of the app, including the UI for the BigCommerce app that will show inside the control panel, are managed.\n  - Next.js docs: https://nextjs.org/docs/basic-features/pages\n- `/src/pages/api`\n  - Where the APIs for the app are managed.\n  - Next.js docs: https://nextjs.org/docs/api-routes/introduction\n    - `/cart`, `/channel`, and `/product`: Contains endpoints that proxy to BigCommerce APIs.\n    - `/store`: Contains endpoints that update app information in the DB.\n    - `/stripe`: Contains endpoints that proxy to Stripe APIs.\n    - `/webhooks/index.ts`: Contains the webhook listener for the \"Order Created\" BigCommerce event which is used to create the initial Stripe subscription.\n- `/src/providers`\n  - Where the context providers used within pages and components live.\n\n## Contributing\n\nWant to help expand this foundation? We'd love to collaborate! To kick off, here's a breakdown of items we've itemized as either potential improvements to the existing codebase or features worth adding.\n\n- Improvements:\n  - Implement cart metafields to improve shopper UX (removes overloading of product name)\n  - Move FE cart requests / calculations within the subscription widget to be handled within a single internal API endpoint\n  - Centralize logging so it's easily turned on / off and connected to third-party logging services\n- Features:\n  - Additional subscription use cases outside of 'Subscribe and Save'\n  - Handling for more complex tax and shipping scenarios, changes occur to price after initial subscription creation\n  - Ability to see subscription information inline, within My Account -\u003e Order section of the storefront\n\n## Learn More\n\n### Additional Subscription Solutions\n\nCheck out the wide variety of subscription apps on the [BigCommerce App Marketplace](https://www.bigcommerce.com/apps/recurring-billing-subscriptions/?source=subscription-foundation).\n\n### The BigCommerce Platform\n\nLooking to help the world's leading brands and the next generation of successful merchants take flight? To learn more about developing on top of the BigCommerce platform, take a look at the following resources:\n\n- [BigCommerce Developer Center](https://developer.bigcommerce.com/?source=subscription-foundation) - Learn more about BigCommerce platform features, APIs and SDKs\n- [BigDesign](https://developer.bigcommerce.com/big-design/?source=subscription-foundation) - An interactive site for BigCommerce's React Components with live code editing\n- [Building BigCommerce Apps](https://developer.bigcommerce.com/api-docs/getting-started/building-apps-bigcommerce/building-apps?source=subscription-foundation) - Learn how to build apps for the BigCommerce marketplace\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbigcommerce%2Fsubscription-foundation","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbigcommerce%2Fsubscription-foundation","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbigcommerce%2Fsubscription-foundation/lists"}