☁️Sending Logs To A Syslog Server
api.logger.set_up_sys_log_handler()
Logger lets you send your logs externally to a server which can be handy for system administrators that need accountability. When making calls to Odin's API not all calls are logged in the event history in the web portal. Using this feature can ensure you get the full benefits of the library and have complete accountability of the team.
Parameters
url (str): IP/ URL to syslog server e.g. 1.1.1.1 or mysyslogserver.com/
port_number (int): Port number the logs will sent on to URL
Return
None: This method does not return anything.
How To Use:
When creating your API object it will set up the logger automatically and start to send logs of API calls made to os.logg
. When authenticating your API object this sends a call to the API and will Logger will send this to os.logg
. Therefore, to capture all logs including the authentication call this method before authenticating.
Example logs.
Last updated