PasswordAuth¶
Bases: BaseAuth
Authentication using a username or email and password
| ATTRIBUTE | DESCRIPTION |
|---|---|
endpoint |
The token to use for authentication (default: 'api/access-tokens')
TYPE:
|
Initialize a PasswordAuth instance with a username or email and password
| PARAMETER | DESCRIPTION |
|---|---|
|
The username or email to use for authentication
TYPE:
|
|
The password to use for authentication
TYPE:
|
Example
>>> auth = PasswordAuth('username', 'password')
>>> auth.authenticate('http://planka.instance')
{'Authorization' : 'Bearer <token>'}
| METHOD | DESCRIPTION |
|---|---|
authenticate |
Implementation of the authenticate method |
Source code in src/plankapy/v1/handlers.py
242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 | |
authenticate
¶
Implementation of the authenticate method
| PARAMETER | DESCRIPTION |
|---|---|
|
The base url of the Planka instance
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
dict[str, str]
|
Headers with the token in the |
Source code in src/plankapy/v1/handlers.py
262 263 264 265 266 267 268 269 270 271 272 | |