Google API Acquisition Tool¶
Access many APIs and acquire as much user identifying information as possible.
Getting Started¶
Gripper depends on an active G Suite account, which requires a domain name for your organization (you can create a new domain while creating your G Suite account if you don’t already have one).
Only has been tested in a Linux environment.
Install python 3 / pip3
Install google api python client
pip3 install --upgrade google-api-python-client
Prerequisites¶
Installing¶
Running¶
Command line:
Usage: gripper.py drive [options] (created | revised | comment) ...
gripper.py reports [options]
Options:
-c --cached Use a cached version of the data, if available.
-e EMAIL --email=EMAIL
The email address of a user to impersonate. This requires
domain-wide delegation to be activated. See
https://developers.google.com/admin-sdk/reports/v1/guides/delegation
for instructions.
--level=LEVEL The granularity level of the resulting heat map [default: hr]
--start=START -s START
The earliest data to collect. Can be any kind of date string,
as long as it is unambiguous (e.g. "2017"). It can even be
slang, such as "a year ago". Be aware, however, that only the
*day* of the date will be used, meaning time information will
be discarded.
--end=END -e END
The latest data to collect. Same format rules apply for this
as for --start.
--tz=TIMEZONE The timezone to convert all timestamps to before compiling.
This should be a standard timezone name. For reference, the
list that the timezone will be compared against is available
at https://github.com/newvem/pytz/blob/master/pytz/__init__.py.
If omitted, the local timezone of the computer will be used.
Note: If you start this script using ipython (recommended), you'll need to
invoke it like this:
$ ipython3 gripper.py -- [typical arguments]
The reason for this is that ipython interprets any options *before* the ``--``
as being meant for it.
Bugs or Issues¶
If you receive this error:
Failed to start a local webserver listening on either port 8080
or port 8090. Please check your firewall settings and locally
running programs that may be blocking or using those ports.
use: lsof -w -n -i tcp:8080
or lsof -w -n -i tcp:8090
respectively.
then: kill -9 PID
Or you can click the click provided in the terminal and then copy and paste the key from the webpage that is launched.
API Documentation¶
Please refer to the following documents for information on the API:
MIME Type Info¶
As specified in the Google Drive API documentation, G Suite and Google Drive use MIME types specific to those services, as follows:
MIME Type | Description |
---|---|
application/vnd.google-apps.audio | |
application/vnd.google-apps.document | Google Docs |
application/vnd.google-apps.drawing | Google Drawing |
application/vnd.google-apps.file | Google Drive file |
application/vnd.google-apps.folder | Google Drive folder |
application/vnd.google-apps.form | Google Forms |
application/vnd.google-apps.fusiontable | Google Fusion Tables |
application/vnd.google-apps.map | Google My Maps |
application/vnd.google-apps.photo | |
application/vnd.google-apps.presentation | Google Slides |
application/vnd.google-apps.script | Google Apps Scripts |
application/vnd.google-apps.sites | Google Sites |
application/vnd.google-apps.spreadsheet | Google Sheets |
application/vnd.google-apps.unknown | |
application/vnd.google-apps.video | |
application/vnd.google-apps.drive-sdk | 3rd party shortcut |
In addition to the above MIME types, Google Doc formats can be exported as the following MIME types, as described in the Drive documentation:
Google Doc Format | Conversion Format | Corresponding MIME type |
---|---|---|
Documents | HTML | text/html |
HTML (zipped) | application/zip | |
Plain text | text/plain | |
Rich text | application/rtf | |
Open Office doc | application/vnd.oasis.opendocument.text | |
application/pdf | ||
MS Word document | application/vnd.openxmlformats-officedocument .wordprocessingml.document | |
EPUB | application/epub+zip | |
Spreadsheets | MS Excel | application/vnd.openxmlformats-officedocument .spreadsheetml.sheet |
Open Office sheet | application/x-vnd.oasis.opendocument.spreadsh eet | |
application/pdf | ||
CSV (1st sheet only) | text/csv | |
TSV (1st sheet only) | text/tab-separated-values | |
HTML (zipped) | application/zip | |
Drawings | JPEG | image/jpeg |
PNG | image/png | |
SVG | image/svg+xml | |
application/pdf | ||
Presentations | MS PowerPoint | application/vnd.openxmlformats-officedocument .presentationml.presentation |
Open Office presentation | application/vnd.oasis.opendocument.presentati on | |
application/pdf | ||
Plain text | text/plain | |
Apps Scripts | JSON | application/vnd.google-apps.script+json |
Authors¶
- Daniel Caruso II - Creator - Daniel Caruso II