EveSSO
SSO Authorization for Eve Online.
About
This library implements the native SSO authorization flow as described here. EveSSO will perform the authorization process as needed, store your access and refresh tokens, and refresh your access token as needed. It will then provide the required header for your requests.
Installation
pip install evesso
Quickstart
from evesso import SSO
import requests
sso = SSO(
client_id='1234567890asdfghjklqwertyuiop',
callback_url='http://localhost/',
scope='esi-characters.some_scope.v1 esi-characters.some_scope.v1'
)
response = requests.get(
'https://esi.evetech.net/latest/markets/structures/SOME_STRUCTURE_ID/?datasource=tranquility',
headers=sso.get_header()
)
response.raise_for_status()
print(response.json())
Using .env file
CLIENT_ID=1234567890asdfghjklqwertyuiop
CALLBACK_URL=http://localhost/
SCOPE="esi-characters.some_scope.v1 esi-characters.some_scope.v1"
Esi will check environment variables for credentials if not parameterized.
from evesso import SSO
from dotenv import load_dotenv
import requests
load_dotenv()
sso = SSO()
response = requests.get(
'https://esi.evetech.net/latest/markets/structures/SOME_STRUCTURE_ID/?datasource=tranquility',
headers=sso.get_header()
)
response.raise_for_status()
print(response.json())
Authorizing on a remote machine
- Set the
cliparameter toTrue. - The auth url will be printed to the command line.
- Open the auth url in a browser and complete the auth process
- The SSO server will make a get request to the machine where you opened the auth url
- Copy the callback url and paste it into the command line so evesso can parse it
from evesso import SSO
sso = SSO(cli=True)
...
Release files for evesso 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| evesso-0.1.3.tar.gz | 9.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| evesso-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 18.9 kB
Release files / evesso-0.1.3.tar.gz
| Download URL | evesso-0.1.3.tar.gz |
|---|---|
| Size | 9.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e9a40638028f38ec32fffbdc0797cd3abe9aeb131a38b24089e263db85b89f85
|
|
BLAKE2b-256 checksum How to use checksums |
a368e817e38cabc679ce07cf3693e1a2177051ca2bc34ca3c51ce522bd781349
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.31.0 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.0 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.5
|
Release files / evesso-0.1.3-py3-none-any.whl
| Download URL | evesso-0.1.3-py3-none-any.whl |
|---|---|
| Size | 9.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4744fdcfaafa2755eee7d27352adde44c11b8cfd712761a7b74141dfc5f90c28
|
|
BLAKE2b-256 checksum How to use checksums |
87f9428191d246bf3a0a78b78665a893da02b70818c9e0244aef103e864495e9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.31.0 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.0 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.5
|