Arafath10 commited on
Commit
6242b18
1 Parent(s): 9f8b128

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +3 -2
main.py CHANGED
@@ -32,6 +32,7 @@ async def read_root():
32
 
33
  @app.get("/start_model_trigger")
34
  async def model_trigger(page:int):
 
35
  page = str(page)
36
  url = "https://api-ai-service.transexpress.lk/trigger_the_data_fecher?page="+page+"&paginate=10000"
37
  print(url,page)
@@ -42,8 +43,8 @@ async def model_trigger(page:int):
42
  }
43
 
44
  response = requests.request("GET", url, headers=headers, data=payload)
45
-
46
  print(response.text)
47
- return page
48
 
49
 
 
32
 
33
  @app.get("/start_model_trigger")
34
  async def model_trigger(page:int):
35
+ while True:
36
  page = str(page)
37
  url = "https://api-ai-service.transexpress.lk/trigger_the_data_fecher?page="+page+"&paginate=10000"
38
  print(url,page)
 
43
  }
44
 
45
  response = requests.request("GET", url, headers=headers, data=payload)
46
+ page = int(page)+1
47
  print(response.text)
48
+ return page
49
 
50