extracting images from hangouts
Download images from a google takeout dump of hangouts. Requires: jq
, grep
, and wget
.
If you want all media, you can just use grep for image_url
, clean up the json remnants, then download with wget -i
If you only want a single conversation and the other user's images, you'll need to use something like jq
to extract the relevant hangout events before grepping.
cat Takeout/Hangouts/Hangouts.json | \
jq -c '.conversation_state[] | \
select(.conversation_id.id=="CONVERSATION_ID") | \
.conversation_state.event[] | \
select(.sender_id.gaia_id=="SENDER_ID")' | \
jq . | grep image_url | \
sed 's|^\s*"image_url": "||g' | \
sed 's|",$||g'