# Node-red-node-google - can't get multiple calendar events

**URL:** https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111
**Category:** General
**Created:** [9 April 2024 20:32 UTC](https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111 "2024-04-09T20:32:46Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)
#### Post date: [9 April 2024 20:32 UTC](https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111/1 "2024-04-09T20:32:46Z")

</div>

> **[node-red-node-google](https://flows.nodered.org/node/node-red-node-google)**
>
> A set of Node-RED nodes to access various Google services

I fear that I may have wasted a few hours tonight setting up the node-google node after reading posts on other forums about people requesting and receiving multiple calendar entries from a specified google calendar.

After getting it to all connected I failed to get more than the next calendar entry to return from each calendar that I specified.

I then noticed that when I hover over the google calendar node in node-red that is says "Return the next event in google calendar", which aligns with the documentation, but not the posts I found that showed a screenshot of an array of objects being returned - presumably each object representing an individual calendar event!

Am I barking up the wrong tree and actually need to use another node-red node or is there a parameter I am missing...

```auto

let now = new Date();
let startOfMonth = new Date(Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), 1, 0, 0, 0));
let endOfMonth = new Date(Date.UTC(now.getUTCFullYear(), now.getUTCMonth() + 1, 0, 23, 59, 59));

msg.topic = {
    maxResults: 250,
    calendarId: msg.calendar, 
    timeMin: startOfMonth.toISOString(),
    timeMax: endOfMonth.toISOString()
};

return msg;

```

Before anyone jumps up and down, if I sent a msg.payload I always get a response of ""Error: no event found". I can sent msg.[anything[ and I always get the next calendar entry, so long as anything != "payload"

@knolleary @dceejay I notice you are maintainers of this node. Can you help please?

EDIT:  
Interestingly I just tested the API via here: [Google Event list API](https://developers.google.com/calendar/api/v3/reference/events/list?apix_params=%7B%22calendarId%22%3A%22primary%22%7D) and I do get an array of objects in the response, so the API allows it. I suspect I am just doing something wrong with the request.

---

<div class="post-metadata">

### Author: ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)
#### Post date: [18 April 2024 10:12 UTC](https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111/2 "2024-04-18T10:12:04Z")

</div>

FYI, I ended up using another node which works very well.

---

<div class="post-metadata">

### Author: ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)
#### Post date: [18 April 2024 10:14 UTC](https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111/3 "2024-04-18T10:14:13Z")

</div>

Glad you are sorted.

for future reader, please tell us the node (a link from the [flows library](https://flows.nodered.org/) would be even better)

---

<div class="post-metadata">

### Author: ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)
#### Post date: [18 April 2024 17:46 UTC](https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111/4 "2024-04-18T17:46:03Z")

</div>

> **[node-red-contrib-ical-events](https://flows.nodered.org/node/node-red-contrib-ical-events)**
>
> NodeRed calender event adapter

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [17 July 2024 17:47 UTC](https://discourse.nodered.org/t/node-red-node-google-cant-get-multiple-calendar-events/87111/5 "2024-07-17T17:47:00Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
