How to automate actions in certain apps? I have a Note 5 running Android 7.0. I use an app to get scheduled for work. Is there any app that could automate my scheduling in the app? Getting schedule is very hard if I do it manually by updating the screen manually for 30 minutes at least. I checked Automate and MacroDroid but could not find any actions that would control third party apps. If no app is available, is there examples of a Java code to see how controlling on Android works. I could modify the code for my use case. Thanks!
By default regular Apps can't control other apps. 

There are two exceptions:


If the app is a system app (signed with the same cryptographic key that was used to sign the OS itself)
An app can request access to the "accessibility services". Using this service  an app can interact with other apps.


Note that Google is currently (mid 2018) restricting the accessibility service usage. Only apps that use it for legitimate purposes are allowed (helping disabled people to use an Android phone. As you can imagine controlling third party apps is not a legitimate purpose for Google's perspective.