title: Spring Boot : Recipe to repeatably get access token based on authorisation header
body: <p>So I have this situation.
  I am coding inside a controller API in spring boot that gets a request with authorisation header.
  I need to hit a token endpoint with this header to get the access token.
  After this I need to hit an API with this toke to get some information.</p>
  <p>Now one way of approaching this is to ,</p>
  <ol>
  <li>Create a clients one to get the token .</li>
  <li>Create another client to hit the actual API.</li>
  <li>Then when my API received the request , then hit these above endpoints in succession to get<br />
  the job done. Also, need to take care of caching the token so that we dont end up doing this
  every time.</li>
  </ol>
  <p>Because this looks like a pattern I want to create a system where i can create one client kind of like the Spring <code>WebCLient</code> and that can take care of hitting the token uri when required.
  But all documentation I am reading suggest providing a token url(which I have) and also clientid/secret in the configuration.(These I dont. I only have the incoming auth code).
  Is there a programmatic way I can achieve the same with webclient ?</p>