switch to middleware validation

This commit is contained in:
2025-01-06 20:07:55 +01:00
parent 2c94b7fb7e
commit dca88c26a4
4 changed files with 51 additions and 40 deletions

View File

@ -15,9 +15,10 @@ def send_post_request(uri, data, token):
"Content-Type": "application/json",
}
try:
requests.post(uri, json=data, timeout=1, headers=headers)
response = requests.post(uri, json=data, timeout=1, headers=headers)
print("Return code: " + str(response.status_code))
except requests.exceptions.RequestException as e:
pass
print(e)
def main():
parser = argparse.ArgumentParser(