This code
import splunklib.client as client
host = "127.0.0.1"
port = "8000"
username = "---"
password = "----"
service = client.connect(username=username,password=password,host=host,port=port,scheme = https)
for app in service.apps:
print(app.name)
produces
SSLError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1125)