blob: 91a27b4fbeadbafc2fb833481f1f70fc35b0e816 [file] [log] [blame] [view]
Martin Kustermann3aa33492014-11-17 15:03:40 +01001Auto-generated Dart libraries for accessing [Google APIs][libs].
Martin Kustermannf9c50a22014-09-10 15:26:11 +02002
3## Usage
4
Martin Kustermann3aa33492014-11-17 15:03:40 +01005First, obtain OAuth 2.0 access credentials. This can be done using the
6`googleapis_auth` package. Your application can access APIs on behalf of a
Martin Kustermannf9c50a22014-09-10 15:26:11 +02007user or using a service account.
8
9After obtaining credentials, an API from the `googleapis` package can be
10accessed with an authenticated HTTP client.
11
Martin Kustermann3aa33492014-11-17 15:03:40 +010012## Example
13
14The following command line application lists files in Google Drive by using a
15service account.
Martin Kustermannf9c50a22014-09-10 15:26:11 +020016
17Create a `pubspec.yaml` file with the `googleapis_auth` and `googleapis`
18dependencies.
19
Martin Kustermann3aa33492014-11-17 15:03:40 +010020```yaml
21...
22dependencies:
23 googleapis: any
24 googleapis_auth: any
25```
Martin Kustermannf9c50a22014-09-10 15:26:11 +020026
27Create a service account in the Google Cloud Console and save the credential
Martin Kustermann3aa33492014-11-17 15:03:40 +010028information.
Martin Kustermannf9c50a22014-09-10 15:26:11 +020029
Martin Kustermann3aa33492014-11-17 15:03:40 +010030Then create a Dart application to list files in a spececific project. *In the
31example below, files from the `dart-on-cloud` project are listed.*
Martin Kustermannf9c50a22014-09-10 15:26:11 +020032
Martin Kustermann3aa33492014-11-17 15:03:40 +010033```dart
34// bin/list_files.dart
Martin Kustermannf9c50a22014-09-10 15:26:11 +020035
Martin Kustermann3aa33492014-11-17 15:03:40 +010036import 'package:googleapis/storage/v1.dart';
37import 'package:googleapis_auth/auth_io.dart';
38
39final _credentials = new ServiceAccountCredentials.fromJson(r'''
40{
41 "private_key_id": ...,
42 "private_key": ...,
43 "client_email": ...,
44 "client_id": ...,
45 "type": "service_account"
46}
47''');
48
49const _SCOPES = const [StorageApi.DevstorageReadOnlyScope];
50
51void main() {
52 clientViaServiceAccount(_credentials, _SCOPES).then((http_client) {
53 var storage = new StorageApi(http_client);
54 storage.buckets.list('dart-on-cloud').then((buckets) {
55 print("Received ${buckets.items.length} bucket names:");
56 for (var file in buckets.items) {
57 print(file.name);
58 }
59 });
60 });
61}
62```
63
64[libs]: https://developers.google.com/discovery/libraries/
Martin Kustermannf9c50a22014-09-10 15:26:11 +020065
66## Available Google APIs
67
68The following is a list of APIs that are currently available inside this
69package.
70
71#### ![Logo](https://www.google.com/images/icons/product/doubleclick-16.gif) Ad Exchange Buyer API - adexchangebuyer v1.3
72
73Accesses your bidding-account information, submits creatives for validation, finds available direct deals, and retrieves performance reports.
74
75Official API documentation: https://developers.google.com/ad-exchange/buyer-rest
76
77#### ![Logo](https://www.google.com/images/icons/product/doubleclick-16.gif) Ad Exchange Seller API - adexchangeseller v1.1
78
79Gives Ad Exchange seller users access to their inventory and the ability to generate reports
80
81Official API documentation: https://developers.google.com/ad-exchange/seller-rest/
82
Søren Gjessea7d1bd02014-09-29 17:56:55 +020083#### ![Logo](https://www.google.com/images/icons/product/doubleclick-16.gif) Ad Exchange Seller API - adexchangeseller v2.0
84
85Gives Ad Exchange seller users access to their inventory and the ability to generate reports
86
87Official API documentation: https://developers.google.com/ad-exchange/seller-rest/
88
Martin Kustermannf9c50a22014-09-10 15:26:11 +020089#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Admin Directory API - admin directory_v1
90
91The Admin SDK Directory API lets you view and manage enterprise resources such as users and groups, administrative notifications, security features, and more.
92
93Official API documentation: https://developers.google.com/admin-sdk/directory/
94
Martin Kustermann0abb8102014-09-23 16:10:54 +020095#### ![Logo](https://www.google.com/images/icons/product/googlemail-16.png) Email Migration API v2 - admin email_migration_v2
Martin Kustermannf9c50a22014-09-10 15:26:11 +020096
97Email Migration API lets you migrate emails of users to Google backends.
98
99Official API documentation: https://developers.google.com/admin-sdk/email-migration/v2/
100
101#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Admin Reports API - admin reports_v1
102
103Allows the administrators of Google Apps customers to fetch reports about the usage, collaboration, security and risk for their users.
104
105Official API documentation: https://developers.google.com/admin-sdk/reports/
106
107#### ![Logo](https://www.google.com/images/icons/product/adsense-16.png) AdSense Management API - adsense v1.4
108
109Gives AdSense publishers access to their inventory and the ability to generate reports
110
111Official API documentation: https://developers.google.com/adsense/management/
112
113#### ![Logo](https://www.google.com/images/icons/product/adsense-16.png) AdSense Host API - adsensehost v4.1
114
115Gives AdSense Hosts access to report generation, ad code generation, and publisher management capabilities.
116
117Official API documentation: https://developers.google.com/adsense/host/
118
Martin Kustermann3242d2e2014-10-20 19:17:43 +0200119#### ![Logo](https://www.google.com/images/icons/product/analytics-16.png) Google Analytics API - analytics v3
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200120
121View and manage your Google Analytics data
122
123Official API documentation: https://developers.google.com/analytics/
124
125#### ![Logo](https://www.google.com/images/icons/product/android-16.png) Google Play Android Developer API - androidpublisher v2
126
127Lets Android application developers access their Google Play accounts.
128
129Official API documentation: https://developers.google.com/android-publisher
130
131#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Apps Activity API - appsactivity v1
132
133Provides a historical view of activity.
134
135Official API documentation: https://developers.google.com/google-apps/activity/
136
137#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google App State API - appstate v1
138
139The Google App State API.
140
141Official API documentation: https://developers.google.com/games/services/web/api/states
142
143#### ![Logo](https://www.google.com/images/icons/product/search-16.gif) BigQuery API - bigquery v2
144
145A data platform for customers to create, manage, share and query data.
146
147Official API documentation: https://developers.google.com/bigquery/docs/overview
148
149#### ![Logo](https://www.google.com/images/icons/product/blogger-16.png) Blogger API - blogger v3
150
151API for access to the data within Blogger.
152
153Official API documentation: https://developers.google.com/blogger/docs/3.0/getting_started
154
Søren Gjesse42f96152014-12-01 15:16:51 +0100155#### ![Logo](https://www.google.com/images/icons/product/ebooks-16.png) Books API - books v1
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200156
157Lets you search for books and manage your Google Books library.
158
159Official API documentation: https://developers.google.com/books/docs/v1/getting_started
160
161#### ![Logo](http://www.google.com/images/icons/product/calendar-16.png) Calendar API - calendar v3
162
163Lets you manipulate events and other calendar data.
164
165Official API documentation: https://developers.google.com/google-apps/calendar/firstapp
166
167#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Civic Information API - civicinfo us_v1
168
169An API for accessing civic information.
170
171Official API documentation: https://developers.google.com/civic-information
172
173#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Civic Information API - civicinfo v1
174
175An API for accessing civic information.
176
177Official API documentation: https://developers.google.com/civic-information
178
Søren Gjessea7d1bd02014-09-29 17:56:55 +0200179#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Civic Information API - civicinfo v2
180
181An API for accessing civic information.
182
183Official API documentation: https://developers.google.com/civic-information
184
Søren Gjesse2fcef162014-10-09 09:12:20 +0200185#### ![Logo](https://www.google.com/images/icons/product/compute_engine-16.png) Compute Engine API - compute v1
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200186
187API for the Google Compute Engine service.
188
189Official API documentation: https://developers.google.com/compute/docs/reference/latest/
190
191#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Content API for Shopping - content v2
192
193Manage product items, inventory, and Merchant Center accounts for Google Shopping.
194
195Official API documentation: https://developers.google.com/shopping-content/v2/
196
197#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Maps Coordinate API - coordinate v1
198
199Lets you view and manage jobs in a Coordinate team.
200
201Official API documentation: https://developers.google.com/coordinate/
202
203#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) CustomSearch API - customsearch v1
204
205Lets you search over a website or collection of websites
206
207Official API documentation: https://developers.google.com/custom-search/v1/using_rest
208
209#### ![Logo](https://www.google.com/images/icons/product/doubleclick-16.gif) DFA Reporting API - dfareporting v1.3
210
211Lets you create, run and download reports.
212
213Official API documentation: https://developers.google.com/doubleclick-advertisers/reporting/
214
Martin Kustermannc72d8692014-09-12 11:44:55 +0200215#### ![Logo](http://www.google.com/images/icons/feature/filing_cabinet_search-g16.png) APIs Discovery Service - discovery v1
216
217Lets you discover information about other Google APIs, such as what APIs are available, the resource and method details for each API.
218
219Official API documentation: https://developers.google.com/discovery/
220
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200221#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) DoubleClick Bid Manager API - doubleclickbidmanager v1
222
223API for viewing and managing your reports in DoubleClick Bid Manager.
224
225Official API documentation: https://developers.google.com/bid-manager/
226
227#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) DoubleClick Search API - doubleclicksearch v2
228
229Report and modify your advertising data in DoubleClick Search (for example, campaigns, ad groups, keywords, and conversions).
230
231Official API documentation: https://developers.google.com/doubleclick-search/
232
233#### ![Logo](https://ssl.gstatic.com/docs/doclist/images/drive_icon_16.png) Drive API - drive v2
234
235The API to interact with Drive.
236
237Official API documentation: https://developers.google.com/drive/
238
Søren Gjesseee081772014-11-05 12:32:29 +0100239#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Fitness - fitness v1
240
241Google Fit API
242
Martin Kustermann3aa33492014-11-17 15:03:40 +0100243Official API documentation: https://developers.google.com/fit/rest/
244
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200245#### ![Logo](http://www.google.com/images/icons/product/freebase-16.png) Freebase Search - freebase v1
246
247Find Freebase entities using textual queries and other constraints.
248
249Official API documentation: https://developers.google.com/freebase/
250
251#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Fusion Tables API - fusiontables v1
252
253API for working with Fusion Tables data.
254
255Official API documentation: https://developers.google.com/fusiontables
256
Søren Gjesse42f96152014-12-01 15:16:51 +0100257#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Fusion Tables API - fusiontables v2
258
259API for working with Fusion Tables data.
260
261Official API documentation: https://developers.google.com/fusiontables
262
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200263#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Play Game Services API - games v1
264
265The API for Google Play Game Services.
266
267Official API documentation: https://developers.google.com/games/services/
268
269#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Play Game Services Management API - gamesManagement v1management
270
271The Management API for Google Play Game Services.
272
273Official API documentation: https://developers.google.com/games/services
274
275#### ![Logo](https://www.google.com/images/icons/product/googlemail-16.png) Gmail API - gmail v1
276
277The Gmail REST API.
278
279Official API documentation: https://developers.google.com/gmail/api/
280
281#### ![Logo](http://www.google.com/images/icons/product/discussions-16.gif) Groups Migration API - groupsmigration v1
282
283Groups Migration Api.
284
285Official API documentation: https://developers.google.com/google-apps/groups-migration/
286
287#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Groups Settings API - groupssettings v1
288
289Lets you manage permission levels and related settings of a group.
290
291Official API documentation: https://developers.google.com/google-apps/groups-settings/get_started
292
293#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Identity Toolkit API - identitytoolkit v3
294
295Help the third party sites to implement federated login.
296
297Official API documentation: https://developers.google.com/identity-toolkit/v3/
298
299#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Enterprise License Manager API - licensing v1
300
301Licensing API to view and manage license for your domain.
302
303Official API documentation: https://developers.google.com/google-apps/licensing/
304
305#### ![Logo](https://www.google.com/images/icons/product/maps_engine-16.png) Google Maps Engine API - mapsengine v1
306
307The Google Maps Engine API allows developers to store and query geospatial vector and raster data.
308
309Official API documentation: https://developers.google.com/maps-engine/
310
311#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Mirror API - mirror v1
312
313API for interacting with Glass users via the timeline.
314
315Official API documentation: https://developers.google.com/glass
316
317#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google OAuth2 API - oauth2 v2
318
319Lets you access OAuth2 protocol related APIs.
320
321Official API documentation: https://developers.google.com/accounts/docs/OAuth2
322
Søren Gjesse2fcef162014-10-09 09:12:20 +0200323#### ![Logo](https://www.google.com/images/icons/product/pagespeed-16.png) PageSpeed Insights API - pagespeedonline v1
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200324
325Lets you analyze the performance of a web page and get tailored suggestions to make that page faster.
326
327Official API documentation: https://developers.google.com/speed/docs/insights/v1/getting_started
328
329#### ![Logo](http://www.google.com/images/icons/product/gplus-16.png) Google+ API - plus v1
330
331The Google+ API enables developers to build on top of the Google+ platform.
332
333Official API documentation: https://developers.google.com/+/api/
334
335#### ![Logo](http://www.google.com/images/icons/product/gplus-16.png) Google+ Domains API - plusDomains v1
336
337The Google+ API enables developers to build on top of the Google+ platform.
338
339Official API documentation: https://developers.google.com/+/domains/
340
341#### ![Logo](http://www.google.com/images/icons/feature/predictionapi-16.png) Prediction API - prediction v1.6
342
343Lets you access a cloud hosted machine learning service that makes it easy to build smart apps
344
345Official API documentation: https://developers.google.com/prediction/docs/developer-guide
346
347#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) QPX Express API - qpxExpress v1
348
349Lets you find the least expensive flights between an origin and a destination.
350
351Official API documentation: http://developers.google.com/qpx-express
352
353#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Enterprise Apps Reseller API - reseller v1
354
355Lets you create and manage your customers and their subscriptions.
356
357Official API documentation: https://developers.google.com/google-apps/reseller/
358
359#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Google Site Verification API - siteVerification v1
360
361Lets you programatically verify ownership of websites or domains with Google.
362
363Official API documentation: https://developers.google.com/site-verification/
364
365#### ![Logo](https://www.google.com/images/icons/product/cloud_storage-16.png) Cloud Storage API - storage v1
366
367Lets you store and retrieve potentially-large, immutable data objects.
368
369Official API documentation: https://developers.google.com/storage/docs/json_api/
370
Søren Gjesseee081772014-11-05 12:32:29 +0100371#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) Tag Manager API - tagmanager v1
372
373API for accessing Tag Manager accounts and containers.
374
375Official API documentation: https://developers.google.com/tag-manager/api/v1/
376
377#### ![Logo](https://www.google.com/images/icons/product/tasks-16.png) Tasks API - tasks v1
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200378
379Lets you manage your tasks and task lists.
380
381Official API documentation: https://developers.google.com/google-apps/tasks/firstapp
382
Søren Gjesse42f96152014-12-01 15:16:51 +0100383#### ![Logo](https://www.google.com/images/icons/product/translate-16.png) Translate API - translate v2
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200384
385Lets you translate text from one language to another
386
387Official API documentation: https://developers.google.com/translate/v2/using_rest
388
389#### ![Logo](http://www.google.com/images/icons/product/search-16.gif) URL Shortener API - urlshortener v1
390
391Lets you create, inspect, and manage goo.gl short URLs
392
393Official API documentation: http://code.google.com/apis/urlshortener/v1/getting_started.html
394
395#### ![Logo](http://www.google.com/images/icons/feature/font_api-16.png) Google Fonts Developer API - webfonts v1
396
397The Google Fonts Developer API.
398
399Official API documentation: https://developers.google.com/fonts/docs/developer_api
400
Søren Gjessea7d1bd02014-09-29 17:56:55 +0200401#### ![Logo](https://www.google.com/images/icons/product/webmaster_tools-16.png) Webmaster Tools API - webmasters v3
402
403Lets you view Google Webmaster Tools data for your verified sites.
404
405Official API documentation: https://developers.google.com/webmaster-tools/v3/welcome
406
407#### ![Logo](https://www.google.com/images/icons/product/youtube-16.png) YouTube Data API - youtube v3
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200408
409Programmatic access to YouTube features.
410
411Official API documentation: https://developers.google.com/youtube/v3
412
Søren Gjesse42f96152014-12-01 15:16:51 +0100413#### ![Logo](https://www.google.com/images/icons/product/youtube-16.png) YouTube Analytics API - youtubeAnalytics v1
Martin Kustermannf9c50a22014-09-10 15:26:11 +0200414
415Retrieve your YouTube Analytics reports.
416
417Official API documentation: http://developers.google.com/youtube/analytics/
418