Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

747
Visualizações
StripeInvalidRequestError: You cannot accept payments using this API as it is no longer supported in India

I have been building an ecommerce web application and wanted to Integrate my Checkout with the Stripe API , but when i run the application and make a transaction. I get the following message error..

I came to find that Payment Intent API are to be used as per new RBI regulations, I cannot get how to change my code so that it again accepts my transaction with a 201 response. Here is my code snippet.

import StripeCheckout from "react-stripe-checkout";

const STRIPE_PUBLISHABLE =
  "my_api_key";

const onToken = (user, checkout) => (token) => checkout(user, token.id);

const Checkout = ({ amount, user, checkout }) => (
  <StripeCheckout
    amount={amount * 100}
    token={onToken(user, checkout)}
    currency="INR"
    stripeKey={STRIPE_PUBLISHABLE}
  />
);

export default Checkout;
about 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

Your code is using Stripe's Legacy Checkout product which was deprecated back in 2019 already. You can't really "modify" that code since it's not supported in India due to the new RBI regulations. You have to rewrite your integration instead to use a different product.

The easiest option is to use Stripe's "newer" product called Payment Links. This allows you to configure a payment flow with a URL for a certain product: https://stripe.com/docs/payments/payment-links

Alternatively, you can use the newer version of Checkout which is hosted by Stripe and handles all the payment collection for you: https://stripe.com/docs/payments/checkout

Finally, if those solutions don't work for you, you will have to use the Payment Intents API to accept a payment and the Payment Element to collect card details: https://stripe.com/docs/payments/accept-a-payment

about 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda