This is an App Script solution. Otherwise you can try integrating with API using the documentation here.