由于对阿里云 OpenAPI 数量众多,为方便查阅制作了一个 Alfred 工作流,效果如下
1. 输入 api 唤起工作流
2. 输入 API 名称关键字
3. 选择 API,回车打开文档
效果图:
Alfred Workflow 配置
query=$1filter='{ items: .data.list | map({ arg: (.product + "/" + .version + "/" + .api) , title: ( " [" + .product + "] " + .api + " - " + .title), subtitle: .summary, icon: { path: ( "./product/" + .product + ".png") }, mods: { alt: { subtitle: .search_summary } } })}'curl"https://next.api.aliyun.com/api/search/api?query=$query&query_type=direct&biz=workbench_home&page=1&perPage=10&guess_tab=1" \ -H'authority: next.api.aliyun.com' \ -H'accept: application/json' \ -H'content-type: application/json' \ -H'referer: https://next.api.aliyun.com/home' \ -s | /usr/local/bin/jq "$filter"