QQ Music reptiles

# Today target
 
** ** QQ music reptiles 
today are crawling all QQ music lyrics any music singer, because I was a big fan of Jay, so specially wrote a reptile crawling his lyrics to music, because he the music can listen to music in microphone cushions, so they do not take the climb. 
Well, given directly below the code! 

* Code implementation * 
`` ` 
Import Requests
 Import   CSV 
Singer, = the INPUT ( ' your favorite singer who is? \ The n- ' ) 
url = ' https://cyqq.com/soso/fcgi-bin/client_search_cp? ' 
Headers = {
 ' the User-- Agent ' : ' the Mozilla / 5.0 (the Windows NT 10.0; Win64; x64-) AppleWebKit / 537.36 (KHTML, like the Gecko) the Chrome / 73.0.3683.103 Safari / 537.36 ' 
} 
for X in range(50):
    params={
    'ct':' 24',
    'qqmusic_ver': '1298',
    'remoteplace':'txt.yqq.lyric',
    'searchid': '105425534333318532',
    'aggr': '0',
    'catZhida':'1',
    'lossless':' 0',
    'sem':'1',
    't': '7',
    'p': str(x),
    'n':'5',
    'w':singer,
    'g_tk':'5381',
    'loginUin':'0',
    'hostUin':'0',
    'format': 'json',
    'inCharset': 'utf8',
    'outCharset': 'utf-8',
    'notice':'0',
    'platform': 'yqq.json',
    'needNewCode': '0'
    }

    res=requests.get(url,headers=headers,params=params)
    json_lyric=res.json()
    list_lyric=json_lyric['data']['lyric']['list']
    for lyric in list_lyric:
        print(lyric['content'])
        print('='*50)

```

 

Guess you like

Origin www.cnblogs.com/cxiaolong/p/11318495.html