title: json schema for a map of similar objects
body: <p>I wish to write a json schema to cover this (simplified) example</p>
  
  <pre><code>{
      "errorMessage": "",
      "nbRunningQueries": 0,
      "isError": False,
      "result": {
          "foo": {"price":10.0, "country":"UK"},
          "bar": {"price":100.2, "country":"UK"}
      }
  }
  </code></pre>
  
  <p>which can have this pretty trivial root schema</p>
  
  <pre><code>schema = {
      "type":"object",
      "required":True,
      "properties":{
          "errorMessage": {"type":"string", "required":True},
          "isError": {"type":"boolean", "required":True},
          "nbRunningQueries": {"type":"number", "required":True},
          "result": {"type":"object","required":True}
      }
  }
  </code></pre>
  
  <p>The complication is the results {} element. Unlike a standard pattern where results would be an array of same objects - each with an id field or similar this response models a python dictionary which looks like this:</p>
  
  <pre><code>{
      "foo": {},
      "bar": {},
      ...
  }
  </code></pre>
  
  <p>So given that a will be getting a results object of flexible size with no set keys how can I write json schema for this?</p>
  
  <p>I don't control the input sadly or I'd rewrite it to be something like</p>
  
  <pre><code>{
      "errorMessage": "",
      "nbRunningQueries": 0,
      "isError": False,
      "result": [
          {"id": "foo", "price":10.0, "country": "UK"},
          {"id": "bar", "price":100.2, "country":"UK"}
      ]
  }
  </code></pre>
  
  <p>Any help or links to pertinent examples would be great. Thanks.</p>