blob: 36f354ad56629e566295d3d2871d4d6524257080 [file] [log] [blame]
Joe Gregorioa2f56e72010-09-09 15:15:56 -04001#!/usr/bin/python2.4
2# -*- coding: utf-8 -*-
3#
4# Copyright 2010 Google Inc. All Rights Reserved.
5
6"""Simple command-line example for Buzz.
7
8Command-line application that retrieves the users
9latest content and then adds a new entry.
10"""
11
12__author__ = 'jcgregorio@google.com (Joe Gregorio)'
13
14
15from apiclient.discovery import build
16
17import httplib2
18import pickle
19
20
21def main():
22 f = open("moderator.dat", "r")
23 credentials = pickle.loads(f.read())
24 f.close()
25
26 http = httplib2.Http()
27 http = credentials.authorize(http)
28
29 p = build("moderator", "v1", http=http)
Joe Gregorio5f087cf2010-09-20 16:08:07 -040030 print p.submissions().list(seriesId="7035", topicId="64").execute()
Joe Gregorioa2f56e72010-09-09 15:15:56 -040031
32if __name__ == '__main__':
33 main()