import requests

import random
import requests

from useragents import *

# 获取随机headers
def get_headers():
    headers = {'User-Agent':random.choice(ua_list)}

    return headers

def total_number():
    # F12抓包抓到的地址
    url = 'https://movie.douban.com/j/chart/top_list_count?type={}&interval_id=100%3A90'.format(17)
    headers = get_headers()
    html = requests.get(url=url, headers=headers).json()
    total = int(html['total'])
    print(html)
    print(total)

total_number()



41d4c963b69293645d92d58725e3f15f38072857
<mask token>


def get_headers():
    headers = {'User-Agent': random.choice(ua_list)}
    return headers


<mask token>

<mask token>


def get_headers():
    headers = {'User-Agent': random.choice(ua_list)}
    return headers


def total_number():
    url = (
        'https://movie.douban.com/j/chart/top_list_count?type={}&interval_id=100%3A90'
        .format(17))
    headers = get_headers()
    html = requests.get(url=url, headers=headers).json()
    total = int(html['total'])
    print(html)
    print(total)


<mask token>

<mask token>


def get_headers():
    headers = {'User-Agent': random.choice(ua_list)}
    return headers


def total_number():
    url = (
        'https://movie.douban.com/j/chart/top_list_count?type={}&interval_id=100%3A90'
        .format(17))
    headers = get_headers()
    html = requests.get(url=url, headers=headers).json()
    total = int(html['total'])
    print(html)
    print(total)


total_number()

import requests
import random
import requests
from useragents import *


def get_headers():
    headers = {'User-Agent': random.choice(ua_list)}
    return headers


def total_number():
    url = (
        'https://movie.douban.com/j/chart/top_list_count?type={}&interval_id=100%3A90'
        .format(17))
    headers = get_headers()
    html = requests.get(url=url, headers=headers).json()
    total = int(html['total'])
    print(html)
    print(total)


total_number()

import requests

import random
import requests

from useragents import *

# 获取随机headers
def get_headers():
    headers = {'User-Agent':random.choice(ua_list)}

    return headers

def total_number():
    # F12抓包抓到的地址
    url = 'https://movie.douban.com/j/chart/top_list_count?type={}&interval_id=100%3A90'.format(17)
    headers = get_headers()
    html = requests.get(url=url, headers=headers).json()
    total = int(html['total'])
    print(html)
    print(total)

total_number()


