My favorites | Sign in
Project Home Downloads Source
Checkout   Browse   Changes    
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# -*- coding: utf-8 -*-
from me2day import me2API

if __name__=='__main__':
# api = me2API('_username_', '_userkey_', '_application_key_')
api = me2API('rath')
for f in api.get_friends():
print "%s(%s)" % (f.id, f.nickname)

# api.create_comment({'post_id': 'p2mjxx', 'body': 'just for test'})

for p in api.get_posts({'scope': 'friend[close]', 'count': 20}):
print p.id + ", " + p.author.nickname + ": " + p.body_as_text

for metoo in api.get_metoos({'post_id': p.id}):
person, date = metoo
print date + ", " + person.nickname

for comment in api.get_comments({'post_id': p.id}):
print " %s, %s: %s" % (comment.id, comment.author.nickname, comment.body)

api.noop()

Change log

r22 by xrathx on Sep 13, 2009   Diff
test script for me2day API.
Go to: 
Project members, sign in to write a code review

Older revisions

All revisions of this file

File info

Size: 761 bytes, 22 lines
Powered by Google Project Hosting