Moibe commited on
Commit
7e0ea75
1 Parent(s): 7f9c0e7

Setup Future Usage Null

Browse files
Files changed (2) hide show
  1. funciones.py +4 -1
  2. paga_oxxo.py +4 -2
funciones.py CHANGED
@@ -96,7 +96,10 @@ def create_checkout_session(price_id, customer_email=None, customer_id=None, fir
96
  # 'client_reference_id': 'HERC',
97
  'metadata': {
98
  'imagenes': unidades
99
- } # Inicializamos metadata para a帽adir el customer_id y firebase_user si existen
 
 
 
100
  }
101
 
102
  # Asociar el cliente encontrado/creado a la sesi贸n
 
96
  # 'client_reference_id': 'HERC',
97
  'metadata': {
98
  'imagenes': unidades
99
+ },
100
+ 'payment_intent_data': {
101
+ 'setup_future_usage': None # En Python usamos None en lugar de null
102
+ }
103
  }
104
 
105
  # Asociar el cliente encontrado/creado a la sesi贸n
paga_oxxo.py CHANGED
@@ -1,13 +1,15 @@
1
  import stripe
2
  import globales
3
 
4
- #stripe.api_key = globales.llave
 
 
5
 
6
  # Despu茅s de crear un Checkout Session
7
  #session = stripe.checkout.Session.create(**session_params)
8
 
9
  # Si necesitas recuperar el PaymentIntent asociado a la sesi贸n
10
- payment_intent = stripe.PaymentIntent.retrieve('pi_3RtecaROVpWRmEfB08gAe9CP')
11
  print("payment_intent obtenido...")
12
 
13
  # Comprobar si hay alguna acci贸n necesaria
 
1
  import stripe
2
  import globales
3
 
4
+ print("Haciendo pago en Oxxo...")
5
+
6
+ stripe.api_key = globales.llave
7
 
8
  # Despu茅s de crear un Checkout Session
9
  #session = stripe.checkout.Session.create(**session_params)
10
 
11
  # Si necesitas recuperar el PaymentIntent asociado a la sesi贸n
12
+ payment_intent = stripe.PaymentIntent.retrieve('pi_3RupzSROVpWRmEfB1wEZghFL')
13
  print("payment_intent obtenido...")
14
 
15
  # Comprobar si hay alguna acci贸n necesaria