Spaces:
Running
Running
Omite error card por oxxo
Browse files
main.py
CHANGED
|
@@ -57,11 +57,11 @@ async def webhook_received(request: Request, stripe_signature: str = Header(None
|
|
| 57 |
print(len(event_data['payment_method_options']))
|
| 58 |
#Si hay un elemento que es card abona inmediatamente.
|
| 59 |
#Si no, por ahora ignora.
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
|
| 66 |
if event_type == 'checkout.session.async_payment_succeeded':
|
| 67 |
print("Pago asíncrono completado.")
|
|
|
|
| 57 |
print(len(event_data['payment_method_options']))
|
| 58 |
#Si hay un elemento que es card abona inmediatamente.
|
| 59 |
#Si no, por ahora ignora.
|
| 60 |
+
if len(event_data['payment_method_options']) > 0:
|
| 61 |
+
print("Imprimiendo payment method cards con pago en oxxo: ")
|
| 62 |
+
time.sleep(2)
|
| 63 |
+
print(event_data['payment_method_options']["card"])
|
| 64 |
+
time.sleep(3)
|
| 65 |
|
| 66 |
if event_type == 'checkout.session.async_payment_succeeded':
|
| 67 |
print("Pago asíncrono completado.")
|