시작 시간과 종료 시간이 있는 모든 데이터 포인트가 포함된 데이터 세트를 반환합니다.
데이터 세트의 지정된 최소 시작 시간 범위와 겹칩니다.
최대 종료 시간입니다. 특히 시작 시간이 이보다 짧은 모든 데이터 포인트는
데이터 세트 종료 시간과 같거나 종료 시간이 다음보다 크거나 같음
데이터 세트 시작 시간과 같아야 합니다.
지금 사용해 보기
요청
HTTP 요청
GET https://www.googleapis.com/fitness/v1/users/userId/dataSources/dataSourceId/datasets/datasetId
매개변수
매개변수 이름
값
설명
경로 매개변수
dataSourceId
string
데이터 세트를 만든 데이터 소스의 데이터 스트림 ID입니다.
datasetId
string
최소 데이터 포인트 시작 시간의 복합인 데이터 세트 식별자
최대 데이터 포인트 종료 시간은 에포크로부터 나노초로 표현됩니다.
ID는 'startTime-endTime'와 같은 형식입니다.
여기서 startTime 및 endTime는 64비트 정수입니다.
userId
string
식별된 사람의 데이터 세트를 검색합니다. me 사용 용도
인증된 사용자를 나타냅니다 현재는 me만 지원됩니다.
있습니다.
선택적 쿼리 매개변수
limit
integer
지정하면 지정된 수의 데이터 포인트만
데이터 세트로 그룹화됩니다. 데이터 세트에 더 많은 데이터 포인트가 있는 경우 nextPageToken
데이터 세트 응답에 설정됩니다
제한은 시간 범위의 끝부터 적용됩니다. 즉,
pageToken가 없음, 최신 데이터 limit개
포인트가 반환됩니다.
pageToken
string
대규모 데이터 세트를 페이징하는 데 사용되는 연속 토큰입니다.
데이터 세트의 다음 페이지를 가져오려면 이 매개변수를
이전 응답의 nextPageToken입니다. 이후에
호출하면 다음과 같은 데이터 포인트 종료 타임스탬프가 있는 부분 데이터 세트를
이전 부분 응답보다 훨씬 작아야 합니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-07-25(UTC)"],[[["\u003cp\u003eRetrieves a dataset containing all data points within a specified time range, overlapping with the dataset's minimum start and maximum end times.\u003c/p\u003e\n"],["\u003cp\u003eRequires authorization with specific scopes related to fitness data access (e.g., \u003ccode\u003ehttps://www.googleapis.com/auth/fitness.activity.read\u003c/code\u003e).\u003c/p\u003e\n"],["\u003cp\u003eUses a GET request to the endpoint \u003ccode\u003ehttps://www.googleapis.com/fitness/v1/users/userId/dataSources/dataSourceId/datasets/datasetId\u003c/code\u003e with parameters for user, data source, and dataset identification.\u003c/p\u003e\n"],["\u003cp\u003eAllows optional parameters like \u003ccode\u003elimit\u003c/code\u003e and \u003ccode\u003epageToken\u003c/code\u003e to control the size and pagination of the returned dataset.\u003c/p\u003e\n"],["\u003cp\u003eReturns a \u003ccode\u003eUsers.dataSources.datasets\u003c/code\u003e resource upon successful execution, containing the requested fitness data.\u003c/p\u003e\n"]]],[],null,["# Users.dataSources.datasets: get\n\n| **Note:** Requires [authorization](#auth).\n\nReturns a dataset containing all data points whose start and end times\noverlap with the specified range of the dataset minimum start time and\nmaximum end time. Specifically, any data point whose start time is less\nthan or equal to the dataset end time and whose end time is greater than or\nequal to the dataset start time.\n[Try it now](#try-it).\n\nRequest\n-------\n\n### HTTP request\n\n```\nGET https://www.googleapis.com/fitness/v1/users/userId/dataSources/dataSourceId/datasets/datasetId\n```\n\n### Parameters\n\n| Parameter name | Value | Description |\n|----------------|-----------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| **Path parameters** |||\n| `dataSourceId` | `string` | The data stream ID of the data source that created the dataset. |\n| `datasetId` | `string` | Dataset identifier that is a composite of the minimum data point start time and maximum data point end time represented as nanoseconds from the epoch. The ID is formatted like: \"\u003cvar translate=\"no\"\u003estartTime\u003c/var\u003e-\u003cvar translate=\"no\"\u003eendTime\u003c/var\u003e\" where \u003cvar translate=\"no\"\u003estartTime\u003c/var\u003e and \u003cvar translate=\"no\"\u003eendTime\u003c/var\u003e are 64 bit integers. |\n| `userId` | `string` | Retrieve a dataset for the person identified. Use `me` to indicate the authenticated user. Only `me` is supported at this time. |\n| **Optional query parameters** |||\n| `limit` | `integer` | If specified, no more than this many data points will be included in the dataset. If there are more data points in the dataset, nextPageToken will be set in the dataset response. The limit is applied from the end of the time range. That is, if \u003cvar translate=\"no\"\u003epageToken\u003c/var\u003e is absent, the \u003cvar translate=\"no\"\u003elimit\u003c/var\u003e most recent data points will be returned. |\n| `pageToken` | `string` | The continuation token, which is used to page through large datasets. To get the next page of a dataset, set this parameter to the value of `nextPageToken` from the previous response. Each subsequent call will yield a partial dataset with data point end timestamps that are strictly smaller than those in the previous partial response. |\n\n### Authorization\n\nThis request requires authorization with at least one of the following scopes:\n\n| Scope |\n|---------------------------------------------------------------------|\n| `https://www.googleapis.com/auth/fitness.activity.read` |\n| `https://www.googleapis.com/auth/fitness.activity.write` |\n| `https://www.googleapis.com/auth/fitness.location.read` |\n| `https://www.googleapis.com/auth/fitness.location.write` |\n| `https://www.googleapis.com/auth/fitness.body.read` |\n| `https://www.googleapis.com/auth/fitness.body.write` |\n| `https://www.googleapis.com/auth/fitness.nutrition.read` |\n| `https://www.googleapis.com/auth/fitness.nutrition.write` |\n| `https://www.googleapis.com/auth/fitness.blood_pressure.read` |\n| `https://www.googleapis.com/auth/fitness.blood_pressure.write` |\n| `https://www.googleapis.com/auth/fitness.blood_glucose.read` |\n| `https://www.googleapis.com/auth/fitness.blood_glucose.write` |\n| `https://www.googleapis.com/auth/fitness.oxygen_saturation.read` |\n| `https://www.googleapis.com/auth/fitness.oxygen_saturation.write` |\n| `https://www.googleapis.com/auth/fitness.body_temperature.read` |\n| `https://www.googleapis.com/auth/fitness.body_temperature.write` |\n| `https://www.googleapis.com/auth/fitness.reproductive_health.read` |\n| `https://www.googleapis.com/auth/fitness.reproductive_health.write` |\n\nFor more information, see the [authentication and authorization](/fit/rest/v1/authorization) page.\n\n### Request body\n\nDo not supply a request body with this method.\n\nResponse\n--------\n\nIf successful, this method returns a [Users.dataSources.datasets resource](/fit/rest/v1/reference/users/dataSources/datasets#resource) in the response body.\n\nTry it!\n-------\n\n\nUse the APIs Explorer below to call this method on live data and see the response."]]