I am working on the project in which I intend to log in to Heroku CLI without inputting the email and password. I read that heroku login <<< $"$USERNAME\n$PASSWORD\n" no longer works.
What are the alternatives?
easiest way is to set HEROKU_API_KEY to an oauth key
Can you please elaborate it, or maybe give a link to a resource for this? having a really hard time with this
do this to create a token, then set the HEROKU_API_KEY env var to that token
Thank you for the reply.
I followed what you mentioned. Commands like heroku apps seem to work, but when i run git push heroku master, i get the following in my console

What am I supposed to do to avoid this, and automatically push to heroku?
git doesn't use the api key so that won't work. You'll either have to manually create a netrc file with the api key or use ssh git
i used the Platform API and it did the work. Thank you for your help. Appreciate your time
Most helpful comment
do this to create a token, then set the
HEROKU_API_KEYenv var to that token