Sometimes I cannot get hangoutLink for events created in Java

Asked 1 months ago, Updated 1 months ago, 3 views

The Java app uses Calendar API v3 (v3-rev260-1.23.0) to insert the event.
During insert, the calendar user is guest-registered with the attendees parameter.

However, sometimes hangoutLink cannot be retrieved from the response event.
There was a 0.002% chance that it could not be retrieved.

However, even when hangoutLink cannot be retrieved, if you look at events in Google Calendar, hangoutLink is configured.
Is there a time lag from event creation to actual hangoutLink generation?

Please let me know when hangoutLink cannot be retrieved from the response event.
Also, if there is a way to get hangoutLink from the response, please let me know.

Also, since September 1, 2020, we have not been able to obtain it 100% of the time, and the Meet URL has not been added.
I wonder if the Google Meet settings have been changed.

Sample Code

com.google.api.services.calendar.calendar service=newcom.google.api.services.calendar.Builder(
        httpTransport, JacksonFactory.getDefaultInstance(), credential).setApplicationName(APPLICATION_NAME).build();
Event event = new Event();
event.setSummary("Title");
event.setDescription("Details";
DateTime start = new DateTime (start time, TimeZone.getTimeZone("UTC"));
event.setStart(newEventDateTime().setDateTime(start));
DateTime end = new DateTime (End Time, TimeZone.getTimeZone("UTC"));
event.setEnd(newEventDateTime().setDateTime(end));
event.setGuestsCanModify(true);

java.util.List<EventAttendee>eAttendees=Lists.newArrayList();
EventAttendee eAttendee=new EventAttendee();
eAttendee.setEmail("[email protected]");
eAttendees.add(eAttendee);
event.setAttendees(eAttendees);

Event result=service.events().insert(calendarId, event).execute();
String meetURL=result.getHangoutLink(); // ★← meetURL may be null

java playframework google-calendar-api

2022-09-30 11:02

1 Answers

Regarding hangoutLink which was no longer available from September 1, 2020, I solved myself by following the following actions.
Update Calendar API v3 version from v3-rev260-1.23.0 to v3-rev411-1.25.0 and
After adding the action to set the CreateConferenceRequest to the insert event, hangoutLink can now be retrieved.


2022-09-30 11:02

If you have any answers or tips


© 2022 OneMinuteCode. All rights reserved.