Let guests and users set up wishlists
The Alphabite Wishlist Plugin is the most feature-complete wishlist system for MedusaJS. It supports both authenticated and guest users, multiple wishlists per user, and a full-featured SDK client for frontend integration.
This plugin ships with:
Please install the plugin version that matches your Medusa version:
| Medusa Version | Plugin Version | Install Command |
|---|---|---|
| and above | ||
| Below |
npm install @alphabite/medusa-wishlist
npm install @alphabite/medusa-wishlist@0.5.8
npm install @alphabite/medusa-wishlist@0.5.7
βΉοΈ Using a mismatched version may result in compatibility issues. Make sure to check your Medusa version () before installing.
Install the plugin via npm:
npm install @alphabite/medusa-wishlist
In your , register the plugin:
1const plugins = [2 {3 resolve: "@alphabite/medusa-wishlist",4 options: {5 // all are optional, read bellow about default values6 wishlistFields: [],7 wishlistItemsFields: [],8 includeWishlistItems: true,9 includeWishlistItemsTake: 5,10 allowGuestWishlist: true,11 },12 },13];
| Option | Type | Default | Description |
|---|---|---|---|
| Selectively include Medusa product or product variant fields on wishlist list/retrieve endpoints that have wishlist items included | |||
| Selectively include Medusa product or product variant fields on wishlist items list/retrieve endpoints | |||
| Automatically populate wishlist items in | |||
| Limit number of items if is true | |||
| Enables wishlist creation & usage without authentication (cookie-based) |
The plugin adds a Wishlists page to the admin sidebar () with two tabs: Settings (guest / multiple-wishlist toggles) and Analytics (a read-only dashboard of KPIs, an activity trend, and the most-wishlisted products and variants).
See docs/admin-analytics.md for the analytics endpoint and response shape.
All endpoints are available under .
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| GET | β | List wishlists for the current customer | |
| POST | β (optional) | Create a new wishlist | |
| GET | β (optional) | Retrieve a wishlist by ID | |
| PUT | β | Update wishlist metadata | |
| DELETE | β | Delete a wishlist | |
| POST | β | Transfer guest wishlist to logged-in user | |
| GET | β (optional) | Get items in a wishlist | |
| POST | β (optional) | Add an item to the wishlist | |
| DELETE | β (optional) | Remove an item from the wishlist |
βββRead more about our Medusa compatible SDK here
1import { AlphabiteMedusaClient, wishlistPlugin } from '@alphabite/sdk'23const sdk = new AlphabiteMedusaClient({4 {5 baseUrl,6 debug: process.env.NODE_ENV === "development",7 publishableKey: process.env.NEXT_PUBLIC_MEDUSA_PUBLISHABLE_KEY,8 },9 [wishlistPlugin],10 {11 getAuthHeader: () => { return { authorization: `Bearer ${customerJwt}` } },12 }13})1415// Create wishlist16await sdk.alphabite.wishlist.create({ name: 'My Sneakers' })1718// Add item19await sdk.alphabite.wishlist.addItem({20 id: 'wishlist_id',21 product_variant_id: 'variant_id',22})2324// List items25const { data } = await sdk.alphabite.wishlist.listItems({ id: 'wishlist_id' })
Guest wishlists work like guest carts:
await medusa.alphabite.wishlist.transfer({ id: wishlistId });
After that, the cookie is no longer needed.
Youβll find the ready-to-import Postman collection at:
Use it to explore and test all endpoints interactively.
We welcome issues, feedback, and PRs. Fork it, build it, improve it.
Letβs make commerce more personalized ποΈ