title: Extract field from JSON response with Ansible
body: <p>I have a task which performs a GET request to a page. The response's body is a JSON like the following. </p>
  
  <pre><code> {
    "ips": [
      {
        "organization": "1233124121",
        "reverse": null,
        "id": "1321411312",
        "server": {
          "id": "1321411",
          "name": "name1"
        },
        "address": "x.x.x.x"
      },
      {
        "organization": "2398479823",
        "reverse": null,
        "id": "2418209841",
        "server": {
          "id": "234979823",
          "name": "name2"
        },
        "address": "x.x.x.x"
      }
    ]
  }
  </code></pre>
  
  <p>I want to extract the fields id and address, and tried (for id field):</p>
  
  <pre><code>tasks:
    - name: get request                                           
      uri:
        url: "https://myurl.com/ips"
        method: GET
        return_content: yes
        status_code: 200
        headers:
          Content-Type: "application/json"
          X-Auth-Token: "0010101010"
        body_format: json
      register: json_response 
  
  
    - name: copy ip_json content into a file
      copy: content={{json_response.json.ips.id}} dest="/dest_path/json_response.txt"
  </code></pre>
  
  <p>but I get this error: </p>
  
  <p>the field 'args' has an invalid value, which appears to include a variable
   that is undefined. The error was: 'list object' has no attribute 'id'..</p>
  
  <p>Where is the problem?</p>