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

Make public API masking optional #19

Merged

Conversation

janniksam
Copy link

@janniksam janniksam commented Dec 4, 2022

By removing / commenting out the enviroment variable NEXT_PUBLIC_MULTIVERSX_API the maskin of the public MultiversX api can be disabled. When masking is disabled all api requests done by the dapp will go directly to the public api endpoint.

Further more I've simplified the access to the active network configuration. We can use activeNetworkConfiguration-method to get the active network configuration, if we don't want to retrieve a specific configuration for a given chainType.

Fixes #18

@netlify
Copy link

netlify bot commented Dec 4, 2022

👷 Deploy request for multiversx-nextjs-dapp pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 027fdb9

utils/apiCall.ts Outdated Show resolved Hide resolved
@janniksam janniksam force-pushed the feature/makeApiMaskingOptional branch from 1a72b6d to f8182e0 Compare December 4, 2022 11:42
.env.example Outdated Show resolved Hide resolved
next.config.js Outdated Show resolved Hide resolved
@janniksam janniksam force-pushed the feature/makeApiMaskingOptional branch 2 times, most recently from 4929f04 to 5222301 Compare December 4, 2022 19:04
@janniksam janniksam force-pushed the feature/makeApiMaskingOptional branch from 5222301 to 027fdb9 Compare December 4, 2022 19:06
@juliancwirko juliancwirko merged commit 7f81079 into xdevguild:main Dec 4, 2022
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.

Make the API proxy optional. For example, when someone uses public API, it isn't needed at all
2 participants