(✧ω✧) 哇嗷!欢迎您即将成为 Project Podris 的一员!
这个页面将指导您获得 Project Podris 的访问权限并学习如何使用它~
English
Wow! Welcome to become a member of Project Podris!
This page will guide you to gain access to Project Podris and learn how to use it.
> 开始之前 [Before-we-begin]
Project Podris 的接口是设计给有能力有一定技术力的开发者使用,一直以来都是。
所以如果您对编程一窍不通,只是来享受 Project Podris 便利成果的用户,那麻烦您移步到首页的“我们的服务”部分!(*´∀`*)
English
Project Podris is designed for developers with a certain level of technical ability, and it always has been.
So if you are a user who doesn't know anything about programming and just wants to enjoy the convenience of Project Podris, please go to the "Our Services" section on the home page!
Project Podris 是一个公益项目,但我们会使用令牌认证机制以避免服务被滥用。目前 Project Podris 的令牌是要求与您的QQ账号相绑定的,因此,我们使用 Project Podris 官方QQ群内的机器人进行Token发放与管理,所以您需要先加入群聊(172185748)获取您的令牌!(同时该群也是 Project Podris 的唯一官方交流群,有什么问题也都可以到群里提的哦)
English
Project Podris is a public welfare project, but we use a token authentication mechanism to prevent the service from being abused. Currently, the token for Project Podris is required to be associated with your QQ account. Therefore, we use a robot in the official Project Podris QQ group to distribute tokens. So you need to join the group chat (172185748) first to obtain your token! (Also, this group is the only official communication group for Project Podris, and you can ask any questions there.)
> 注意事项 [Usage-Precautions]
哎?!看到这里了应该是成功获得了您自己的令牌了罢 o(〃^▽^〃)o 恭喜您已经成功一半咯!
接下来您需要特别记住以下注意事项:
English
Huh?! If you've read this far, you must have successfully obtained your own token, right? (゚∀゚) Congratulations, you're halfway there!
Next, you need to especially remember the following precautions:
Technically 技术上:
- Project Podris 使用基本 WebSocket 协议(即ws://)并不是安全 WebSocket 协议(即wss://)
- 您的令牌应放置在客户端的 Authorization 请求头中的
Bearer
片段,即:Authorization: Bearer <YOUR_TOKEN>
如果您使用的平台并不支持自定义请求头(如 JavaScript),您可以在让客户端在连接上 Project Podris 后在三秒内以纯文本的形式发送您的令牌,Project Podris 也会与客户端握手 - Project Podris 使用频道(Channel)机制来保证情报的可靠性,相关详情请查阅技术文档
- 连接成功建立后,客户端会第一时间收到来自服务器的握手包
- 一个令牌仅支持最多三个同时连接,同时连接数量已满的令牌再被用于请求连接时,会被服务器拒绝连接并返回错误码
1008: Token limit exceeded
- Project Podris 没有心跳包机制
- 客户端收到的来自 Project Podris 的任何消息(包括握手包)都使用了 Base64 编码的 Brotli 压缩,客户端需要将其解压
- 解压后的数据是JSON格式的字符串,客户端需要将其解析成其编程语言使用的类型
- Project Podris 的服务器屏蔽了来自非中国大陆的任何连接
- 不论是哪种原因,若您的程序会自动进行连接重试,都会给我们的服务器增加一定的负担,所以请让每次重试之间的间隔保持在1秒以上,但我们更推荐您明智地使用指数退避机制进行重试♪(´▽`)
English
- Project Podris uses the basic WebSocket protocol (ws://) instead of the secure WebSocket protocol (wss://).
- Your token should be placed in the
Authorization
request header of the client in theBearer
section, i.e.:Authorization: Bearer <YOUR_TOKEN>
If the platform you are using does not support custom request headers (such as JavaScript), you can have the client send your token in plain text within three seconds after connecting to Project Podris, and Project Podris will also shake hands with the client. - Project Podris uses the Channel mechanism to ensure the reliability of intelligence. For more details, please refer to the technical documentation.
- After a successful connection is established, the client will immediately receive a handshake packet from the server.
- A single token supports a maximum of three concurrent connections. If a token that has reached its connection limit is used to request a connection, the server will reject the connection and return error code
1008: Token limit exceeded
. - Project Podris does NOT have a heartbeat packet mechanism.
- ANY messages received by the client from Project Podris (including handshake packets) are encoded with Base64-compressed Brotli. The client needs to decompress them.
- The decompressed data is a JSON-formatted string, which the client needs to parse into the type used by its programming language.
- Project Podris's server blocks any connections from outside Mainland China.
- Regardless of the reason, if your program automatically retries the connection, it will add some burden to our server. Therefore, you MUST use the exponential backoff mechanism to retry the connection to the server. Otherwise, please keep the interval between each retry more than 10 seconds! (Our server is fragile and can't bear too many retries... Of course, if you don't consider yourself a good person 🙁 and think this retry time is too long, you can secretly reduce it by one or two seconds. 🙂 )
In terms of usage 使用上:
- 您可以负责地将 Project Podris 的服务应用在您的作品上,但您必须标明情报来源
- 请不要将 Project Podris 应用在要求高严谨性高准确性的作品上(如:论文)
- 自然现象瞬息万变,防灾情报也如此。Project Podris 作为公益项目,是无法保证发布的每一份情报都能准确无误的,所以当您对收到的情报信息有疑问,请您在我们的交流群内或邮箱反馈,做到不复制不转发不外传,避免不必要的麻烦
- 最后一个警示:如果您在未遵守以上注意事项时使用 Project Podris 中产生了任何的纠纷,Project Podris 没有义务也不会为您的所做所为负责。如果对该警示存在任何的异议,请立即停止使用我们的任何服务!
English
- You may responsibly apply the services of Project Podris to your work, but you MUST indicate the source of the information.
- Please do NOT apply Project Podris to works that require high rigor and accuracy (such as academic papers).
- Natural phenomena are constantly changing, and disaster prevention information is no different. As a public welfare project, Project Podris cannot guarantee that every piece of information released is accurate. Therefore, if you have any doubts about the information you receive, please provide feedback in our communication group or via email. Do NOT copy, forward, or disseminate the information to avoid unnecessary trouble.
- Finally, a warning: If you use Project Podris WITHOUT adhering to the above precautions and any disputes arise, Project Podris has NO obligation and will NOT be responsible for your actions. If you have any objections to this warning, please immediately cease using any of our services!
> 解析指南 [Learn-to-parse]
哇...能进行到这里可真不容易啊!(;・∀・)
接下来我们就开始了解 Project Podris 的情报格式了!
English
Wow... It's really not easy to get this far! (;・∀・)
Next, let's start to understand the intelligence format of Project Podris!
> 准备就绪 [I-am-all-set]
恭喜您已经成为了 Project Podris 合格的一员!您可以自由地应用 Project Podris 到您的作品上了。祝您好运!Congratulations on becoming a qualified member of Project Podris! You can freely apply Project Podris to your work. Good luck to you!