nilekhet commited on
Commit
ff61b19
·
1 Parent(s): fd3ec12

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -9,6 +9,7 @@ def get_hashtags(keyword):
9
  "X-RapidAPI-Host": "hashtagy-generate-hashtags.p.rapidapi.com"
10
  }
11
  response = requests.get(url, headers=headers, params={"keyword": keyword})
 
12
  data = response.json()['data']
13
  hashtags = data['best_30_hashtags']['hashtags']
14
  return ', '.join(hashtags)
@@ -21,6 +22,7 @@ def get_post_count(tag):
21
  "X-RapidAPI-Host": "hashtag5.p.rapidapi.com"
22
  }
23
  response = requests.get(url, headers=headers, params={"tag": tag})
 
24
  count = response.json()['count']
25
  return count
26
 
 
9
  "X-RapidAPI-Host": "hashtagy-generate-hashtags.p.rapidapi.com"
10
  }
11
  response = requests.get(url, headers=headers, params={"keyword": keyword})
12
+ print(response.json())
13
  data = response.json()['data']
14
  hashtags = data['best_30_hashtags']['hashtags']
15
  return ', '.join(hashtags)
 
22
  "X-RapidAPI-Host": "hashtag5.p.rapidapi.com"
23
  }
24
  response = requests.get(url, headers=headers, params={"tag": tag})
25
+ print(response.json())
26
  count = response.json()['count']
27
  return count
28