NAME
WebService::Google::Client::UserAgent - User Agent wrapper for working with Google APIs
VERSION
version 0.06
METHODS
build_http_transaction
Example of usage:
$gapi->build_http_transaction({
method => 'post',
path => 'https://www.googleapis.com/calendar/users/me/calendarList',
options => { key => value }
})
refresh_access_token
Get new access token for user from Google API server
$self->refresh_access_token({
client_id => '',
client_secret => '',
refresh_token => ''
})
Q: under what conditions could we not have a refresh token? - what scopes are required? ensure that included in defaults if they are req'd
api_query
Low-level method that can make any API query to a Google API service
Required params: method, route
$self->access_token must be valid
Examples of usage:
$gapi->api_query({
method => 'get',
path => 'https://www.googleapis.com/calendar/users/me/calendarList',
});
$gapi->api_query({
method => 'post',
path => 'https://www.googleapis.com/calendar/v3/calendars/'.$calendar_id.'/events',
options => { key => value }
}
Returns Mojo::Message::Response object
AUTHORS
Pavel Serikov <pavelsr@cpan.org>
Peter Scott <peter@localshop.com.au>
COPYRIGHT AND LICENSE
This software is copyright (c) 2017-2018 by Pavel Serikov, Peter Scott and others.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.