tester_1.py 446 B

123456789101112131415161718
  1. # %%
  2. import requests
  3. import json
  4. import os
  5. from results_output_JSON import df_to_json_records, write_to_json_results, write_to_json_searches, read_from_json, filename_results, filename_searches, path
  6. url = 'http://127.0.0.1:5000/simple_get_query'
  7. # %%
  8. searches = read_from_json(os.path.join(path, filename_searches))
  9. # %%
  10. for search in searches:
  11. dto = {
  12. "queryList": [search]
  13. }
  14. x = requests.post(url, json = dto)
  15. print(x.text)
  16. # %%