title: Spring boot call external API with external YAML API definition
body: <h2>I am trying to find way, how to call external API based on YAML definition:</h2>
  <ul>
  <li>I have (Spring boot, external) API-1, generated with OpenAPI plugin, which has
  it's YAML file.</li>
  <li>I have (Spring boot) API-2, which calls API-1. But all I have is YAML definition of API-1.</li>
  </ul>
  <p>We know external API can be called with:</p>
  <pre><code>@Bean
  public WebClient remoteApiBean() {
      return WebClient.create(&quot;http://example.com/api&quot;);
  }
  </code></pre>
  <p>And e.g. Service implementation:</p>
  <pre><code>@Autowired
  public MyService(WebClient remoteApiBean) {
      this.remoteApiBean = remoteApiBean;
  }
  </code></pre>
  <p>And requesting resource</p>
  <pre><code>this.remoteApiBean.get()
              .uri(&quot;/request&quot;)
              .retrieve()
              .bodyToMono(ModelDTO.class)
              .block(REQUEST_TIMEOUT);
  </code></pre>
  <p>API and model info are stored inside of API-1 YAML config. My question is, if it is possible to use API-1 YAML definition as a resource for API-2. Generate code above and also generate DTOs. I think, there MUST be any plugin which generate this, but I am unable to find it, because there are very similar issues with Spring Boot yaml external configurations and google result are bad according this searching.</p>