Last active
August 29, 2015 13:58
-
-
Save potato4d/10003605 to your computer and use it in GitHub Desktop.
Tes.so SNS Post. Attention: tssns2.dll is necessary
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!python2 | |
#coding:utf-8 | |
import sys | |
from ctypes import * | |
if __name__ == '__main__': | |
lib = windll.tssns2 | |
ID = "YourID" | |
PASS = "YourPassword" | |
print('////////////////////') | |
print('Tes.so sns client') | |
print('////////////////////') | |
print('') | |
print('ID:'+ID) | |
print('\n') | |
stat = lib.TsSnsConnectA("test") | |
if(lib.TsSnsLoginA(stat, ID, PASS) == 0): | |
sys.exit() | |
buf = pointer(c_int(0)) | |
while(True): | |
post = raw_input(">>>") | |
if(post == 'exit'): | |
sys.exit() | |
if(post == ''): | |
print(u"発言が空欄です!") | |
lib.TsSnsPostMsgA(stat, 1, post, buf) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment