review() function returns all fields

Signed-off-by: Domenico Iezzi <domenico.iezzi.201@gmail.com>
This commit is contained in:
Domenico Iezzi 2017-10-10 18:55:03 +02:00
parent 3b37b18542
commit b8412dd68a

View File

@ -402,13 +402,21 @@ class GooglePlayAPI(object):
if(filterByDevice): if(filterByDevice):
path += "&dfil=1" path += "&dfil=1"
data = self.executeRequestApi2(path) data = self.executeRequestApi2(path)
reviews = [rev for rev in data.payload.reviewResponse.getResponse.review] output = []
return [{'documentVersion': r.documentVersion, for rev in data.payload.reviewResponse.getResponse.review:
'timestampMsec': r.timestampMsec, author = {'personIdString': rev.author2.personIdString,
'starRating': r.starRating, 'personId': rev.author2.personId,
'comment': r.comment, 'name': rev.author2.name,
'commentId': r.commentId, 'profilePicUrl': rev.author2.urls.url,
'author': r.author2.name} for r in reviews] 'googlePlusUrl': rev.author2.googlePlusUrl}
review = {'documentVersion': rev.documentVersion,
'timestampMsec': rev.timestampMsec,
'starRating': rev.starRating,
'comment': rev.comment,
'commentId': rev.commentId,
'author': author}
output.append(review)
return output
def delivery(self, packageName, versionCode, def delivery(self, packageName, versionCode,
offerType=1, downloadToken=None, progress_bar=False): offerType=1, downloadToken=None, progress_bar=False):