{ "info": { "author": "Miguel Ferrer, Nerio Rincon, Yordy Gelvez", "author_email": "ingferrermiguel@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "# microsoft-python\nMicrosoft graph API wrapper for Microsoft Graph written in Python.\n\n## Installing\n```\npip install microsoftgraph-python\n```\n\n## Usage\nIf you need an office 365 token, send office365 attribute in True like this:\n```\nfrom microsoftgraph.client import Client\nclient = Client('CLIENT_ID', 'CLIENT_SECRET', account_type='by defect common', office365=True)\n```\n\nIf you don't, just instance the library like this:\n```\nfrom microsoftgraph.client import Client\nclient = Client('CLIENT_ID', 'CLIENT_SECRET', account_type='by defect common')\n```\n\n#### Get authorization url\n```\nurl = client.authorization_url(redirect_uri, scope, state=None)\n```\n\n#### Exchange the code for an access token\n```\ntoken = client.exchange_code(redirect_uri, code)\n```\n\n#### Refresh token\n```\ntoken = client.refresh_token(redirect_uri, refresh_token)\n```\n\n#### Set token\n```\ntoken = client.set_token(token)\n```\n\n#### Get me\n```\nme = client.get_me()\n```\n\n#### Get message\n```\nme = client.get_message(message_id=\"\")\n```\n\n### Webhook section, see the api documentation: https://developer.microsoft.com/en-us/graph/docs/api-reference/beta/resources/webhooks\n\n#### Create subscription\n```\nsubscription = client.create_subscription(change_type, notification_url, resource, expiration_datetime, client_state=None)\n```\n\n#### Renew subscription\n```\nrenew = client.renew_subscription(subscription_id, expiration_datetime)\n```\n\n#### Delete subscription\n```\nrenew = client.delete_subscription(subscription_id)\n```\n\n### Onenote section, see the api documentation: https://developer.microsoft.com/en-us/graph/docs/concepts/integrate_with_onenote\n\n#### List notebooks\n```\nnotebooks = client.list_notebooks()\n```\n\n#### Get notebook\n```\nnotebook = client.get_notebook(notebook_id)\n```\n\n#### Get notebook sections\n```\nsection_notebook = client.get_notebook_sections(notebook_id)\n```\n\n#### Create page\n```\nadd_page = client.create_page(section_id, files)\n```\n\n#### List pages\n```\npages = client.list_pages()\n```\n\n### Calendar section, see the api documentation: https://developer.microsoft.com/en-us/graph/docs/api-reference/beta/resources/calendar\n\n#### Get events\n```\nevents = client.get_me_events()\n```\n\n#### Create calendar event\n```\nevents = client.create_calendar_event(subject, content, start_datetime, start_timezone, end_datetime, end_timezone,\n recurrence_type, recurrence_interval, recurrence_days_of_week, recurrence_range_type,\n recurrence_range_startdate, recurrence_range_enddate, location, attendees, calendar=None)\n```\n\n#### Get calendars\n```\nevents = client.get_me_calendars()\n```\n\n#### Create calendar\n```\nevents = client.create_calendar(name)\n```\n\n### Contacts section, see the api documentation: https://developer.microsoft.com/en-us/graph/docs/api-reference/beta/resources/contact\n\n#### Get contacts\nIf you need a specific contact send the contact id in data_id\n```\nspecific_contact = client.outlook_get_me_contacts(data_id=\"\")\n```\nIf you want all the contacts\n```\nspecific_contact = client.outlook_get_me_contacts()\n```\n\n#### Create contact\n```\nadd_contact = client.outlook_create_me_contact()\n```\n\n#### Create contact in specific folder\n```\nadd_contact_folder = client.outlook_create_contact_in_folder(folder_id)\n```\n\n#### Get contact folders\n```\nfolders = client.outlook_get_contact_folders()\n```\n\n#### Create contact folders\n```\nadd_folders = client.outlook_create_contact_folder()\n```\n\n### Onedrive section, see the api documentation: https://developer.microsoft.com/en-us/graph/docs/api-reference/beta/resources/onedrive\n\n#### Get root items\n```\nroot_items = client.drive_root_items()\n```\n\n#### Get root children items\n```\nroot_children_items = client.drive_root_children_items()\n```\n\n#### Get specific folder items\n```\nfolder_items = client.drive_specific_folder(folder_id)\n```\n\n### Excel section, see the api documentation: https://developer.microsoft.com/en-us/graph/docs/api-reference/beta/resources/excel\nFor use excel, you should know the folder id where the file is\n#### Create session for specific item\n```\ncreate_session = client.drive_create_session(item_id)\n```\n\n#### Refresh session for specific item\n```\nrefresh_session = client.drive_refresh_session(item_id)\n```\n\n#### Close session for specific item\n```\nclose_session = client.drive_close_session(item_id)\n```\n\n#### Get worksheets\n```\nget_worksheets = client.excel_get_worksheets(item_id)\n```\n\n#### Get specific worksheet\n```\nspecific_worksheet = client.excel_get_specific_worksheet(item_id, worksheet_id)\n```\n\n#### Add worksheets\n```\nadd_worksheet = client.excel_add_worksheet(item_id)\n```\n\n#### Update worksheet\n```\nupdate_worksheet = client.excel_update_worksheet(item_id, worksheet_id)\n```\n\n#### Get charts\n```\nget_charts = client.excel_get_charts(item_id, worksheet_id)\n```\n\n#### Add chart\n```\nadd_chart = client.excel_add_chart(item_id, worksheet_id)\n```\n\n#### Get tables\n```\nget_tables = client.excel_get_tables(item_id)\n```\n\n#### Add table\n```\nadd_table = client.excel_add_table(item_id)\n```\n\n#### Add column to table\n```\nadd_column = client.excel_add_column(item_id, worksheets_id, table_id)\n```\n\n#### Add row to table\n```\nadd_row = client.excel_add_row(item_id, worksheets_id, table_id)\n```\n\n#### Get table rows\n```\nget_rows = client.excel_get_rows(item_id, table_id)\n```\n\n#### Get range\n```\nget_range = client.excel_get_range(item_id, worksheets_id)\n```\n\n#### Update range\n```\nupdate_range = client.excel_update_range(item_id, worksheets_id)\n```\n\n## Requirements\n- requests\n\n## Tests\n```\ntest/test.py\n```", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/GearPlug/microsoftgraph-python", "keywords": "", "license": "GPL", "maintainer": "", "maintainer_email": "", "name": "microsoftgraph-python", "package_url": "https://pypi.org/project/microsoftgraph-python/", "platform": "", "project_url": "https://pypi.org/project/microsoftgraph-python/", "project_urls": { "Homepage": "https://github.com/GearPlug/microsoftgraph-python" }, "release_url": "https://pypi.org/project/microsoftgraph-python/0.1.6/", "requires_dist": null, "requires_python": "", "summary": "API wrapper for Microsoft Graph written in Python", "version": "0.1.6" }, "last_serial": 5705588, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "f1b105e20f7bdcfd9a29c6d74c696e21", "sha256": "149bb0f858058c18b3926da396995fc668a3b9f3ede3cc5f949a2f2854802c2a" }, "downloads": -1, "filename": "microsoftgraph-python-0.1.tar.gz", "has_sig": false, "md5_digest": "f1b105e20f7bdcfd9a29c6d74c696e21", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7979, "upload_time": "2018-02-23T14:54:06", "url": "https://files.pythonhosted.org/packages/13/4a/7c7c3001909bc25b07e16d56cf3dc8d184cf821963edb917626f1e4088ee/microsoftgraph-python-0.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "1057d3818392f660c8b07a74ab1076a7", "sha256": "df703e22ca72209b6c7f903639d35b3f8102ffd45e677877040895365e6938ed" }, "downloads": -1, "filename": "microsoftgraph-python-0.1.2.tar.gz", "has_sig": false, "md5_digest": "1057d3818392f660c8b07a74ab1076a7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8657, "upload_time": "2018-02-26T13:01:06", "url": "https://files.pythonhosted.org/packages/f4/ab/dd5cdeb151d5ada14e348112b661776a302b2f21c26ffed436bf60fd7f33/microsoftgraph-python-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "c6ba9990d43956809114ab2fabcacfdc", "sha256": "c5e853a82de6b26ff25086ffde52005ed73a34a9332b9f148a48fecd64edfa04" }, "downloads": -1, "filename": "microsoftgraph-python-0.1.3.tar.gz", "has_sig": false, "md5_digest": "c6ba9990d43956809114ab2fabcacfdc", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8226, "upload_time": "2018-09-20T15:53:13", "url": "https://files.pythonhosted.org/packages/0f/20/7816e52412e16255f676b79c89dd6536725f3550fd8876c7ab397e8d4404/microsoftgraph-python-0.1.3.tar.gz" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "976d38e49c7b12a393006c6d8e15d108", "sha256": "147906b89657ae0079bd9bceae563facbf936ef82834ab327831b2caff8cdacc" }, "downloads": -1, "filename": "microsoftgraph-python-0.1.5.tar.gz", "has_sig": false, "md5_digest": "976d38e49c7b12a393006c6d8e15d108", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7543, "upload_time": "2019-05-28T21:50:11", "url": "https://files.pythonhosted.org/packages/91/0a/efa22b5f102559aa86140d05757c886e6d13f72dfa0783c4a34bff562bf7/microsoftgraph-python-0.1.5.tar.gz" } ], "0.1.6": [ { "comment_text": "", "digests": { "md5": "78313a161e87bcb1525ed9d7189cfc82", "sha256": "315dbe9a2a650f564181f32015a090cda33c909909a1aa29e58ac220faeba01c" }, "downloads": -1, "filename": "microsoftgraph-python-0.1.6.tar.gz", "has_sig": false, "md5_digest": "78313a161e87bcb1525ed9d7189cfc82", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8256, "upload_time": "2019-08-20T20:51:49", "url": "https://files.pythonhosted.org/packages/cb/bc/3a31923567eb4a0397a8c40f929fef9d03db1d2c8b1867c5dcaa8e6937e9/microsoftgraph-python-0.1.6.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "78313a161e87bcb1525ed9d7189cfc82", "sha256": "315dbe9a2a650f564181f32015a090cda33c909909a1aa29e58ac220faeba01c" }, "downloads": -1, "filename": "microsoftgraph-python-0.1.6.tar.gz", "has_sig": false, "md5_digest": "78313a161e87bcb1525ed9d7189cfc82", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8256, "upload_time": "2019-08-20T20:51:49", "url": "https://files.pythonhosted.org/packages/cb/bc/3a31923567eb4a0397a8c40f929fef9d03db1d2c8b1867c5dcaa8e6937e9/microsoftgraph-python-0.1.6.tar.gz" } ] }