Moibe commited on
Commit
932f59f
·
1 Parent(s): c03d0ab

Debug Mode gone

Browse files
Files changed (3) hide show
  1. funciones.py +1 -1
  2. ga4Analiticas.py +1 -1
  3. main.py +1 -4
funciones.py CHANGED
@@ -62,7 +62,7 @@ async def procesa_evento(request: Request, stripe_signature: str = Header(None))
62
  if event_type == 'checkout.session.async_payment_succeeded':
63
  print("Pago asíncrono completado.")
64
  print("Checkout Session completado.")
65
- print("Status:")
66
  print(event_data['status'])
67
  print("Payment Method Options:")
68
  print(event_data['payment_method_options'])
 
62
  if event_type == 'checkout.session.async_payment_succeeded':
63
  print("Pago asíncrono completado.")
64
  print("Checkout Session completado.")
65
+ #print("Status:")
66
  print(event_data['status'])
67
  print("Payment Method Options:")
68
  print(event_data['payment_method_options'])
ga4Analiticas.py CHANGED
@@ -49,7 +49,7 @@ def send_ga4_purchase_event(session):
49
  {
50
  "name": "purchase",
51
  "params": {
52
- "debug_mode": True,
53
  "transaction_id": session['id'],
54
  "value": valor, # Convierte de céntimos a la unidad de moneda
55
  "currency": moneda,
 
49
  {
50
  "name": "purchase",
51
  "params": {
52
+ #"debug_mode": True,
53
  "transaction_id": session['id'],
54
  "value": valor, # Convierte de céntimos a la unidad de moneda
55
  "currency": moneda,
main.py CHANGED
@@ -8,7 +8,6 @@ app = FastAPI()
8
  string_key = globales.llave
9
 
10
  print ("Obtuve string key...")
11
- time.sleep(15)
12
 
13
  @app.get("/")
14
  def start():
@@ -17,6 +16,4 @@ def start():
17
  @app.post("/webhook")
18
  async def webhook_received(request: Request, stripe_signature: str = Header(None)):
19
 
20
- return await funciones.procesa_evento(request, stripe_signature)
21
-
22
-
 
8
  string_key = globales.llave
9
 
10
  print ("Obtuve string key...")
 
11
 
12
  @app.get("/")
13
  def start():
 
16
  @app.post("/webhook")
17
  async def webhook_received(request: Request, stripe_signature: str = Header(None)):
18
 
19
+ return await funciones.procesa_evento(request, stripe_signature)