palantir.api.EyeOfSauronAPI
- class palantir.api.EyeOfSauronAPI
Deals with authentication and requests to eyeOfSauron API
- __init__()
Methods
__init__
()fillHeaders
(headers)getAccessToken
()Returns and sets a token to the accessToken attribute.
getRefreshToken
()Returns and sets a token to the refreshToken attribute.
getResources
(uri[, resources])Executes a GET HTTP request to eyeOfSauron API.
makeHeadersAuth
([headers])Adds 'Authorization' key with a Bearer token to headers.
postResources
(uri[, payload])Executes a POST HTTP request to eyeOfSauron API.
request
(uri, method[, payload, resources, ...])Executes a POST HTTP request to eyeOfSauron API.
sendAlert
(channelType, alertCode, detail, ...)transformURI
(uri)Attributes
ALERT_INFRA
ALERT_SI
API_URL
EMAIL_CHANNEL
EXTERNAL_API
INVALID_CREDENTIALS
REDMINE_CHANNEL
RESPONSE_FORMAT
SERVER_ERROR