measmonysuon commited on
Commit
ac77ded
1 Parent(s): dcc49a2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -8,10 +8,10 @@ from urllib.parse import urlparse, parse_qs
8
 
9
  # Initialize the client for image generation
10
  client_image = Client("mukaist/DALLE-4K")
 
11
  # Retrieve secret token from environment variables
12
  webhook_server = os.getenv('webhook_server')
13
 
14
-
15
  # Define resolutions
16
  resolutions = {
17
  "896x1152": (896, 1152),
@@ -66,7 +66,7 @@ def update_user_points(user_chat_id, points):
66
 
67
  def notify_webhook(user_chat_id):
68
  """Notify the webhook server about the points update."""
69
- webhook_url = "http://65.108.76.174:5000/update_points"
70
  payload = {'user_chat_id': user_chat_id, 'points': 10} # Adjust payload as necessary
71
  try:
72
  response = requests.post(webhook_url, json=payload)
 
8
 
9
  # Initialize the client for image generation
10
  client_image = Client("mukaist/DALLE-4K")
11
+
12
  # Retrieve secret token from environment variables
13
  webhook_server = os.getenv('webhook_server')
14
 
 
15
  # Define resolutions
16
  resolutions = {
17
  "896x1152": (896, 1152),
 
66
 
67
  def notify_webhook(user_chat_id):
68
  """Notify the webhook server about the points update."""
69
+ webhook_url = f"{webhook_server}/update_points"
70
  payload = {'user_chat_id': user_chat_id, 'points': 10} # Adjust payload as necessary
71
  try:
72
  response = requests.post(webhook_url, json=payload)