added conn.params for api_key and api_username