0
私はGoogleカレンダーAPIにリクエストするためにPythonクライアントライブラリーを使用しています。それは正常に動作しますが、カレンダーのすべてのイベントを取得していません。しかし、私がAPIのエクスプローラを見ると、私はすべてを取得し、別の形式で取得します。たとえば、APIエクスプローラには、必要な「要約」キーが含まれています。何故ですか?GoogleカレンダーAPIがAPIエクスプローラーと異なる結果を返す
credentials = ServiceAccountCredentials.from_json_keyfile_name(SERVICE_ACCOUNT_JSON_FILE_PATH, scopes)
http_auth = credentials.authorize(Http())
calendar = build('calendar', 'v3', credentials=credentials)
currentTime = datetime.datetime.now()
maxTime = currentTime + relativedelta(months=+1)
#do this to get all events on this day
maxTime = maxTime.replace(minute=59, hour=23, second=59)
currentTime = currentTime.isoformat('T') + '-06:00'
maxTime = maxTime.isoformat('T') + '-06:00'
response = calendar.events().list(calendarId="*******", singleEvents=True, maxResults=2500, showHiddenInvitations=True, timeMin=currentTime, timeMax=maxTime).execute()
return JsonResponse(response)