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

Too many Api calls will incur many issues, and also take more time (OCC-284) #484

Closed
infofromca opened this issue Aug 19, 2024 · 1 comment · Fixed by #497
Closed

Too many Api calls will incur many issues, and also take more time (OCC-284) #484

infofromca opened this issue Aug 19, 2024 · 1 comment · Fixed by #497
Labels
enhancement New feature or request

Comments

@infofromca
Copy link
Contributor

infofromca commented Aug 19, 2024

Is your feature request related to a problem? Please describe

Too many Api calls will incur many networks related issue, and also take more time。
on stripe-payment-form.js, the following three APIs calls can be merged to ONE API call.
await fetch(updatePaymentIntentUrl.replace('PAYMENT_INTENT', paymentIntent.id));
await fetchPost('checkout/validate/Stripe');
await fetchPost('checkout/params/Stripe'),

Describe the solution you'd like

in the backend, firstly, save paymentIntent.id.
secondly, validate it on the C# under the same api.
finally get the params

Jira issue

@infofromca infofromca added the enhancement New feature or request label Aug 19, 2024
@github-actions github-actions bot changed the title Too many Api calls will incur many issues, and also take more time Too many Api calls will incur many issues, and also take more time (OCC-284) Aug 19, 2024
@infofromca
Copy link
Contributor Author

FOR EXAMPLE, I think we do not need this code:
const { paymentIntent } = await stripe.retrievePaymentIntent(clientSecret);
await fetch(updatePaymentIntentUrl.replace('PAYMENT_INTENT', paymentIntent.id));
after we get #490 fixed . @sarahelsaig

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

Successfully merging a pull request may close this issue.

1 participant