As per android developer documentation
Android 8.0 (API level 26) introduces several new permissions related to telephony: The ANSWER_PHONE_CALLS permission allows your app to answer incoming phone calls programmatically. To handle an incoming phone call in your app, you can use the acceptRingingCall() method.
How my app give voice answer to incoming call ?
but I have not found any guide or examples about of this . so
I want automatic answer with voice(from raw folder in app) (I have need guide or example code like answering machine)
Updates from Google :
All these three commands are deprecated on and from Android Q
click to verify here