Discover Packages
github.com/zhlicen/pdgzf
package
module
Version:
v0.0.0-...-82c0af8
Opens a new window with list of versions in this module.
Published: Nov 15, 2023
License: Apache-2.0
Opens a new window with license information.
Imports: 10
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
README
¶
pdgzf
https://select.pdgzf.com
浦东公租房 REST API 封装,可用于一些自动化脚本,或数据分析使用
数据结构定义不全,仅用于本人的个人脚本,欢迎提 pr 补全
验证码识别推荐使用ttshitu ,便宜好用(本人亲测非广告)
房源镜像
Expand ▾
Collapse ▴
Documentation
¶
生成登陆参数
logReqStrFmt 登录请求消息体,预留验证码字段占位 {"account":"xxx","password":"xxxx","captcha":"%s"}
cr 验证码识别方法
Login 登陆验证码不好破...这里直接复制登陆请求(一个漏洞)
loginReqStr是login的body {"account":"xxx","password":"xxxx","captcha":"xxx"}
JSESSIONID从cookie中找
type House struct {
ID int64 `json:"id"`
FullName string `json:"fullName"`
TypeName int `json:"typeName"`
Queue []Queue `json:"queue"`
QueueCount int `json:"queueCount"`
SelectStartTime string `json:"selectStartTime"`
}
House 房源信息
GetHouses 根据请求查询房源列表
reqStr https://select.pdgzf.com/houseLists 页面定制查询条件,复制POST参数JSON字符串
cookies 从Login中拿,也可以自己从header中取GZFAuthentication(有效期24h),存入http.Cookie结构中
如果无需排队数据,cookies参数填空即可
type Period struct {
Name string `json:"name"`
StartTime string `json:"startTime"`
}
type Queue struct {
Qualification QueueItem `json:"qualification"`
Status string `json:"status"`
Position int `json:"position"`
Period Period `json:"period"`
}
type QueueItem struct {
Code string `json:"code"`
Name string `json:"name"`
StartDate string `json:"startDate"`
}
QueueItem 排队信息
GetQueue 获取房源排队队列
houseID 房源ID
cookies 从Login中拿,也可以自己从header中取GZFAuthentication(有效期24h)
如果无需排队数据,cookies参数填空即可
Source Files
¶
Click to show internal directories.
Click to hide internal directories.