Describes, how to invoke REST operations with SSL and sample code.

The Collector SDK allows the programmer to consume Collector end point APIs that might be exposed over HTTPS, with a self-signed certificate. The reference code below depicts how the RestConfiguration can be setup to allow various possibilities with SSL communication between the RestClient and the Collector end point.

# Setting up RestConfiguration with SSLglobal 
rest_configuration = RestConfiguration() 
# the below values should read from configuration file config.json
rest_configuration.host = "https://127.0.0.1:8080"
rest_configuration.verify_ssl = False
rest_configuration.ssl_ca_cert ="<path>/tomcat.cert"
rest_configuration.assert_hostname = "127.0.0.1"
response = rest_client.RestClient(configuration=rest_configuration)                                              .call_api("/resource_path", 'GET',    _preload_content=False,_return_http_data_only=True,query_params={"alt":"json"})