new helper function
This commit is contained in:
@@ -92,6 +92,20 @@ def get_contacts(rower):
|
|||||||
|
|
||||||
return None # pragma
|
return None # pragma
|
||||||
|
|
||||||
|
def get_api_get(url):
|
||||||
|
token = idoklad_token()
|
||||||
|
if token is None:
|
||||||
|
return None
|
||||||
|
|
||||||
|
headers = {
|
||||||
|
'Authorization': 'Bearer {t}'.format(t=token.access_token),
|
||||||
|
}
|
||||||
|
|
||||||
|
res = requests.get(url, headers=headers)
|
||||||
|
|
||||||
|
return res
|
||||||
|
|
||||||
|
|
||||||
def create_contact(rower):
|
def create_contact(rower):
|
||||||
token = idoklad_token()
|
token = idoklad_token()
|
||||||
if token is None:
|
if token is None:
|
||||||
|
|||||||
Reference in New Issue
Block a user