blob: 472ac5abb373678f176df93f1111385c1c05c415 [file] [log] [blame]
Joe Gregorio2379ecc2010-10-26 10:51:28 -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 running against a
7 local server.
8
9"""
10
11__author__ = 'jcgregorio@google.com (Joe Gregorio)'
12
13# Enable this sample to be run from the top-level directory
14import os
15import sys
16sys.path.insert(0, os.getcwd())
17
18from apiclient.discovery import build
19
20import httplib2
21# httplib2.debuglevel = 4
22import pickle
23import pprint
24
Joe Gregorioaf276d22010-12-09 14:26:58 -050025DISCOVERY_URI = ('http://localhost:3990/discovery/v0.2beta1/describe/'
Joe Gregorio2379ecc2010-10-26 10:51:28 -040026 '{api}/{apiVersion}')
27
Joe Gregorioaf276d22010-12-09 14:26:58 -050028
Joe Gregorio2379ecc2010-10-26 10:51:28 -040029def main():
30 http = httplib2.Http()
31
32 p = build("buzz", "v1", http=http, discoveryServiceUrl=DISCOVERY_URI)
33 help(p.activities().list)
34 print p.activities().list(userId='@self', scope='@me', c='foo').uri
35
36if __name__ == '__main__':
37 main()