安装phone模块, pip install phone
Python(phone)模块获取手机号归属地、区号、运营商
from phone import Phone
phoneNum = '131*******3'
c = Phone().find(phoneNum)
print(c)
phone = c['phone']
province = c['province']#获得省份
city = c['city'] #获得所在城市
zip_code = c['zip_code'] #获得邮编
area_code = c['area_code']#获得区号
phone_type = c['phone_type']#获得运营商