title: swagger api documentation issues with nested objects
body: <p>I want to use swagger to document our internal Jenkins Jobs and parameters. So that everybody knows what the body has to look like to properly trigger a Jenkins jobs over the API.</p>
  <p>I am writing the API documentation with a swagger.yml file. Where I am totally struggling is to document nested objects.</p>
  <p>Jenkins needs the parameters in JSON. The curl request looks like this</p>
  <pre><code>curl --request POST \
    --url https://myjenkins.com/job/demojob/build \
    --form 'json={
      &quot;parameter&quot;: [
          {
           &quot;name&quot;: &quot;FilePath&quot;, 
           &quot;value&quot;: &quot;E:\\Jenkins&quot;
          },
          {
       &quot;name&quot;: &quot;FileName&quot;, 
           &quot;value&quot;: &quot;JenkinsAPI.txt&quot;
          },
          {
       &quot;name&quot;: &quot;FileContent&quot;, 
           &quot;value&quot;: &quot;I am a file created by jenkins through API&quot;
          },
          {
       &quot;name&quot;: &quot;Computer&quot;, 
           &quot;value&quot;: &quot;myhost&quot;
          }
      ]
  }'
  </code></pre>
  <p>I am able to create a yml file that contains something like this, and that does not resemble what I need at all.</p>
  <p>Can somebody point me in the right direction, or give me an example?</p>
  <pre><code>paths:
    /job/demojob/build:
      post:
        summary: triggers the job           
        parameters:
          - name: parameters
            in: body
            required: true
          - name: filePath
            in: body
            schema:
              type: string
              default: &quot;C:\\fancyfolder&quot;
  </code></pre>