This forum is closed. Thank you for your contributions.
I have SharePoint Client Id, Client credential and Write access grant type. I need to generate a bearer access token using the above details. Please let me know how to generate a bearer access token dynamically using JAVA /HttpURL Connection ?