1
0
dust/examples/async_download.ds

14 lines
435 B
Plaintext
Raw Permalink Normal View History

2023-11-05 18:54:29 +00:00
raw_data = async {
{
2023-11-04 10:02:27 +00:00
cast = (download "https://api.sampleapis.com/futurama/cast")
characters = (download "https://api.sampleapis.com/futurama/characters")
episodes = (download "https://api.sampleapis.com/futurama/episodes")
2023-11-05 18:54:29 +00:00
}
}
2023-11-04 10:02:27 +00:00
cast_len = (length (from_json data:cast))
characters_len = (length (from_json data:characters))
episodes_len = (length (from_json data:episodes))
2023-11-05 18:54:29 +00:00
(output [cast_len, characters_len, episodes_len])