From 624788b57e8a03de42c7603f46cc3ad3e9dfeba4 Mon Sep 17 00:00:00 2001 From: jakobhkristjansson Date: Wed, 12 Feb 2025 11:39:07 +0000 Subject: [PATCH] feat/python_update_all --- api_check.py | 14 ++++++++++++++ requirements.txt | 3 ++- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 api_check.py diff --git a/api_check.py b/api_check.py new file mode 100644 index 00000000..bb48c4ec --- /dev/null +++ b/api_check.py @@ -0,0 +1,14 @@ +import requests + +AUTH = 'AfasToken PHRva2VuPjx2ZXJzaW9uPjE8L3ZlcnNpb24+PGRhdGE+OENDNjVGQUE3RjBGNEYwMkIxRjVFRDAyOTA5RDEyQzBCRDlBQUNCMTNEREM0MkNEODMxRTQyNzExQ0JGMzFCQzwvZGF0YT48L3Rva2VuPg==' +url = "https://83448.rest.afas.online/profitrestservices/connectors/ETL2_Dossier2_Verzuimverloop/" + +headers = { + 'Authorization': AUTH +} + +response = requests.get(url, headers=headers) + +print(f"Status code: {response.status_code}") +print("Headers:", response.headers) +print("Response body:", response.text) \ No newline at end of file diff --git a/requirements.txt b/requirements.txt index 8ab6294c..5eaf725f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1,2 @@ -flask \ No newline at end of file +flask +requests \ No newline at end of file