{ "info": { "author": "Andrew Babenko", "author_email": "andruonline11@gmail.com", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "License :: OSI Approved :: Apache Software License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Office/Business :: Financial :: Spreadsheet", "Topic :: Software Development", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "1) Create client_secret.json in Google APIs Console:\n- Create new project in Google APIs Console(https://console.developers.google.com/iam-admin/projects);\n- Open the Credentials page (https://console.developers.google.com/apis/credentials) and create new credentials Add credentials > OAuth 2.0 client ID;\n- In 'Type of application' select 'Other types' and enter the name of client(for example 'Spreedsheet client') and press 'Create';\n- Select your created client and download it like a JSON file;\n- Rename json file to 'client_secret.json' and put it to your project dir\n- Activate Google Drive API and Google Sheets API in Google Dev. Console (https://console.developers.google.com/apis/library)\n\n2) Create an instance of an object:\n- Import SpreadsheetWorker and PERMISSION_TYPES to your project\n- \u0421reate an instance of the class SpreadsheetWorker and pass to him a path to your client_secret.json file as first argument. Then you can pass title spreadsheet, that will be created\n\n!!!REMARK!!!: when you run creating of spreadsheet for the first time and accept agreement in your browser, may happen, that your spreadsheet will not created. To solve this problem, just run script again. This problem is connected with the creation of .credentials directory.\n\n3) Import package:\nfrom PythonGoogleSpreadsheet.PythonGoogleSpreadsheet import SpreadsheetWorker, PERMISSION_TYPES\n\nMethods of python-google-spreadsheet:\n- spreadsheet_constructor(output_data):\n\tCreate new Google Spreadsheet\n\tIf output_data not define, spreadsheet generator create new empty spreadsheet with access permission only for user, who allowed using his data for app (in browser). Else create new spreadsheet with access permission only for user, who allowed using his data for app (in browser) and data from output_data\n\t\n\t:param output_data(non-requirement): - data for recording to Spreadsheet (if not specified, spreadsheet will be create empty)\n\t\texample:\n\t\toutput_data = [\n\t\t\t['Iron Man', 'Tony Stark'],\n [43, 1.75, 80],\n ['Just like his costume;-]']\n ]\n\t:return: new spreadsheet id\n\n- record_data(output_data, spreadsheet_id):\n\tRecord data to spreadsheet\n\n\t:param output_data: - data for recording to Spreadsheet\n\t:param spreadsheet_id: - id of modifying spreadsheet\n\t:return: - response from Google\n\n- get_spreadsheet_data(spreadsheet_id, sheet_name, sheet_range):\n Get data from spreadsheet by sheet name and sheet range\n!!!REMARK!!!: sheet_name must be consist of letters of the Latin alphabet\n\n :param spreadsheet_id: - id of modifying spreadsheet\n :param sheet_name: - name of sheet from which the data will be taken\n :param sheet_range: - range of columns(Example - 'A3:B10').\n :return: - array of values from selected sheet in spreadsheet\n\n- add_permission(spreadsheet_id, permission_type, user_email):\n\tAdd new permission to spreadsheet with id spreadsheet_id\n\n\t:param spreadsheet_id: - spreadsheet id\n\t:param permission_type: - type of permission, that apply to the spreadsheet\n\t:param user_email(non-requirement): - email of user, to which is added permission\n\t:return: response or None\n\n- show_permissions(spreadsheet_id):\n\tShow all permissions of selected spreadsheet (with id spreadsheet_id)\n\t\n\t:param spreadsheet_id: - spreadsheet id\n\t:return: - permissions\n\n- remove_permission(spreadsheet_id, permission_id):\n\tRemove permission by id of permission\n\t\n\t:param spreadsheet_id: - spreadsheet id\n\t:param permission_id: - id of permission to delete(can get in from response of show_permission-method)\n\t:return: ''", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/HolmesInc/spreadsheet_maker.git", "keywords": "'google-spreadsheet','spreadsheet','create-google-spreadsheet'", "license": "LICENSE", "maintainer": "", "maintainer_email": "", "name": "spreadsheet-maker", "package_url": "https://pypi.org/project/spreadsheet-maker/", "platform": "", "project_url": "https://pypi.org/project/spreadsheet-maker/", "project_urls": { "Homepage": "https://github.com/HolmesInc/spreadsheet_maker.git" }, "release_url": "https://pypi.org/project/spreadsheet-maker/1.0/", "requires_dist": null, "requires_python": "", "summary": "Simple framework to create Google Spreadsheet with python", "version": "1.0" }, "last_serial": 2366093, "releases": { "1.0": [ { "comment_text": "", "digests": { "md5": "2827fe64d9beb619d78a3730cf2d756b", "sha256": "855fe72f421c349c7f2f77cae428b13a72cb2e895dacbb4a86843e627af39b96" }, "downloads": -1, "filename": "spreadsheet_maker-1.0.tar.gz", "has_sig": false, "md5_digest": "2827fe64d9beb619d78a3730cf2d756b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5720, "upload_time": "2016-09-27T11:06:03", "url": "https://files.pythonhosted.org/packages/b8/5b/52ff69293ca68389a0908335d94e2b2af96ffe1f6041bb920c19f62258fc/spreadsheet_maker-1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "2827fe64d9beb619d78a3730cf2d756b", "sha256": "855fe72f421c349c7f2f77cae428b13a72cb2e895dacbb4a86843e627af39b96" }, "downloads": -1, "filename": "spreadsheet_maker-1.0.tar.gz", "has_sig": false, "md5_digest": "2827fe64d9beb619d78a3730cf2d756b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5720, "upload_time": "2016-09-27T11:06:03", "url": "https://files.pythonhosted.org/packages/b8/5b/52ff69293ca68389a0908335d94e2b2af96ffe1f6041bb920c19f62258fc/spreadsheet_maker-1.0.tar.gz" } ] }