Skip to content
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

Add route to return the rectification config value #678

Merged
merged 3 commits into from
Jan 30, 2025

Conversation

rerissondaniel
Copy link
Contributor

@rerissondaniel rerissondaniel commented Jan 15, 2025

What problem is this solving?

This pull request introduces a new feature to fetch email rectification configuration from the OMS service. The most important changes include adding a new method to the OMS client, updating the service configuration to include a new route, and implementing the route handler.

We need this to make this route accessible only to authenticated shoppers using the application token to retrieve the configuration.

How to test it?

Workspace

New Feature: Email Rectification Configuration

  • node/clients/oms.ts: Added a new method getRmailRetificationConfig to fetch email rectification configuration from the OMS service.
  • node/index.ts: Imported the new route handler getEmailRetificationConfig and added a new route rectification-config to the service configuration. [1] [2]
  • node/routes/index.ts: Implemented the getEmailRetificationConfig route handler to fetch and return the email rectification configuration, and added a helper function setForbiddenStatus to handle authorization errors.
  • node/service.json: Updated the service configuration to include the new route rectification-config with its path and access settings.

@rerissondaniel rerissondaniel requested a review from a team as a code owner January 15, 2025 15:48
@rerissondaniel rerissondaniel requested review from vsseixaso, RodrigoTadeuF and leo-prange-vtex and removed request for a team January 15, 2025 15:48
Copy link
Contributor

vtex-io-ci-cd bot commented Jan 15, 2025

Hi! I'm VTEX IO CI/CD Bot and I'll be helping you to publish your app! 🤖

Please select which version do you want to release:

  • Patch (backwards-compatible bug fixes)

  • Minor (backwards-compatible functionality)

  • Major (incompatible API changes)

And then you just need to merge your PR when you are ready! There is no need to create a release commit/tag.

  • No thanks, I would rather do it manually 😞

@vtex-io-docs-bot
Copy link

vtex-io-docs-bot bot commented Jan 15, 2025

Beep boop 🤖

I noticed you didn't make any changes at the docs/ folder

  • There's nothing new to document 🤔
  • I'll do it later 😞

In order to keep track, I'll create an issue if you decide now is not a good time

  • I just updated 🎉🎉

@rerissondaniel rerissondaniel force-pushed the feature/add-rect-config-route branch from 2ec80ba to 1233a85 Compare January 15, 2025 16:06
wagnerlduarte
wagnerlduarte previously approved these changes Jan 15, 2025
Copy link
Contributor

@wagnerlduarte wagnerlduarte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

node/clients/oms.ts Outdated Show resolved Hide resolved
node/routes/index.ts Outdated Show resolved Hide resolved
Co-authored-by: Wagner Lemos Duarte <[email protected]>
node/routes/index.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@iago1501 iago1501 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice

@iago1501 iago1501 merged commit a37a729 into master Jan 30, 2025
8 checks passed
@iago1501 iago1501 deleted the feature/add-rect-config-route branch January 30, 2025 16:23
Copy link
Contributor

vtex-io-ci-cd bot commented Jan 30, 2025

Your PR has been merged! App is being published. 🚀
Version 2.172.1 → 2.173.0

After the publishing process has been completed (check #vtex-io-releases) and doing A/B tests with the new version, you can deploy your release by running:

vtex deploy [email protected]

After that your app will be updated on all accounts.

For more information on the deployment process check the docs. 📖

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants