1

您好只是想知道我如何从以下获取真实数据。我将其放入 Oauth 2.0 playgournd:

https://www.googleapis.com/fitness/v1/users/me/dataSources/derive_step_cadence <-raw:com.google.step_count.cumulative:LGE:Nexus 5:bc5f1b97:Step Counter/datasets/8587796212108459505-8587784116108409439

我回来了:

HTTP/1.1 200 OK 内容长度:202 X-xss-protection:1;mode=block 内容位置:https ://www.googleapis.com/fitness/v1/users/me/dataSources/derive_step_cadence<-raw:com.google.step_count.cumulative:LGE:Nexus 5:bc5f1b97:Step Counter/datasets/8587796212108459505-8587784116108409439 X-content-type-options: nosniff 过期时间:1990 年 1 月 1 日星期五 00:00:00 GMT 变化: Origin,X-Origin 服务器: GSE Etag: "hLUJCvL5ZSSqXM3VrwyiV-fn_Cc/UTWu-5kuRnTemL1Tzb1qSZ4O9uk" Pragma: no-cache 缓存控制: no-cache, no-store, max-age=0, must-revalidate Date: Fri, 2015 年 2 月 6 日 04:22:06 GMT X-frame-options: SAMEORIGIN Content-type: application/json; charset=UTF-8 { "minStartTimeNs": "8587784116108409439", "maxEndTimeNs": "8587796212108459505", "dataSourceId": "derive_step_cadence<-raw:com.google.step_count.cumulative:LGE:Nexus 5:bc5f1b97:Step Counter }

没有任何有用的数据。

难道我做错了什么?

谢谢拉斯

4

1 回答 1

1

确保您在端点末尾提供的时间戳采用纳米时间格式。

https://www.googleapis.com/fitness/v1/users/me/dataSources/derive_step_cadence<-raw:com.google.step_count.cumulative:LGE:Nexus 5:bc5f1b97:Step Counter/datasets/000000-1720845034000000000

这个解决方案就像一个魅力

于 2015-11-18T15:17:05.420 回答