Adding a Google Calendar using apiClient
- by EricCarmichael
I'm finally able to get an Access Token, now I'm very confused as how to add a Calendar using only Google's provided apiClient.
$apiClient = SiteController::getApiClient();
$service = new apiCalendarService($apiClient);
$calendar = new Calendar();
$calendar->description = "What";
$service->calendars->insert($calendar);
This produces:
Error calling POST https://www.googleapis.com/calendar/v3/calendars?key=mykey: (400) Required
Is there some documentation/examples on adding a Calendar? There are a ton of examples, it seems like, for simply adding an Event.