title: How to fix 'response.json is not a function' in async/await function
body: <p>Trying to turn my response into json. I'm not quite sure I'm getting <code>TypeError: response.json is not a function</code> error. Can someone please point me in the right direction. Thanks in advance.</p>
  
  <pre><code>    componentDidMount(){
          this.timingFunction = setInterval(() =&gt; this.getAllStations(), 1000);
      }
  
  
      async getAllStations(){
          try{
              const response = await(`http:api.bart.gov/api/etd.aspx?cmd=etd&amp;orig=${this.state.selectedStation}&amp;key=${bartKey}&amp;json=y`);
              const data = await response.json();
              console.log(`Here: ${data}`)
  
  
          }catch(e){
              console.log(`Error: ${e}`)
          }
  
      }
  </code></pre>
  
  <p>I expected to see the json response but got the error message.
  edit: Added await in front of response.json(); and got no where.</p>