title: OpenUI/Swagger java to API
body: <p>Creating rest api project using spring boot + OpenUI/Swagger for api description.</p>
  <pre><code>implementation 'org.springdoc:springdoc-openapi-ui:1.4.6'
  </code></pre>
  <p>Rest api is complex. Each rest endpoint in result sending callback. Which can be described in OpenApi UI(and in generated yaml).
  This is how im describing callbacks in java code:</p>
  <pre><code>@Callbacks({
  
      @Callback(name = &quot;testCallback&quot;,
  
              operation = @Operation(
  
                      summary = &quot;Book Callback&quot;
  
              ),
  
              ref = &quot;#/components/schemas/CBResp&quot;),
  
      @Callback(name = &quot;testCallback2&quot;,
  
              operation = @Operation(
  
                      summary = &quot;Book Callback2&quot;
  
              ),
  
              ref = &quot;#/components/schemas/CBResp&quot;)})
  </code></pre>
  <p>In resulting yml file see:</p>
  <pre><code>&quot;callbacks&quot;: {
  
        &quot;testCallback&quot;: {
  
          &quot;$ref&quot;: &quot;#/components/schemas/CBResp&quot;
  
        }
  
      }
  </code></pre>
  <p>Only 1 callback without many properties.  For me its looking like a heavy bug.
  At the same time in documentation i see &quot;detailed&quot; description <a href="https://springdoc.org/#are-callbacks-supported" rel="nofollow noreferrer">https://springdoc.org/#are-callbacks-supported</a></p>
  <p>Anyone know how to describe rest calbacks in Java and generate yml?</p>
  <p>Thank you.</p>