demb.design -> demb.uk

This commit is contained in:
norohind 2022-09-18 14:15:03 +03:00
parent c81d504dba
commit 26d7804065
Signed by: norohind
GPG Key ID: 01C3BECC26FB59E1
2 changed files with 4 additions and 4 deletions

View File

@ -99,7 +99,7 @@
</table>
</div>
<a>In order to access to api, add /api/ prefix to any endpoint url<br>
Author contact: a31#6403 (discord), a31@demb.design (email)<br>
Author contact: a31#6403 (discord), a31@demb.uk (email)<br>
<a href="https://github.com/norohind/SquadsActivityMonitor">Source code</a></a>
<br><a>Monero XMR: 85aKmMT2ab4hkpU3iZRk9q5DDSuDL4qDX2wDEgSFgDmRif7pD1LCN8ZLhYEFDC6rsFae71E5gKsMPG3YHRoikzhcUJ8Rm7h</a>
</body>

View File

@ -119,18 +119,18 @@ def proxied_request(url: str, method: str = 'get', **kwargs) -> requests.Respons
def _get_bearer() -> str:
"""Gets bearer token from capi.demb.design (companion-api project, I will upload it on GH one day...)
"""Gets bearer token from capi.demb.uk (companion-api project, I will upload it on GH one day...)
:return: bearer token as str
"""
bearer_request: requests.Response = requests.get(
url='https://capi.demb.design/random_token', headers={'auth': os.environ['DEMB_CAPI_AUTH']})
url='https://capi.demb.uk/random_token', headers={'auth': os.environ['DEMB_CAPI_AUTH']})
try:
bearer: str = bearer_request.json()['access_token']
except Exception as e:
logger.exception(f'Unable to parse capi.demb.design answer\nrequested: {bearer_request.url!r}\n'
logger.exception(f'Unable to parse capi.demb.uk answer\nrequested: {bearer_request.url!r}\n'
f'code: {bearer_request.status_code!r}\nresponse: {bearer_request.content!r}', exc_info=e)
raise e