Compare commits
2 Commits
a586960ae6
...
af58391164
Author | SHA1 | Date | |
---|---|---|---|
af58391164 | |||
3110840017 |
@ -20,6 +20,9 @@ class HappyDomain:
|
|||||||
self.baseurl = scheme + "://" + host + ":" + str(port) + baseurl
|
self.baseurl = scheme + "://" + host + ":" + str(port) + baseurl
|
||||||
self.token = token
|
self.token = token
|
||||||
|
|
||||||
|
if self.token is not None:
|
||||||
|
self.session.headers.update({'Authorization': 'Bearer ' + self.token})
|
||||||
|
|
||||||
def login(self, username, password):
|
def login(self, username, password):
|
||||||
r = self.session.post(
|
r = self.session.post(
|
||||||
self.baseurl + "/api/auth",
|
self.baseurl + "/api/auth",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "happydomain"
|
name = "happydomain"
|
||||||
version = "0.1.1"
|
version = "0.2.0"
|
||||||
authors = [
|
authors = [
|
||||||
{ name="happyDomain's team", email="contact+pypi@happydomain.org" },
|
{ name="happyDomain's team", email="contact+pypi@happydomain.org" },
|
||||||
]
|
]
|
||||||
|
Loading…
Reference in New Issue
Block a user