In this example included in Scriptable on Line 6 where can I get the documentation that explain the data structure (properties and methods) for the json object that it is returned. I haven’t been able to find documentation that explains jason.items, why .items? thank you
There’s no documentation for that in Scriptable since the object is not exposed by Scriptable. The JSON is loaded using
await req.loadJSON() and then stored in the
json.items, we read the
items property in the data defined by MacStories. If you look at the JSON located at the URL (https://www.macstories.net/feed/json) you will notice there’s an attribute named
items. That’s what we’re reading.
To get a better understanding of how the JSON object is structured, you can call
Side note: In this concrete case, you can refer to the spec for JSON feed. JSON feed is a format similar to Atom and RSS for exposing a feed of items. A lot of times this is news stories.
The point I was trying to make above, still stands. Since the data is loaded from a third party source, there’s no documentation of it in Scriptable. Sometimes you’ll find documentation on the third party side
Thank you VERY much for the detailed explanation, now I fully understand it.