This video comes from a camera attached to a homebuilt device that rose to great heights. The Guardian describes it in a short paragraph (and also, elsewhere, in more detail):
Two teenagers from Toronto sent a Lego man carrying a Canadian flag into the stratosphere. Mathew Ho and Asad Muhammad, both 17, attached four cameras to a balloon carrying the toy astronaut 24km above Earth. A week after launch they recovered their Lego man in a field, and discovered they had captured stunning space footage
(Thanks to investigator Greg Johnson for bringing this to our attention.)