以请求的状态码响应
写 api 会用到 HTTP 状态码,自己对这个还不甚了解,也没有找到有各种响应的服务器可以测,虽然知道 http.cat ,但上面都是猫图,自己玩 Cloudflare 的 worker 又玩的起劲,这么好用的平台,撸个轮子分分钟。
http.example.com / 200
/*
@200: 请求码
*/
Cloudflare Workers documentation - https://developers.cloudflare.com/workers/
HTTP 响应代码 - https://developer.mozilla.org/zh-CN/docs/Web/HTTP/Status
Hypertext Transfer Protocol (HTTP) Status Code Registry - https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
MIT
https://github.com/initdc/HTTP-status-codes
http.moz.one
Cloudflare CDN 只支持 100-599 的状态码, 其他的会抛出错误。本地运行的 miniflare 可在服务器 console 中看到相应的请求。
欢迎大家 issue,commit,start,fork,有新点子快来分享吧!
这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。
V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。
V2EX is a community of developers, designers and creative people.