$processor$: http
-- record repo: string full_name: string description: string html_url: integer stargazers_count: integer watchers_count: -- record result: integer total_count: 0 repo list items: -- result r:
repo
, and result
. We also have a variable of type result
. Lets initialise this variable with result of fetching the top repositories from Github:
-- r: $processor$: http url: https://api.github.com/search/repositories sort: stars order: desc q: language:python
url: string
The response of the JSON must match with type of the variable where we are storing the result, here it is r
of type record
defined above.