title: Swashbuckle OperationFilter to Add Parameter of Type Object
body: <p>I have a C# object</p>
  
  <pre class="lang-cs prettyprint-override"><code>public class MyObject
  {
   public int property1 { get; set; }
   public string property2 { get; set; }
   public string property3 { get; set; }
  }
  </code></pre>
  
  <p>I want to create a parameter of type object that has the schema of <code>MyObject</code>.</p>
  
  <pre class="lang-cs prettyprint-override"><code>public class MyFilter : IOperationFilter
  {
   public void Apply(OpenApiOperation operation, OperationFilterContext context)
   {
     operation.Parameters.Add(new OpenApiParameter
     {
      Name = "MyParameter",
      Description = "MyDescription"
      In = ParameterLocation.Header
      Required = true,
      Schema = new OpenApiSchema()
      {
       Type = "object",
       Properties = new Dictionary&lt;string, OpenApiSchema&gt;()
       {
         // MyObject
       }
      }
     }
    }
  }
  </code></pre>
  
  <p>Does Swashbuckle provide any methods that can automatically generate the properties with the schema of <code>MyObject</code>.</p>