Use dictionary instead of single arguments for connect()