The /events endpoint enables retrieval of a user's event records. This includes carbohydrate intake, insulin doses, exercise, and health events that are entered in the receiver interface or through the mobile app.
GET /v2/users/self/events
OAuth 2.0 bearer token; see the Authentication section for details on this workflow.
The G6 app enabled the ability to delete events after they have been created. To accomodate this, the eventId and eventStatus fields were introduced. When an event is initially created by the user, the eventStatus is set to "created". If the user deletes the event, the eventStatus will be changed to "deleted". The eventId will remain the same.
For events generated by receiving devices that do not have the ability to delete events (such as the G4 and G5 apps), the eventStatus field will always return "created".
startDate required | string <date-time> Beginning of the time window; see the discussion of time in the Endpoint Overview section for more details on how they relate to device information Example: startDate=2023-01-01T09:12:35 |
endDate required | string <date-time> End of the time window Example: endDate=2023-01-01T09:12:35 |
Ok
curl -i -X GET \ 'https://api.dexcom.com/v2/users/self/events?startDate=2023-01-01T09%3A12%3A35&endDate=2023-01-01T09%3A12%3A35' \ -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{- "events": [
- {
- "systemTime": "2019-08-24T14:15:22Z",
- "displayTime": "2019-08-24T14:15:22Z",
- "eventType": "insulin",
- "eventSubType": "longActing",
- "value": 17,
- "unit": "units",
- "eventId": "4b790d7c-542e-4673-b1c4-92e4d8d4550a",
- "eventStatus": "created"
}
]
}