Withings
非官方测试版翻译
本页面由 PageTurner AI 翻译(测试版)。未经项目官方认可。 发现错误? 报告问题 →
功能
Withings 健康生态系统通过互联设备和应用,旨在提升日常健康状态与长期健康状况。
获取 Withings 数据
授权 Oh My Posh 访问 Withings 数据需开通公开活动读取权限。操作后将获得访问令牌与刷新令牌,请将令牌粘贴至 Withings 段配置中。
点击下方链接连接 Withings:
示例配置
- json
- yaml
- toml
{
"type": "withings",
"style": "powerline",
"powerline_symbol": "",
"foreground": "#ffffff",
"background": "#000000",
"template": "{{ if gt .Weight 0.0 }} {{ round .Weight 2 }}kg {{ end }}",
"options": {
"access_token": "11111111111111111",
"refresh_token": "1111111111111111",
"http_timeout": 1500
}
}
type: withings
style: powerline
powerline_symbol:
foreground: "#ffffff"
background: "#000000"
template: "{{ if gt .Weight 0.0 }} {{ round .Weight 2 }}kg {{ end }}"
options:
access_token: "11111111111111111"
refresh_token: "1111111111111111"
http_timeout: 1500
type = "withings"
style = "powerline"
powerline_symbol = ""
foreground = "#ffffff"
background = "#000000"
template = "{{ if gt .Weight 0.0 }} {{ round .Weight 2 }}kg {{ end }}"
[options]
access_token = "11111111111111111"
refresh_token = "1111111111111111"
http_timeout = 1500
选项
| Name | Type | Default | Description |
|---|---|---|---|
access_token | template | token from Withings login, see login link in section above. | |
refresh_token | template | token from Withings login, see login link in section above. | |
expires_in | int | 0 | the default timeout of the token from the Withings login |
http_timeout | int | 20 | how long do you want to wait before you want to see your prompt more than your Withings data? |
模板 (信息)
默认模板
{{ if gt .Weight 0.0 }} {{ round .Weight 2 }}kg {{ end }}
属性
| Name | Type | Description |
|---|---|---|
.Weight | float | your last measured weight |
.SleepHours | string | your last measured sleep SleepHours |
.Steps | int | your last measured steps |
现在就去活动起来吧!