{"id":14957531,"url":"https://github.com/ecitlm/node-spliderapi","last_synced_at":"2025-04-12T17:45:00.904Z","repository":{"id":37502950,"uuid":"92590852","full_name":"ecitlm/Node-SpliderApi","owner":"ecitlm","description":"基于node+express爬虫 API接口项目,包括全国高校信息、成语诗歌、星座运势、历史的今天、音乐数据接口、图片壁纸、搞笑视频、热点新闻资讯 详情接口数据","archived":false,"fork":false,"pushed_at":"2023-07-19T12:00:32.000Z","size":5939,"stargazers_count":863,"open_issues_count":16,"forks_count":218,"subscribers_count":22,"default_branch":"master","last_synced_at":"2025-04-03T19:16:43.509Z","etag":null,"topics":["express","expressjs","mysql","nodejs"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ecitlm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-05-27T10:11:20.000Z","updated_at":"2025-03-28T03:20:20.000Z","dependencies_parsed_at":"2024-01-17T00:18:39.645Z","dependency_job_id":"93414657-76c2-459e-bd52-527e39867765","html_url":"https://github.com/ecitlm/Node-SpliderApi","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecitlm%2FNode-SpliderApi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecitlm%2FNode-SpliderApi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecitlm%2FNode-SpliderApi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecitlm%2FNode-SpliderApi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ecitlm","download_url":"https://codeload.github.com/ecitlm/Node-SpliderApi/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248609501,"owners_count":21132915,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["express","expressjs","mysql","nodejs"],"created_at":"2024-09-24T13:15:05.524Z","updated_at":"2025-04-12T17:45:00.887Z","avatar_url":"https://github.com/ecitlm.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Express\n\u003e项目基于`express`+`sequelize`+`mysql`+`express-validator`\n\u003e 基于node+express爬虫 API接口项目,包括全国高校信息、成语诗歌、星座运势、历史的今天、音乐数据接口、图片壁纸、搞笑视频、热点新闻资讯 详情接口数据\n\n- [x] express\n- [x] sequelize\n- [x] mysql\n- [x] `express-validator`参数表单校验\n- [x] 使用`cheerio`解析爬虫页面\n- [x] 集成`ejs`模板\n- [x] 集成`swaggerUI`接口文档\n- [x] `nodemon`项目开发动态热更新\n- [x] `dotenv`管理配置系统参数\n- [x] 包含接口sign请求验证\n- [x] `log4js` 错误日志收集\n\n### 环境要求\n\u003e需要安装`node`环境,`mysql`数据库\n\n### 部署运行\n```shell\n$ git clone https://github.com/ecitlm/Node-SpliderApi.git\n$ npm install\n#  start project dev\n$ npm run dev\n# starting prd\n$ npm run prd\n#localhost:3001\n\n```\n### 服务器部署\n\n\u003e 在服务器中使用 `pm2` 对 `node` 服务进行进程守护\n\n```shell\n#启动进程/应用\npm2 start npm --watch --name tools -- run prd\npm2 restart tools\npm2 stop tools\npm2 delete tools\n```\n### 数据库\n\u003e`mysql`中包含、唐诗300、成语、历史的今天、星座运势(聚合平台数据-需要申请自己的APPCODE)、用户表等数据\n\u003e 项目目录`bak-file`文件夹可查看\n\n### 接口文档\n\u003e启动项目之后`http://localhost:3001/api-docs/` 可查看接口文档页面\n![api.png](bak-file/api.png)\n![api2.png](bak-file/api2.png)\n\n\n### 错误码说明\n\n| 状态码  | 含义                               | 备注 |\n|------| ---------------------------------- | ---- |\n| 200  | 响应正常                           |      |\n| 1001 | 参数无效、如一个不存在的id         |      |\n| 1002 | 参数为空、验证不通过、参数类型错误 |      |\n| 1003 | 请求签名异常、非法 |\n| 404  |请求不存在 |\n| 405  | 请求方式错误|\n| 9999 | 第三方接口请求异常|\n| 500  |系统异常|\n\n\n\n### 感谢JetBrains 的支持\nJetBrains:https://www.jetbrains.com/?from=Node-SpliderApi\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fecitlm%2Fnode-spliderapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fecitlm%2Fnode-spliderapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fecitlm%2Fnode-spliderapi/lists"}