Updated streaming api and flow api