Skip to content

fix(api-service): move workflow dto from shared to api #8009

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 23, 2025

Conversation

tatarco
Copy link
Contributor

@tatarco tatarco commented Mar 26, 2025

Resolve Workflow DTO Issues

What changed? Why was the change needed?

DTO Migration and Enhancements

  • All DTOs were moved from shared into API, converted to classes, and assigned the correct OpenAPI decorators.
  • All of the workflow V2 DTOs are now generated under the @novu-api. All of our E2E tests are now using the SDK and dogfooding the OpenAPI structure.
  • Error DTOs have been enhanced due to issues found in implementation.
  • Class validators are now working on DTOs, enforcing bad data from getting into the service.
  • The filter has been updated to parse those errors elegantly as well.
  • Decoupled the interfaces created in shared from entities; they should not be used anymore. We generate DTOs now, and the client should not care about our database entity; all is clearly presented to him.
  • JSON schema was a complete mess; aligned it all the way to the DAL layer. Some as unknown had to be added in the framework to minimize scope.
  • The preference controller has been deprecated along with all its DTOs since naming was a big confusion and duplication. Deprecated them all in order to know what is new and what is old.
  • Separated DTOs into separate properly named files.

Screenshots

Expand for optional sections

Related enterprise PR

Special notes for your reviewer

Copy link

linear bot commented Mar 26, 2025

Copy link

pkg-pr-new bot commented Mar 26, 2025

Open in StackBlitz

npm i https://pkg.pr.new/novuhq/novu@8009
npm i https://pkg.pr.new/novuhq/novu/@novu/providers@8009
npm i https://pkg.pr.new/novuhq/novu/@novu/shared@8009

commit: 751bd06

Copy link

netlify bot commented Mar 31, 2025

Deploy Preview for dashboard-v2-novu-staging canceled.

Name Link
🔨 Latest commit 751bd06
🔍 Latest deploy log https://app.netlify.com/sites/dashboard-v2-novu-staging/deploys/6808b18fdab3180008001f8a

@tatarco tatarco force-pushed the nv-5295-align-workflow-controller-to-sdk branch from 1b85ee4 to 345883d Compare March 31, 2025 10:31
@tatarco tatarco force-pushed the nv-5295-align-workflow-controller-to-sdk branch from a1d0ad9 to 089c3e6 Compare April 18, 2025 06:36
@tatarco tatarco force-pushed the nv-5295-align-workflow-controller-to-sdk branch from 48aa17e to 7f28715 Compare April 22, 2025 09:48
@tatarco tatarco force-pushed the nv-5295-align-workflow-controller-to-sdk branch from 7f28715 to 28af65c Compare April 23, 2025 08:11
@SokratisVidros SokratisVidros merged commit 9f0ed4e into next Apr 23, 2025
16 of 18 checks passed
@SokratisVidros SokratisVidros deleted the nv-5295-align-workflow-controller-to-sdk branch April 23, 2025 09:25
bricehemery pushed a commit to jack-agency/novu that referenced this pull request Jul 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants