Giter Site home page Giter Site logo

gzic_bus's Introduction

gzic_bus

华南理工大学广州国际校区校巴预约API(对应GZIC智慧服务小程序)

摆脱这个巨卡无比的小程序

项目介绍

  • api文件夹为校巴相关接口的爬虫(包含校巴查看、预约、获取二维码等接口)
  • cli文件夹为命令行脚本相关模块,可以直接运行进行预约等操作
  • 整理了校巴接口的文档,方便用别的语言重写

cli使用方法

  1. 安装依赖(requestsquestionary)

    pip install -r requirements.txt

    如果你使用nix包管理器的话,只要运行以下命令,便可以进入一个包含所有依赖(包括python)的环境(请确保您启用了nix flake, 教程):

    nix develop
  2. 运行脚本

    python main.py
    
  3. 关于token

    校巴接口需要传递token作为鉴权header,本程序会将token保存为.token文件,首次使用将进行统一认证登陆获取token,之后默认读取本地文件。token有效期较长,不需要经常更新。

cli功能

  • 预约校巴

    非常简单的起点终点选择,而不是反应缓慢的小程序点击

    日期的选择,只查看某一天的班次,而不是小程序的杂乱列表

    几个回车就能马上预约到校巴,而小程序可能刚刚加载好

  • 查看已预约校巴

    列出预约未乘坐的班次,只显示有用的信息

    轻松取消校巴

后续更新方向

  1. 自动预约脚本
  2. 抢票脚本

gzic_bus's People

Contributors

chfanghr avatar thungghuan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

xty435768

gzic_bus's Issues

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.