STONJSON fromString:
(ZnClient new
accept: 'application/vnd.github.v3+json';
get).
I can get PNG contents executing:
pngData := (ZnEasy get:
((((STONJSON fromString:
(ZnClient new
accept: 'application/vnd.github.v3+json';
get)) at: 'files') at: 'thumbnail.png') at: 'raw_url')) contents.
PNGReadWriter formFromStream: rawPng readStream.
But the PNG image is part of the Gist query and can be retrieved by:
pngContent := ((((STONJSON fromString:
(ZnClient new
accept: 'application/vnd.github.v3+json';
get)) at: 'files') at: 'thumbnail.png') at: 'content').
"As pngContent is a WideString, I cannot use:"
PNGReadWriter formFromStream: pngContent readStream.