Name | Modified | Size | Downloads / Week |
---|---|---|---|
Parent folder | |||
README.md | 2025-08-14 | 10.7 kB | |
v2.9.0 source code.tar.gz | 2025-08-14 | 30.3 MB | |
v2.9.0 source code.zip | 2025-08-14 | 45.0 MB | |
Totals: 3 Items | 75.3 MB | 1 |
Highlights
Throw error on invalid promotions
[!WARNING]
Breaking change
This release updates the promotion application logic to throw when applying an invalid promotion code. This change improves the experience for developers building storefronts by allowing them to handle invalid discount codes directly from the API response, rather than checking cart promotions after the API request.
The backend will respond with a 400 and a message like so:
The promotion code HELLOWORLD is invalid
Add support for logical operators on Index
This release introduces support for logical operators on Index queries, such as:
:::ts
const { data: products } = await query.index({
entity: "product",
filters: {
$and: [
{ status: "published" },
{
$or: [
{ brand: { name: { $ilike: "%adidas%" } } }
]
}
]
}
})
In addition to this, this release also fixes a regression related to indexing custom module entities.
Resolve issue with promotion calculations in a tax-inclusive context
This release resolves an issue with the calculation of adjustments in a tax-inclusive calculation context.
When calculating the applicableTotal
(the maximum amount a promotion can apply to an item), it was incorrectly based on the line item’s subtotal (excluding tax), while the promotion value was based on the total (including tax), causing incorrect adjustment calculations.
Bugs
- fix(core-flows): guest customer updates email to another guest account by @fPolic in https://github.com/medusajs/medusa/pull/13037
- fix(create-medusa-app): Don't allow dot in project name by @olivermrbl in https://github.com/medusajs/medusa/pull/13042
- fix(promotion): check currency when computing actions for promotions by @riqwan in https://github.com/medusajs/medusa/pull/13084
- fix(core-flows): refresh payment collection by @carlos-r-l-rodrigues in https://github.com/medusajs/medusa/pull/13103
- chore(ui): sync Figma resources by @fPolic in https://github.com/medusajs/medusa/pull/13088
- fix(pricing): Calculate prices with multiple rule values by @olivermrbl in https://github.com/medusajs/medusa/pull/13079
- fix(dashboard): variants disappearing when removing an option on product creation by @willbouch in https://github.com/medusajs/medusa/pull/13150
- fix(workflow-engine-inmemory): fix cron job schedule by @carlos-r-l-rodrigues in https://github.com/medusajs/medusa/pull/13151
- fix(index): logical operators by @carlos-r-l-rodrigues in https://github.com/medusajs/medusa/pull/13137
- fix(dashboard,promotion): Fix regression on applying percentage promotions by @riqwan in https://github.com/medusajs/medusa/pull/13161
- fix: Allow getting the token from the SDK client by @sradevski in https://github.com/medusajs/medusa/pull/13164
- fix(types): remove order_id in apis that do not handle it by @willbouch in https://github.com/medusajs/medusa/pull/13185
- fix(tax): Use correct rule reference for shipping by @olivermrbl in https://github.com/medusajs/medusa/pull/13195
Documentation
- docs: update order promotion link details by @shahednasser in https://github.com/medusajs/medusa/pull/13023
- docs: fix vale lint errors by @shahednasser in https://github.com/medusajs/medusa/pull/13024
- chore(docs): Updated UI Reference (automated) by @github-actions[bot] in https://github.com/medusajs/medusa/pull/13026
- docs: fix to OAS generator following Zod update + generate API reference by @shahednasser in https://github.com/medusajs/medusa/pull/13030
- docs: fix bug in layout change when using some chrome extensions by @shahednasser in https://github.com/medusajs/medusa/pull/13031
- docs: document UI route breadcrumbs by @shahednasser in https://github.com/medusajs/medusa/pull/13035
- docs: fix passing linkable for inverse read-only links by @shahednasser in https://github.com/medusajs/medusa/pull/13041
- docs: add section on customer account deletion by @shahednasser in https://github.com/medusajs/medusa/pull/13048
- docs: add how-to guides for retrieving cart and order totals by @shahednasser in https://github.com/medusajs/medusa/pull/13044
- docs: improvements and additions to admin customization chapters by @shahednasser in https://github.com/medusajs/medusa/pull/13049
- docs: document checks examples + migrations naming convention by @shahednasser in https://github.com/medusajs/medusa/pull/13052
- docs: document auto-generated types by @shahednasser in https://github.com/medusajs/medusa/pull/13050
- docs: added examples to DatePicker component by @shahednasser in https://github.com/medusajs/medusa/pull/13054
- docs: general updates to documentation pages by @shahednasser in https://github.com/medusajs/medusa/pull/13055
- docs: migration guide from v1 to v2 by @shahednasser in https://github.com/medusajs/medusa/pull/12597
- docs: open AI assistant based on search query by @shahednasser in https://github.com/medusajs/medusa/pull/13063
- docs: handle recaptcha loading before submitting AI assistant queries by @shahednasser in https://github.com/medusajs/medusa/pull/13065
- Fix spelling error in documentation by @benwrk in https://github.com/medusajs/medusa/pull/13061
- docs: document debugging workflows by @shahednasser in https://github.com/medusajs/medusa/pull/13087
- docs: improved workflows integration tests guide by @shahednasser in https://github.com/medusajs/medusa/pull/13090
- docs: document JSON properties by @shahednasser in https://github.com/medusajs/medusa/pull/13099
- docs: add link to manage metadata section in OAS and API reference by @shahednasser in https://github.com/medusajs/medusa/pull/13102
- docs: improve instructions to install Medusa UI in standalone projects by @shahednasser in https://github.com/medusajs/medusa/pull/13104
- docs: add links to technical guides in user guides by @shahednasser in https://github.com/medusajs/medusa/pull/13108
- docs: update list of resources in module containers + conventions on loaders by @shahednasser in https://github.com/medusajs/medusa/pull/13107
- docs: add more totals to retrieve cart and totals guides by @shahednasser in https://github.com/medusajs/medusa/pull/13110
- docs: updates to nested workflow docs by @shahednasser in https://github.com/medusajs/medusa/pull/13117
- docs: fix search not opening sometimes by @shahednasser in https://github.com/medusajs/medusa/pull/13118
- docs: fix code block titles not showing in UI docs by @shahednasser in https://github.com/medusajs/medusa/pull/13119
- docs: added guide on sending invite user emails + updates to reset password guide by @shahednasser in https://github.com/medusajs/medusa/pull/13122
- docs: add buffer example in workflows + tip for type error in admin global variables by @shahednasser in https://github.com/medusajs/medusa/pull/13124
- docs: document the fetchStream method of the JS SDK by @shahednasser in https://github.com/medusajs/medusa/pull/13125
- docs: change from detecting version to since tag by @shahednasser in https://github.com/medusajs/medusa/pull/13127
- docs: general updates to documentation pages by @shahednasser in https://github.com/medusajs/medusa/pull/13128
- feat: Add MCP instructions for Claude Code by @aldo-roman in https://github.com/medusajs/medusa/pull/13134
- docs: generate invoice tutorial by @shahednasser in https://github.com/medusajs/medusa/pull/13077
- Update page.mdx by @concaveinc in https://github.com/medusajs/medusa/pull/13180
- docs: integrate reo.dev by @shahednasser in https://github.com/medusajs/medusa/pull/13192
Chores
- chore(docs): Update version in documentation (automated) by @github-actions[bot] in https://github.com/medusajs/medusa/pull/13025
- chore(docs): Generated References (automated) by @github-actions[bot] in https://github.com/medusajs/medusa/pull/13027
- chore: fix example in createProductsWorkflow TSDocs by @shahednasser in https://github.com/medusajs/medusa/pull/13112
- chore: add links to package.json by @shahednasser in https://github.com/medusajs/medusa/pull/13100
- chore: use since instead of version tag in TSDocs by @shahednasser in https://github.com/medusajs/medusa/pull/13126
- chore(dashboard): add missing US states by @fPolic in https://github.com/medusajs/medusa/pull/13094
- chore: add willbouch to teams.yml by @willbouch in https://github.com/medusajs/medusa/pull/13141
- chore(core-flows): throw error on invalid promo code by @willbouch in https://github.com/medusajs/medusa/pull/13140
- chore(util): avoid promotion value precision limit by @carlos-r-l-rodrigues in https://github.com/medusajs/medusa/pull/13145
- chore(core-flows): import zod by @carlos-r-l-rodrigues in https://github.com/medusajs/medusa/pull/13197
Other Changes
- fix(dashboard): correct overflow in a few settings edit forms by @SteelRazor47 in https://github.com/medusajs/medusa/pull/11982
- fix: createCustomerGroupsStep rollback, delete created customer groups… by @jbrigbyjs in https://github.com/medusajs/medusa/pull/13056
- This fixes the discount_ calculation logic and promotion tax inclusiveness calculation by @scherddel in https://github.com/medusajs/medusa/pull/12960
- feat: added pacific franc currency by @tehaulp in https://github.com/medusajs/medusa/pull/13086
- fix(types,utils,promotion): Move from total to original_total to resolve edge case for adjustments calculation by @scherddel in https://github.com/medusajs/medusa/pull/13106
- fix(utils):Fix on precision for high quantities for items when promotion is applied by @scherddel in https://github.com/medusajs/medusa/pull/13131
- Made in operator work as In insted of equal logic by @mikkel-lindstrom in https://github.com/medusajs/medusa/pull/13078
New Contributors
- @jbrigbyjs made their first contribution in https://github.com/medusajs/medusa/pull/13056
- @benwrk made their first contribution in https://github.com/medusajs/medusa/pull/13061
- @tehaulp made their first contribution in https://github.com/medusajs/medusa/pull/13086
- @willbouch made their first contribution in https://github.com/medusajs/medusa/pull/13141
- @mikkel-lindstrom made their first contribution in https://github.com/medusajs/medusa/pull/13078
- @concaveinc made their first contribution in https://github.com/medusajs/medusa/pull/13180
Full Changelog: https://github.com/medusajs/medusa/compare/v2.8.8...v2.9.0