Code Monkey home page Code Monkey logo

smzdm_bot-1's Introduction

什么值得买每日签到脚本

1. 实现功能

  • 什么值得买每日签到
  • Github Action(两种配置方式,直接运行或者调用 Docker 运行)
  • 本地 Docker 定时运行
  • 通过pushplus推送运行结果到微信(不推荐)
  • 通过server酱推送运行结果到微信
  • 通过telegram bot推送
  • 自定义反代Telegram Bot API, 搭建教程

2. 使用方法

2.1 Git action 运行

  1. Fork此仓库项目>点击右上角 Fork 按钮即可, 欢迎点star~
  2. 修改 .github/workflows/run.yml里的下面部分, 取消注释,修改为你自己的时间
name: "SMZDM Check-in Bot"

on:
  workflow_dispatch:

  schedule:
    - cron: "0 18 * * *"
  1. Secret 新增SMZDM_COOKIE, 填入什么值得买官网获取的 Cookie 信息, 详见
  2. (可选) Secret 新增PUSH_PLUS_TOKEN用于推送通知, 详见
  3. (可选) Secret 新增SC_KEY用于推送通知, 详见
  4. (可选) Secret 新增TG_BOT_TOKENTG_USER_ID用于推送通知
  5. (可选) Secret 新增TG_BOT_API用于自定义反代的Telegram Bot API

2.2 本地运行

配置config.toml运行, 生成config/config_example.toml并按照需求配置

cp config/config_example.toml config/config.toml

2.3 本地 docker 运行

docker-compose.yml

本地生成一个.env 文件, 用于配置 docker-compose.yml 运行所需要的环境变量, 如下:

SMZDM_COOKIE=__ckguid=
PUSH_PLUS_TOKEN=
SC_KEY=
TG_BOT_TOKEN=
TG_USER_ID=
# 定时设定(可选), 若没有设定则随机定时执行
SCH_HOUR=
SCH_MINUTE=

2.4 使用 Cookie Editor

也可以使用浏览器扩展 Cookie Editor导出 cookies, 另存为cookies.json在项目的根目录

3. 其它

3.1 Cookie 获取方法

  • 使用 Chrome 浏览器访问什么值得买官网, 登录账号
  • 打开开发者工具 (Windows 快捷键F12, MacOS 快捷键option + command + i)
  • 选择 Network, 刷新页面, 选择第一个www.smzdm.com, 找到Requests Headers里的Cookie

smzdm_bot-1's People

Contributors

chasing66 avatar dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.