title: How to flatten an object in GraphQL?
body: <p>I have a nested javascript class (see below) that is exposed through my GraphQL server. Can I write a GQL schema that exposes this complex structure as a single object? (aka flattened). </p>
  
  <h2>The Nested Object</h2>
  
  <pre><code>interface Promotion {
      id
      type 
      data: PromotionType1 | PromotionType2 
  }
  
  interface PromotionType1 {
      a
      b 
  }
  
  interface PromotionType2 {
      c
      d
  }
  </code></pre>
  
  <h2>The desired GQL query to access the Object</h2>
  
  <p>I want to write a GQL schema so that I can query this object as follows:</p>
  
  <pre><code>promotion(id: "123") {
      id
      type
      ... on PromotionType1 {
          a
          b
      }
      ... on PromotionType2 {
          c
          d
      }
  }
  </code></pre>
  
  <p>Is this possible with GQL?</p>