A corporation manager and dashboard for EVE Online
25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.
 
 
 
 
 

22 satır
599 B

  1. # -*- coding: utf-8 -*-
  2. from urllib.parse import urlencode
  3. __all__ = ["SSOManager"]
  4. class SSOManager:
  5. def get_authorize_url(self, client_id, redirect_uri, scopes=None,
  6. state=None):
  7. baseurl = "https://login.eveonline.com/oauth/authorize?"
  8. params = {
  9. "response_type": "code",
  10. "redirect_uri": redirect_uri,
  11. "client_id": client_id
  12. }
  13. if scopes:
  14. params["scope"] = " ".join(scopes)
  15. if state is not None:
  16. params["state"] = state
  17. return baseurl + urlencode(params)