def ff():
    print('关注者基本信息的格式为' + '\n' + '[序号, 个性域名, 昵称, 赞同数, 感谢数, 关注者人数]')
    for i in range(len(r2)):
        r3 = api.user(r2[i]).detail()
        r4 = [i, r3['urlToken'], r3['name'], r3['voteupCount'], r3['thankedCount'], r3['followerCount']]
        r5.append(r4)
        print(r4)
Beispiel #2
0
def ff():
    for i in range(len(r2)):
        r3 = api.user(r2[i]).detail()
        r4 = [
            i, r3['urlToken'], r3['name'], r3['voteupCount'],
            r3['thankedCount'], r3['followerCount']
        ]
        r5.append(r4)
        print(r4)
Beispiel #3
0
def followers(me, page):
    for i in range(page):
        data = api.user(me).followers(offset=(20 * i))
        for j in range(len(data)):
            r1.append(data[j]['name'])  # 关注者的昵称
            r2.append(data[j]['url_token'])  # 关注者的个性域名
Beispiel #4
0
def hash_id():
    for i in range(len(r2)):
        r3 = api.user(r2[i]).detail()
        r4 = [r3['id']]
        r5.append(r4)
    print(r5)
Beispiel #5
0
import zhihuapi as api

with open('cookie') as f:
    api.cookie(f.read())

u = api.user("aqdshg")

print(u.profile())