Pixiv 爬虫,使用 Python 实现。支持批量下载、上传到图床。

Overview

用 Python 实现的 Pixiv 爬虫,支持批量下载和上传。

随机图片 API: https://loliapi.ml/

Deploy

Github Action 集成部署

建议使用本方法部署,相较于本地部署,无需搭建环境,全程在线上完成。并且使用国外服务器下载、上传,网络更加通畅。

  1. Fork 本项目,并给这个 repo 一颗小星星。
  2. 点击 Actions 选项卡,开启 Github Action。
  3. 新建一个 Token,需要 repo 权限。
  4. 在仓库的 Settings --> Secrets 中新建秘钥 personal_token,填写你的 Github Token。
  5. 若要立即看到效果,请随意修改 main 分支,触发 Github Action。

本地部署

  1. 下载本项目,并给这个 repo 一颗小星星。
  2. 安装好 wgetpiprequests
  3. 用 Python 3 运行 main.py,默认上传到图床 SM.MS。

Customize

R-18

修改 main.py 中的 url,如下

url = 'http://api.lolicon.app/setu/v2?r18=1'

P.S. 这并不是严格意义上的 R-18,详见 API 文档

图床

默认使用 SM.MS 图床。因为 Github Action 单次运行是新建一个完全不同的虚拟化环境,所以可以绕过图床的每日上传限制。

理论上可以自己根据图床提供的 API 来修改,但是经过作者的尝试,只有 SM.MS 支持 pixiv 大多数尺度的照片。国内的部分图床(例如去不图床)不允许上传此类图片。

图片类型

请阅读 API 文档,修改 main.py 中的 url

To Do

  • repo 主想要实现的功能好像都在了呢~ 提个 issue 吧

Thanks

API: https://api.lolicon.app/#/setu

Warning

所有图片均来自 Pixiv,版权也归作品的作者所有。本项目只是出于兴趣爱好和研究用途搭建,严禁将本项目爬取的照片用于商业用途!

若您是未成年人,请自觉抵制 R-18 和露骨内容,遵守您所处国家的法律法规,谢谢配合!

You might also like...
A python Discord wrapper made in well, python.

discord.why A python Discord wrapper made in well, python. Made to be used by devs who want something a bit more, general. Basic Examples Sending a me

A wrapper for aqquiring Choice Coin directly through a Python Terminal. Leverages the TinyMan Python-SDK.

CHOICE_TinyMan_Wrapper A wrapper that allows users to acquire Choice Coin directly through their Terminal using ALGO and various Algorand Standard Ass

Python On WhatsApp - Run your python codes on whatsapp along with talking to a chatbot
Python On WhatsApp - Run your python codes on whatsapp along with talking to a chatbot

Python On WhatsApp Run your python codes on whatsapp along with talking to a chatbot This is a small python project to run python on whatsapp. and i c

Get-Phone-Number-Details-using-Python - To get the details of any number, we can use an amazing Python module known as phonenumbers.

Get-Phone-Number-Details-using-Python To get the details of any number, we can use an amazing Python module known as phonenumbers. We can use the amaz

Python-random-quote - A file-based quote bot written in Python

Let's Write a Python Quote Bot! This repository will get you started with building a quote bot in Python. It's meant to be used along with the Learnin

Student-Management-System-in-Python - Student Management System in Python
Student-Management-System-in-Python - Student Management System in Python

Student-Management-System-in-Python Student Management System in Python

WhatsApp Api Python - This documentation aims to exemplify the use of Moorse Whatsapp API in Python
WhatsApp Api Python - This documentation aims to exemplify the use of Moorse Whatsapp API in Python

WhatsApp API Python ChatBot Este repositório contém uma aplicação que se utiliza

OpenSea-Python-Bot - OpenSea Python Bot can be used in 2 modes

OpenSea-Python-Bot OpenSea Python Bot can be used in 2 modes. When --nft paramet

Cdk-python-crud-app - CDK Python CRUD App

Welcome to your CDK Python project! You should explore the contents of this proj

Owner
No Coding No Life
null
Follow pixiv account from twitter profile

Follow pixiv account from twitter profile

Genshi 7 Apr 11, 2022
Official Python client for the MonkeyLearn API. Build and consume machine learning models for language processing from your Python apps.

MonkeyLearn API for Python Official Python client for the MonkeyLearn API. Build and run machine learning models for language processing from your Pyt

MonkeyLearn 157 Nov 22, 2022
PRAW, an acronym for "Python Reddit API Wrapper", is a python package that allows for simple access to Reddit's API.

PRAW: The Python Reddit API Wrapper PRAW, an acronym for "Python Reddit API Wrapper", is a Python package that allows for simple access to Reddit's AP

Python Reddit API Wrapper Development 3k Dec 29, 2022
PRAW, an acronym for "Python Reddit API Wrapper", is a python package that allows for simple access to Reddit's API.

PRAW: The Python Reddit API Wrapper PRAW, an acronym for "Python Reddit API Wrapper", is a Python package that allows for simple access to Reddit's AP

Python Reddit API Wrapper Development 3k Dec 29, 2022
alpaca-trade-api-python is a python library for the Alpaca Commission Free Trading API.

alpaca-trade-api-python is a python library for the Alpaca Commission Free Trading API. It allows rapid trading algo development easily, with support for both REST and streaming data interfaces

Alpaca 1.5k Jan 9, 2023
🖥️ Python - P1 Monitor API Asynchronous Python Client

??️ Asynchronous Python client for the P1 Monitor

Klaas Schoute 9 Dec 12, 2022
Volt is yet another discord api wrapper for Python. It supports python 3.8 +

Volt Volt is yet another discord api wrapper for Python. It supports python 3.8 + How to install [Currently Not Supported.] pip install volt.py Speed

Minjun Kim (Lapis0875) 11 Nov 21, 2022
Bagas Mirror&Leech Bot is a multipurpose Telegram Bot written in Python for mirroring files on the Internet to our beloved Google Drive. Based on python-aria-mirror-bot

- [ MAYBE UPDATE & ADD MORE MODULE ] Bagas Mirror&Leech Bot Bagas Mirror&Leech Bot is a multipurpose Telegram Bot written in Python for mirroring file

null 4 Nov 23, 2021