Highlights
Introduced identity registration in auth domain
🚧 Breaking change
We have separated identity registration from authentication. For context about why this decision was made see #8683.
Introduced endpoint /auth/[scope]/[provider]/register
We have added an endpoint specifically for registering new identities. This change will only be used by providers that require registration, such as email-password.
Introduced method register
in auth provider and auth module
We have introduced a new method register
to the auth provider and auth module interfaces. This change will only be used by providers that require registration, such as email-password.
Examples of new authentication flows
Sign up with email-password:
POST /admin/invites -> admin creates invite
POST /auth/user/emailpass/register -> user registers identity
POST /admin/invites/accept -> invite is accepted passing the invite + auth token
Sign in with email-password:
POST /auth/user/emailpass -> authenticate with email-password
GET /admin/users/me -> get authenticated user
Sign up with Google:
POST /auth/user/google -> redirects to Google auth
POST /auth/user/google/callback -> Google hits callback URL, authenticates, and responds with user
POST /admin/invites/accept -> invite is accepted passing the invite + auth token
Sign up with Google:
POST /auth/user/google -> redirects to Google auth
POST /auth/user/google/callback -> Google hits callback URL, authenticates, and responds with user
GET /admin/users/me -> get authenticated user
Sign up as customer with email-password:
POST /auth/customer/emailpass/register -> customer registers identity
POST /store/customers -> customer is created
Sign in with email-password:
POST /auth/customer/emailpass -> authenticate customer with email-password
CLI commands to manage database operations
We have added a new namespace to our CLI specifically for database operations db:
.
Alongside the namespace, a range of new commands have been introduced:
db:create
: The command creates the database (if it is missing) and updates the .env filedb:migrate
: This command will run the migrations and sync the links, unless --skip-links flag is specifieddb:rollback
: Rolls-back last batch of migrations for one or more selected modulesdb:generate:
Generates migrations for one or more selected modulesdb:sync-links
: Ensures links between modules are in sync
Events
We have (re)introduced events in the product domain:
"product-category.created"
"product-category.updated"
"product-category.deleted"
"product-collection.created"
"product-collection.updated"
"product-collection.deleted"
"product-variant.updated"
"product-variant.created"
"product-variant.deleted"
"product.updated"
"product.created"
"product.deleted"
Documentation: Redesign completed
We have completed redesigning our documentation for Medusa 2.0, which includes an updated layout and a range of new components improving the overall user experience.
Explore the updated documentation here.
Documentation: Re-introduced AI assistant (beta)
We have (re)introduced our AI assistant for Medusa 2.0 to help guide you through our documentation and find what you are looking for as fast as possible.
Try out the new AI assistant here.
Features
- feat(dashboard): Hitting escape restores previous value by @kasperkristensen in #8654
- feat(workflows-sdk): log on error by @carlos-r-l-rodrigues in #8666
- feat(dashboard,core-flows,js-sdk,types,link-modules,payment): ability to copy payment link by @riqwan in #8630
- feat(dashboard): Wrap each route in an ErrorBoundary by @kasperkristensen in #8674
- feat(core-flows): create or update payment collections in RMA flows by @riqwan in #8676
- feat(dashboard,core-flows,js-sdk,types): ability to mark payment as paid by @riqwan in #8679
- feat(dashboard,core-flows): ability to refund payment post RMA flow by @riqwan in #8685
- fix(core-flows): account for unfulfilled items while generating order status by @riqwan in #8698
- feat(dashboard): add activities for order - claim, exchange, payment by @riqwan in #8702
- feat(core-flows): order edit request by @carlos-r-l-rodrigues in #8705
- chore(order): align mikroorm <> order module by @riqwan in #8710
- feat(fulfillment,order): add created_by fields to fulfillment, return, claim, exchange by @riqwan in #8711
- feat(medusa,types,core-flows): apply created_by values - claims, exchanges, returns, fulfillment by @riqwan in #8712
- feat: add missing crud to provider identity service by @christiananese in #8717
- feat(utils): use dotenv-expand to allow variables within env by @shahednasser in #8720
- feat(dashboard): order edit UI by @fPolic in #8700
- feat(core-flows,dashboard): adds item validations for claims, returns and exchanges by @riqwan in #8735
- feat(create-medusa-app): set database name to project name by @shahednasser in #8727
- feat(dashboard,types): add active order change panel - claims, exchanges & returns by @riqwan in #8738
- feat: add env editor utility to edit update .env files by @thetutlage in #8741
- feature: add db:create command by @thetutlage in #8760
- fix(dashboard): summary section return fixes by @fPolic in #8770
- feat: add sync links command by @thetutlage in #8775
- feat: move migrations commands to the new db namespace by @thetutlage in #8810
- feat: create auth provider identity by @christiananese in #8675
- feat: Separate registration from authentication in auth domain by @olivermrbl in #8683
- feat(dashboard): cancel return request by @fPolic in #8761
Bugs
- fix(dashboard): Use proper heading size by @kasperkristensen in #8658
- fix(promotion): validate rules accurately when attribute is scoped by context by @riqwan in #8655
- fix(payment-stripe): fix smallest unit calculation by @carlos-r-l-rodrigues in #8663
- fix: maintain connections pool by @thetutlage in #8670
- fix(dashboard): Fix minor issues with Reservations and Inventroy Create forms by @kasperkristensen in #8657
- chore(order): preview removed items by @carlos-r-l-rodrigues in #8680
- fix(dashboard): bust order preview cache to reset fulfilled quantity by @riqwan in #8687
- fix(types): pluralize by @carlos-r-l-rodrigues in #8709
- fix: enable next actions bar when refund is available by @riqwan in #8719
- fix(core-flows): allow backorder by @carlos-r-l-rodrigues in #8721
- fix: Log on error by default in async workflow executions by @sradevski in #8723
- chore(core-flows): test allow backorder by @carlos-r-l-rodrigues in #8725
- fix(admin-next,types): fixes order page from breaking in admin server by @riqwan in #8730
- fix(payment-stripe): fix rounding by @carlos-r-l-rodrigues in #8753
- fix: Doing update to cart with shipping options set removes them by @sradevski in #8752
- fix(orchestration, workflow-sdk): Local workflow separated orchestrator by @adrien2p in #8765
- fix: add missing typings to create provider identity by @christiananese in #8677
- fix: Cleanup error output and do not add red color to help output by @thetutlage in #8778
- fix(core-flows,order): return damaged items by @carlos-r-l-rodrigues in #8818
- fix(product): Add metadata to property to product category data model by @Alexnortung in #8766
Documentation
- docs: improve main docs and resources sidebar by @shahednasser in #8664
- docs: remove link to events reference by @shahednasser in #8669
- breaking: remove POSTGRES prefix env variables in favor of DATABASE prefix by @thetutlage in #8672
- docs: redesign notes by @shahednasser in #8661
- docs: redesign tables by @shahednasser in #8653
- docs: redesign footer by @shahednasser in #8651
- docs: redesign vertical tabs by @shahednasser in #8673
- docs: redesign cards by @shahednasser in #8671
- docs: fix category not opening in api reference from algolia search by @shahednasser in #8690
- docs: fix response code snippet in api reference by @shahednasser in #8689
- docs: fix broken pages due to remark plugin by @shahednasser in #8694
- chore: update the medusa config TSDocs + options by @shahednasser in #8697
- docs: redesign API runner by @shahednasser in #8688
- docs: fix tooltip placement and width in workflows reference by @shahednasser in #8691
- docs: fix algolia cron script by @shahednasser in #8701
- docs: design polish by @shahednasser in #8696
- docs: fix link to payment concept guide in sidebar by @shahednasser in #8708
- docs: add a note about installing preview version by @shahednasser in #8648
- docs: refactor medusa workflows reference by @shahednasser in #8692
- docs: fix link href for Cart module by @ahrbil in #8713
- docs: second round of polishing by @shahednasser in #8724
- docs: redesign search + re-introduce ai assistant in v2 docs by @shahednasser in #8678
- docs: change notes across docs based on redesign by @shahednasser in #8662
- docs: update to include Supabase S3 File Provider by @420coupe in #8715
- docs(ui): update 3.4 Modules & Services v2 documentation by @WEEFAA in #8751
- docs: delete all core-flows reference by @shahednasser in #8777
- chore: Remove
prepublishOnly
script by @olivermrbl in #8699 - docs: added new guides and troubleshooting related to admin development by @shahednasser in #8739
- docs: update create payment collection route usage in store development by @shahednasser in #8736
- docs: add a note about the middleware regular expression by @shahednasser in #8742
- docs: [3/n] generate core-flows reference by @shahednasser in #8784
- docs: [5/n] generate core-flows reference by @shahednasser in #8786
- docs: [4/n] generate core-flows reference by @shahednasser in #8785
- docs: [1/n] generate core-flows reference by @shahednasser in #8782
- docs: [2/n] generate core-flows reference by @shahednasser in #8783
- docs: [6/n] generate core-flows reference by @shahednasser in #8787
- docs: [7/n] generate core-flows reference by @shahednasser in #8788
- docs: [8/n] generate core-flows reference by @shahednasser in #8789
- docs: [9/n] generate core-flows reference by @shahednasser in #8790
- docs: [10/n] generate core-flows reference by @shahednasser in #8791
- docs: [11/n] generate core-flows reference by @shahednasser in #8792
- docs: [12/n] generate core-flows reference by @shahednasser in #8793
- docs: [13/n] generate core-flows reference by @shahednasser in #8794
- docs: [14/n] generate core-flows reference by @shahednasser in #8795
- docs: [15/n] generate core-flows reference by @shahednasser in #8796
- docs: [16/n] generate core-flows reference by @shahednasser in #8799
- docs: [17/n] generate core-flows reference by @shahednasser in #8800
- docs: [18/n] generate core-flows reference by @shahednasser in #8801
- docs: [19/n] generate core-flows reference by @shahednasser in #8802
- docs: [20/n] generate core-flows reference by @shahednasser in #8803
- docs: [21/n] generate core-flows reference by @shahednasser in #8804
- docs: [22/n] generate core-flows reference by @shahednasser in #8805
- docs: [23/n] generate core-flows reference by @shahednasser in #8807
- docs: [24/24] generate core-flows references by @shahednasser in #8809
- docs: generate sidebar and other data related to core-flows reference by @shahednasser in #8811
- docs: updates following authentication flow changes by @shahednasser in #8706
Chores
- chore(core-flows): set packed_at when fulfillment is created by @carlos-r-l-rodrigues in #8665
- chore(core-flows): order update item quantity by @carlos-r-l-rodrigues in #8659
- chore(core-flows): move cart and line item flows outside definition by @shahednasser in #8703
- chore(core-flows): order edit - remove item update action by @carlos-r-l-rodrigues in #8722
- chore: dependecies reorg by @carlos-r-l-rodrigues in #8535
- chore: dependencies reorg by @carlos-r-l-rodrigues in #8744
- chore: peer dependency version by @carlos-r-l-rodrigues in #8771
- chore(core-flows): product workflows events by @carlos-r-l-rodrigues in #8769
New Contributors
- @ahrbil made their first contribution in #8713
- @WEEFAA made their first contribution in #8751
- @Alexnortung made their first contribution in #8766
Full Changelog: v2.0.5-preview...v2.0.6-preview