Skip to content
This repository has been archived by the owner on Jan 8, 2023. It is now read-only.

Commit

Permalink
Fixed Issue #5
Browse files Browse the repository at this point in the history
  • Loading branch information
Silv3rHorn committed Jan 18, 2022
1 parent b81ae5b commit 5649c17
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions cs_methods.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,15 +123,16 @@ def get_token_request() -> str:
"""
global TOKEN_REQ_TIME

headers = {
'Content-Type': 'application/x-www-form-urlencoded'
}
body = {
'client_id': CLIENT_ID,
'client_secret': SECRET
}
headers = {
'Authorization': HEADERS['Authorization']
}
token_res = http_request('POST', '/oauth2/token', data=body, headers=headers, safe=True,
get_token_flag=False)

token_res = http_request('POST', '/oauth2/token', data=body, headers=headers, safe=True, get_token_flag=False)

try:
TOKEN_REQ_TIME = datetime.now()
return token_res.get('access_token')
Expand Down

0 comments on commit 5649c17

Please sign in to comment.