In this tutorial you can follow, they describe how you can use the Google translation API with android studio and how to properly connect them.
Also this documentation will help you to understand how to manage the document translations properly, and also tells you which permissions you need and what you need to do before using the API.