问题标签 [google-fit]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
asp.net - 来自远程客户端的 Google Fit Api 403 错误
我有一个托管在 IIS 7 上的 Web 应用程序,它使用 Google Fit API 进行 Http 调用,我能够成功发送 POST 并检索访问令牌,之后我对以下 uri 执行 GET:
以下是我构建请求并查看响应的方式:
当我在主机服务器上的浏览器上运行此应用程序时,我成功获得了一个 json 对象(它不是我期望的 json,但这是另一个问题)。但是,当我尝试在远程客户端上访问该站点时,我收到一个 403 错误,指出我尝试检索响应时。有任何想法吗?
android - 如何使用 Tasker 读取 Google Fit 数据?
如何使用 Tasker 将 Google Fit 中的数据读取到变量中?
更具体地说,我想阅读例如我今天的当前步数,这是由我的手机 + 健身追踪器计算并提供给 Google Fit 的。我的目标是有一个包含这个数字的变量,然后使用它。我已阅读有关 Google Fit History API 的信息,但我不知道如何通过 Tasker 访问它。
android - Google Play Service v 6.5 到 v 7.0.0 的差异
有没有人浏览过 Google-Play-Services API 文档并找出 v6.5 和 7.0.0 之间的语法变化?
寻找一张婴儿床单来省去我自己编译的麻烦。
v <7 语法:
变为 v >= 7.0.0:
我还想知道GoogleApiClient.Builder(this) ... if (!authInProgress)示例块是否也应该在“入门”页面上捕获ConnectionResult.SIGN_IN_REQUIRED结果?
我问自从迁移到最新版本以来,我偶尔会注意到:
错误,所以想知道而不是建议:
我们/网站应该使用:
android - 通过 Google Fit Api 检索到的步数与 Google Fit 官方应用中显示的步数不匹配
我开发了一个需要显示每日步数的应用程序。为此,我使用了 Google Fit SDK 中提供的 API。
一切似乎都正常工作,但我得到的步数与 Google Fit 官方应用程序中显示的步数不匹配。
例如,当 Google Fit App 显示 2367 步时,我得到 2308 步。
是否有一个原因?有没有人有同样的问题?有人有线索吗?
google-fit - 通过 Google Fit REST API 访问体重数据
在过去的 6 个月里,我一直在 Google Fit 中输入我的体重,现在我想把我的数据拿出来。
访问 Google Fit REST API 不是问题。然而,在所有可访问的数据中找到我的体重数据让我很难过。
任何指针不胜感激。
android - Google Fit API 空卡路里数据集
我正在开发一个使用Google Fit API
.
到目前为止,我已经成功地获取了步骤增量
但目前我坚持这个:
似乎它部分工作,因为我得到DataSets
type com.google.calories.expended
,但他们没有任何DataPoints
. 这是我得到的:
我在过去 7 天的数据上对此进行了测试,看起来随时都是这样。我找不到任何关于卡路里如何的信息,或者它们是否通过 API 测量,但就 API 收集步数、你的体重和身高(我前段时间填写)而言,没有理由不测量所以它可以食用了。
所以有两个问题:我可以获得AGGREGATE_CALORIES_EXPENDED
非空值,如果是,那么如何?
android - 为 GoogleFit 创建自定义数据类型
我一直在尝试为 google fit 应用程序创建自定义数据类型,但遇到了一些错误。最初 ConfigApi.createCustomDataType 收到以下错误
“不能从静态上下文引用非静态方法‘createCustomDataType (com.google.android.gms.common.api.GoolgeApiClient, com.google.android.gms.fitness.request.DataTypeCreateRequest)”
因此,我实例化了 ConfigApi 以绕过该错误,然后在运行应用程序时出现以下错误:
java.lang.NullPointerException:尝试在空对象引用上调用接口方法“void com.google.android.gms.common.api.PendingResult.setResultCallback(com.google.android.gms.common.api.ResultCallback)”
该错误出现在这一行:pendingResult.setResultCallback
我希望有人能帮助我解决我做错的事情,然后再开始制造比我已经拥有的更大的混乱。以下是我正在使用的代码:
android - How to find which account (email) has user used to log into my google-fit based android app?
I am trying to make an android app based on google-fit.
What I am trying to achieve is that I create an account for the user on my website as soon as the user chooses an account using the app.
Here is the code base that I want to build up upon (It is just the basic registration sample code) https://github.com/ishanatmuz/GoogleFitTest/tree/829051b7739ee9d8871c3ba9e5f21dfb17f4f3d7
onConnected is called when the user has succesfully signed in and provided the permissions. I am calling my own function to do further work which is basically this :
- Get the information (at least email) of the user who just signed in.
- Send the user to my server for registration.
- Continue with the rest of the app.
I need help figuring out how to do the step 1.
Any help will be greatly appreciated.
android - 在 Google Fit 中为自定义数据类型设置数据点
尝试为将使用 Google Fit 的应用程序的自定义数据类型设置数据点时出现以下错误。
错误:DataPoint 中的 getValue (com.google.android.gms.fitness.data.Field) 无法应用于 (int)
我知道我错过了一些东西,但我不确定是什么。
google-api-php-client - 如何在 php 中使用 Google Fit api 获取步数?
我遇到了Google Api Php Client和Google Fit的问题。
我想得到我一天中完成的步骤的总和。
我找到了一个回应,但它不起作用(看看要点)。
我的PHP代码:
这里的问题是它没有进入第一个 while 循环:总是$listDataSources->valid()
返回false
。
我的问题:为什么它返回 false ?我怎样才能得到步骤?
我尝试使用 Oauth Playground ( https://www.googleapis.com/fitness/v1/users/me/dataSources/derived:com.google.step_count.delta:com.google.android.gms:estimated_steps
) 检索数据,但没有得到任何数据。
我懂了 :