geofront.backends.github — GitHub organization and key store

class geofront.backends.github.GitHubKeyStore

Use GitHub account’s public keys as key store.

class geofront.backends.github.GitHubOrganization(client_id: str, client_secret: str, org_login: str)

Authenticate team membership through GitHub, and authorize to access GitHub key store.

Parameters:
  • client_id (str) – github api client id
  • client_secret (str) – github api client secret
  • org_login (str) – github org account name. for example 'spoqa' in https://github.com/spoqa
geofront.backends.github.request(access_token, url: str, method: str='GET', data: bytes=None)

Make a request to GitHub API, and then return the parsed JSON result.

Parameters:
  • access_token (str, Identity) – api access token string, or Identity instance
  • url (str) – the api url to request
  • method (str) – an optional http method. 'GET' by default
  • data (bytes) – an optional content body