Giter Site home page Giter Site logo

zhangchengtest / waimai-crawler Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mudiyouyou/waimai-crawler

0.0 2.0 0.0 153 KB

外卖爬虫,定时自动抓取三大外卖平台上商家订单,平台目前包括:美团,饿了么,百度外卖

License: MIT License

JavaScript 2.36% Shell 0.01% HTML 97.64%

waimai-crawler's Introduction

外卖订单爬虫:美团,饿了么,百度


这个程序是用来抓取外卖平台(美团,饿了么,百度)的商户订单开发,并不是一个通用库,而是为这个 特定场景进行开发的。 适用场景:餐饮企业拥有多家外卖门店,订单量非常大,有对订单进行数据分析的需求。 主要功能:每天定时启动,抓取三大外卖平台的订单,转成成excel文件,发邮件给需要的人

如何使用

修改config目录下的production.json

{
  "log": {
    "level": "DEBUG"
  },
  "mail": {
    "from": "[email protected]", //邮件发送人
    "mailTo": "[email protected]", //邮件接收人
    "host":"smtp.xxx.com",
    "port":25,
    "secure":false,
    "user":"[email protected]",  //程序使用的邮件
    "pass":"程序使用的邮件的密码"
  },
  "imgCode":{
    "key":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxx"   // https://www.juhe.cn/docs/api/id/60  识别验证码api的key
  },
  "account": [
    {
      "name": "美团xxx店",
      "username": "帐户名",
      "password": "账户密码",
      "type": "meituan"
    },
    {
      "name": "饿了么xxx店",
      "username": "帐户名",
      "password": "账户密码",
      "type": "eleme"
    },
    {
      "name": "百度xxx店",
      "username": "帐户名",
      "password": "账户密码",
      "type": "baidu"
    }
  ]
}

其中以下配置是程序中使用验证码识别的api服务, 美团,百度的商家后台都需要验证码登录 api服务使用的是聚合数据的验证码识别服务,你需要先 申请聚合数据的账号,充值后得到key 填写到如下配置项中去。

"imgCode":{
    "key":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxx"   // https://www.juhe.cn/docs/api/id/60  识别验证码api的key
  },

邮件功能需要配置详细的smtp服务地址、发件人账号名、密码、端口、是否使用ssl

"mail": {
    "from": "[email protected]", //邮件发送人
    "mailTo": "[email protected]", //邮件接收人
    "host":"smtp.xxx.com",
    "port":25,
    "secure":false,
    "user":"[email protected]",  //程序使用的邮件
    "pass":"程序使用的邮件的密码"
  },

waimai-crawler's People

Contributors

wodimudi avatar mudiyouyou avatar

Watchers

James Cloos avatar  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.