#Anuj
1 messages · Page 1 of 1 (latest)
hello! can you give the specific examples of the ids?
@frozen bear lets continue the conversation in this thread
"id": "pi_3NGIrcCibbZW6HqQ1b3wueqV",
After Payment Indent Call from Backend (Python) I get details and save them in database. I Consider Id as transaction ID.
I have created webhooks to capture response on backend and update status on database.
After Completion the payment details comes by webhook payment_intent.succeeded then I match data on the base Of Id (Transaction ID) but that Id is different from Id get at the time of payment_intent.create.
Please suggest solution how can i map Transaction to update payment status in backend.
When I want update data against Id get from payment_intent.create after payment_intent.succeeded event in webhook
Id will be differ from payment_intent.create so match found in database
you said the id is different, but you've only provided one id. What's the other ID that you're referring to?
"data": {
"object": {
"id": "pi_3NGLqECibbZW6HqQ0gzeaFTZ",
"object": "payment_intent",
"amount": 50,
"amount_capturable": 0,
"amount_details": {
"tip": {
}
},
"amount_received": 0,
"application": null,
"application_fee_amount": null,
"automatic_payment_methods": null,
"canceled_at": null,
"cancellation_reason": null,
"capture_method": "automatic",
"client_secret": "pi_3NGLqECibbZW6HqQ0gzeaFTZ_secret_M9SA1JKwLIavY3s2y59ujIECK",
"confirmation_method": "automatic",
"created": 1686142318,
"currency": "eur",
"customer": "cus_O2KFu2Nc0kqf2J",
"description": null,
"invoice": null,
"last_payment_error": null,
"latest_charge": null,
"livemode": false,
"metadata": {
},
"next_action": null,
"on_behalf_of": null,
"payment_method": null,
"payment_method_options": {
"card": {
"installments": null,
"mandate_options": null,
"network": null,
"request_three_d_secure": "automatic"
}
},
"payment_method_types": [
"card"
],
"processing": null,
"receipt_email": "naveenkundra12203@gmail.com",
"review": null,
"setup_future_usage": null,
"shipping": null,
"source": null,
"statement_descriptor": null,
"statement_descriptor_suffix": null,
"status": "requires_payment_method",
"transfer_data": null,
"transfer_group": null
}
},
"livemode": false,
"pending_webhooks": 1,
"request": {
"id": "req_QQhCeWLE8qwbxV",
"idempotency_key": "8a1aec33-0ba4-42ef-beab-8cb86204d727"
},
"type": "payment_intent.created"
}
{
"id": "evt_3NGLeMCibbZW6HqQ0u7Jpo4K",
"object": "event",
"api_version": "2022-11-15",
"created": 1686142340,
"data": {
"object": {
"id": "pi_3NGLeMCibbZW6HqQ0unOaf9K",
"object": "payment_intent",
"amount": 50,
"amount_capturable": 0,
"amount_details": {
"tip": {
}
},
"amount_received": 50,
"application": null,
"application_fee_amount": null,
"automatic_payment_methods": null,
"canceled_at": null,
"cancellation_reason": null,
"capture_method": "automatic",
"client_secret": "pi_3NGLeMCibbZW6HqQ0unOaf9K_secret_FwttBoOmqpS7nf8giO3HPN9Xv",
"confirmation_method": "automatic",
"created": 1686141582,
"currency": "eur",
"customer": "cus_O2KFu2Nc0kqf2J",
"description": null,
"invoice": null,
"last_payment_error": null,
"latest_charge": "ch_3NGLeMCibbZW6HqQ05skyVPi",
"livemode": false,
"metadata": {
},
"next_action": null,
"on_behalf_of": null,
"payment_method": "pm_1NGLqZCibbZW6HqQszQo6rjJ",
"payment_method_options": {
"card": {
"installments": null,
"mandate_options": null,
"network": null,
"request_three_d_secure": "automatic",
"setup_future_usage": "off_session"
}
},
"payment_method_types": [
"card"
],
"processing": null,
"receipt_email": "naveenkundra12203@gmail.com",
"review": null,
"setup_future_usage": null,
"shipping": null,
"source": null,
"statement_descriptor": null,
"statement_descriptor_suffix": null,
"status": "succeeded",
"transfer_data": null,
"transfer_group": null
}
},
"livemode": false,
"pending_webhooks": 1,
"request": {
"id": "req_jLDSQiVfPU7mm6",
"idempotency_key": "289fa721-c177-4bc9-8bc8-5b3eece923d3"
},
"type": "payment_intent.succeeded"
}
"id": "pi_3NGLqECibbZW6HqQ0gzeaFTZ", is different from "id": "pi_3NGLeMCibbZW6HqQ0unOaf9K", get at the time of "type": "payment_intent.succeeded"
So I am not able to update data in database as Id mismatch
How can I retrieve payment status against pi_3NGLqECibbZW6HqQ0gzeaFTZ
pi_3NGLqECibbZW6HqQ0gzeaFTZ - this PaymentIntent was never successful. You can view the timeline of this PaymentIntent in the Dashboard : https://dashboard.stripe.com/test/payments/pi_3NGLqECibbZW6HqQ0gzeaFTZ