I am using the stackAPI Python wrapper to interface with the stackexchange api. I am trying to fetch the top most popular questions above a vote count threshold; and for each of those questions the top answers above a certain vote count.
SITE = StackAPI("stackoverflow")
SITE.max_pages=2
SITE.page_size=100
questions = SITE.fetch('questions', min=10, sort='votes')
for quest in questions['items']:
if 'title' not in quest: continue
quest_id = quest['question_id']
title = quest['title']
tags = []
if 'tags' in quest:
tags = quest['tags']
#body = quest['body']
body = ""
if 'body' in quest:
body = quest['body']
answers = SITE.fetch('answers', id=[quest_id],min=10, sort='votes')
for answer in answers['items']:
_stuck here_
This is where I am stuck, how to fetch answers for the above question_id
this query is returning some random answer_ids. How do fetch the question-< answers