0

For example, get the quarterly numbers from https://finance.yahoo.com/quote/AAPL/financials?p=AAPL

Rubén
  • 34,714
  • 9
  • 70
  • 166
Arbie
  • 91
  • 1
  • 6

1 Answers1

0

Since the page is built client side (not server side) by javascript, you need to grab the json from the source code and parse it by

  var source = UrlFetchApp.fetch(url).getContentText()
  var jsonString = source.match(/(?<=root.App.main = ).*(?=}}}};)/g) + '}}}}'
  var data = JSON.parse(jsonString)

you can then be able to retrieve all the data.

Mike Steelson
  • 14,650
  • 2
  • 5
  • 20