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

feat: Add vtexinternal as API environment (SFS-1667) #2508

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

lucasfp13
Copy link
Contributor

@lucasfp13 lucasfp13 commented Oct 16, 2024

What's the purpose of this pull request?

This PR intends to use the vtexinternal internal domain on calls to VTEX APIs.

How it works?

Adding the new type (vtexinternal) to the environment API option, the @faststore/core will receive this value through the global env HOMEBREW_API_ENVIRONMENT from stores served by Homebrew and build the BFF server using this value.

Then, on @faststore/api we will read this environment value and fetch the API calls using the vtexinternal domain when it should.

How to test it?

Check if all of the GraphQL requests are status 200.

The tests should be performed from the Starter deploy preview only, since locally we should not use this host (we validate that in the code).

Starters Deploy Preview

vtex-sites/starter.store#580

References

Check the Opportunity: use vtexinternal on Homebrew internal doc.

@lucasfp13 lucasfp13 self-assigned this Oct 16, 2024
Copy link

vercel bot commented Oct 16, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
faststore-site ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 22, 2024 6:19pm

@lucasfp13 lucasfp13 added the don't merge Blocked by some reason - - Please mention the reason label Oct 16, 2024
Copy link

codesandbox-ci bot commented Oct 16, 2024

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@lucasfp13 lucasfp13 changed the title feat: Add vtexinternal as API environment feat: Add vtexinternal as API environment (SFS-1667) Oct 22, 2024
@lucasfp13 lucasfp13 added enhancement New feature or request performance Pull requests related to perfomance issues and removed don't merge Blocked by some reason - - Please mention the reason labels Oct 22, 2024
@lucasfp13 lucasfp13 marked this pull request as ready for review October 22, 2024 18:24
@lucasfp13 lucasfp13 requested a review from a team as a code owner October 22, 2024 18:24
@lucasfp13 lucasfp13 requested review from emersonlaurentino, renatamottam and gvc and removed request for a team and renatamottam October 22, 2024 18:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request performance Pull requests related to perfomance issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants