Skip to content

abdullah-afzal/medusa-bundled-products

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📦 medusa-bundled-products

A Medusa plugin that adds bundled product functionality, allowing you to create and manage product bundles that combine multiple products into a single offering. Perfect for kits, starter packs, and promotional combos, base on medusa example for bundles.


✨ Features

  • Create bundled products with linked products
  • Set custom pricing for bundles
  • Integrates seamlessly with Medusa’s core product and variant models
  • Supports cart and order handling for bundles
  • Easily extendable for storefront display

🔄 Compatibility

  • Medusa version: @medusajs/medusa >= 2.4.0

📦 Installation

  1. Install the plugin:

    npm install medusa-bundled-products
    # or
    yarn add medusa-bundled-products
  2. Add it to your medusa-config.js:

    module.exports = defineConfig({
      // ...
      plugins: [
        {
          resolve: "medusa-bundled-products",
          options: {
            // Optional configuration
          },
        },
      ],
    });
  3. Run Migrations:

     npx medusa db:migrate

🚀 API Endpoints

Admin Endpoints

  • POST /admin/bundled-products → Create a bundled product
  • GET /admin/bundled-products → List all bundled products

Storefront Endpoints

  • GET /store/bundled-products/:id → Get a specific bundled product
  • POST /store/cart/:id/line-item-bundles → Add a bundle to a cart
  • DELETE /store/cart/:id/line-item-bundles/:bundle_id → Remove a bundle from a cart

🛒 Cart Behavior

This plugin ensures bundles are treated as a single unit in the cart:

  • Adding/removing updates all associated items together
  • Pricing and inventory are handled accurately for all bundle components

💡 Proposals, Bugs, Improvements

If you have ideas, feature requests, or bug reports, please open an issue.


💼 Pro Version

A Pro version is available under a commercial license — contact me for details.


📜 License

© 2024 abdullah-afzal — All rights reserved.


About

A Medusa plugin that adds bundled product functionality, allowing you to create and manage product bundles that combine multiple products into a single offering. Perfect for kits, starter packs, and promotional combos, base on medusa example for bundles.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Contributors