#Daniel M-webhook-secret

1 messages ยท Page 1 of 1 (latest)

atomic flume
#

Hello, it'll be in the Dashboard page for the webhook:

ancient silo
#

oooh yeah there it is

#

thanks

#

sure! just though bc its another topic ๐Ÿ˜„

#

so yeah, I can created one charge and pay

#

each payment after ends in this

atomic flume
#

Looks like your code is returning an error somewhere. Is there anything in the logs?

ancient silo
#

this

atomic flume
#

Taking a look

#

Looks like that PI has already been confirmed

ancient silo
#
const stripe = require("stripe")(
  "sk_test_51KyzygLkVu8CqnKeeX0TbSexsPog29cBPLUekig88CVaR4wn947OOYA4VM7TxMOAZqP4zH94t6utEQIz3fPBiisq00FKsowi5x"
);

exports.createNewIntent = async (req, res) => {

  
  const intent = await paymentIntent;
  res.send(intent);
};

const paymentIntent = stripe.paymentIntents.create({
  amount: process.env.STRIPE_AUDIT_PRICE,
  currency: "eur",
  automatic_payment_methods: {
    enabled: true,
  },
});
```think i found it
#
exports.createNewIntent = async (req, res) => {
  const paymentIntent = stripe.paymentIntents.create({
    amount: process.env.STRIPE_AUDIT_PRICE,
    currency: "eur",
    automatic_payment_methods: {
      enabled: true,
    },
  });
  const intent = await paymentIntent;
  res.send(intent);
};
``` should work
#

used the same intent again after creating it once

atomic flume
#

Ah, was that not executing after confirming because of the bug?

ancient silo
#

well it safed the const paymentIntent and used it again and again after it was created once as ou can see in the upper code snippet

#

now I create a new one with each call

atomic flume
#

Cool