# Smartsheet Python SDK
[![Build Status](https://github.com/smartsheet/smartsheet-python-sdk/actions/workflows/test-build.yaml/badge.svg)](https://github.com/smartsheet/smartsheet-python-sdk/actions/workflows/test-build.yaml) [![PyPI version](https://badge.fury.io/py/smartsheet-python-sdk.svg)](https://badge.fury.io/py/smartsheet-python-sdk)
A library for connecting to the [Smartsheet API](https://smartsheet.redoc.ly) from Python applications.
## Requirements
The SDK is compatible with [actively supported](https://devguide.python.org/versions/#versions) Python versions `3.10`, `3.9`, `3.8`, `3.7`.
## Installation
To install using [pip](http://www.pip-installer.org/):
```bash
pip install smartsheet-python-sdk
```
## Getting Started
To get started with the Smartsheet Python SDK:
1. Set **SMARTSHEET_ACCESS_TOKEN** in your environment, using your Smartsheet API key. Find out more about [Authentication and Access Tokens](https://smartsheet.redoc.ly/#section/API-Basics/Authentication-and-Access-Tokens) in the Smartsheet API Documentation. You can generate an access token in Smartsheet UI under Account > Personal Settings > API Access.
2. Install the Smartsheet Python SDK (see the installation instructions above)
3. The following snippet shows how to create a Smartsheet client and perform some basic actions using the SDK. Ensure your Smartsheet user has access to at least one sheet.
``` python
import smartsheet
smart = smartsheet.Smartsheet() # Create a Smartsheet client
response = smart.Sheets.list_sheets() # Call the list_sheets() function and store the response object
sheetId = response.data[0].id # Get the ID of the first sheet in the response
sheet = smart.Sheets.get_sheet(sheetId) # Load the sheet by using its ID
print(f"The sheet {sheet.name} has {sheet.total_row_count} rows") # Print information about the sheet
```
## Documentation
Use the following resources to learn more about the SDK capabilities:
1. [Smartsheet Python SDK sample project](https://github.com/smartsheet-samples/python-read-write-sheet)
2. [Python SDK documentation](https://smartsheet.github.io/smartsheet-python-sdk/)
3. [Smartsheet API Documentation](https://smartsheet.redoc.ly)
## Advanced Topics
For details about logging, testing, how to use a passthrough option, and how to override HTTP client behavior,
see [Advanced Topics](ADVANCED.md).
Raw data
{
"_id": null,
"home_page": "http://smartsheet-platform.github.io/api-docs/",
"name": "smartsheet-python-sdk",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "Smartsheet,Collaboration,Project Management,Excel,spreadsheet",
"author": "Smartsheet",
"author_email": "api@smartsheet.com",
"download_url": "https://files.pythonhosted.org/packages/84/5b/7e1aea447f96733cdbd2625ca4492b9e4d6fd41d8349d0b9e4de9356155b/smartsheet-python-sdk-3.0.0.tar.gz",
"platform": null,
"description": "# Smartsheet Python SDK\n\n[![Build Status](https://github.com/smartsheet/smartsheet-python-sdk/actions/workflows/test-build.yaml/badge.svg)](https://github.com/smartsheet/smartsheet-python-sdk/actions/workflows/test-build.yaml) [![PyPI version](https://badge.fury.io/py/smartsheet-python-sdk.svg)](https://badge.fury.io/py/smartsheet-python-sdk)\n\nA library for connecting to the [Smartsheet API](https://smartsheet.redoc.ly) from Python applications.\n\n## Requirements\n\nThe SDK is compatible with [actively supported](https://devguide.python.org/versions/#versions) Python versions `3.10`, `3.9`, `3.8`, `3.7`.\n\n## Installation\n\nTo install using [pip](http://www.pip-installer.org/):\n\n```bash\npip install smartsheet-python-sdk\n```\n\n## Getting Started\n\nTo get started with the Smartsheet Python SDK:\n\n1. Set **SMARTSHEET_ACCESS_TOKEN** in your environment, using your Smartsheet API key. Find out more about [Authentication and Access Tokens](https://smartsheet.redoc.ly/#section/API-Basics/Authentication-and-Access-Tokens) in the Smartsheet API Documentation. You can generate an access token in Smartsheet UI under Account > Personal Settings > API Access.\n\n2. Install the Smartsheet Python SDK (see the installation instructions above)\n\n3. The following snippet shows how to create a Smartsheet client and perform some basic actions using the SDK. Ensure your Smartsheet user has access to at least one sheet.\n\n``` python\n\nimport smartsheet\n\nsmart = smartsheet.Smartsheet() # Create a Smartsheet client \n\nresponse = smart.Sheets.list_sheets() # Call the list_sheets() function and store the response object\nsheetId = response.data[0].id # Get the ID of the first sheet in the response\nsheet = smart.Sheets.get_sheet(sheetId) # Load the sheet by using its ID\n\nprint(f\"The sheet {sheet.name} has {sheet.total_row_count} rows\") # Print information about the sheet\n```\n\n## Documentation\n\nUse the following resources to learn more about the SDK capabilities:\n\n1. [Smartsheet Python SDK sample project](https://github.com/smartsheet-samples/python-read-write-sheet)\n2. [Python SDK documentation](https://smartsheet.github.io/smartsheet-python-sdk/)\n3. [Smartsheet API Documentation](https://smartsheet.redoc.ly)\n\n## Advanced Topics\n\nFor details about logging, testing, how to use a passthrough option, and how to override HTTP client behavior,\nsee [Advanced Topics](ADVANCED.md).\n",
"bugtrack_url": null,
"license": "Apache-2.0",
"summary": "Library that uses Python to connect to Smartsheet services (using API 2.0).",
"version": "3.0.0",
"split_keywords": [
"smartsheet",
"collaboration",
"project management",
"excel",
"spreadsheet"
],
"urls": [
{
"comment_text": "",
"digests": {
"md5": "61db81da363d66177d18994206a7a286",
"sha256": "bee48b90e2902543383e05d32693c38d82f6cfba844d2a75e6f8d56f9a4eb769"
},
"downloads": -1,
"filename": "smartsheet_python_sdk-3.0.0-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "61db81da363d66177d18994206a7a286",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": null,
"size": 228949,
"upload_time": "2022-12-07T13:48:35",
"upload_time_iso_8601": "2022-12-07T13:48:35.654805Z",
"url": "https://files.pythonhosted.org/packages/45/6d/c60d84ea7825c441891fdaa3833d408ee52d0af9dccb4e0cfd6427a95466/smartsheet_python_sdk-3.0.0-py2.py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"md5": "5eb5ffb25e2cc32760e42338740e7ed4",
"sha256": "9d710bea4a73a8a90c54334a5a042fc8a6f862cfcc64a9b391ff26155ef3dc6a"
},
"downloads": -1,
"filename": "smartsheet-python-sdk-3.0.0.tar.gz",
"has_sig": false,
"md5_digest": "5eb5ffb25e2cc32760e42338740e7ed4",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 331644,
"upload_time": "2022-12-07T13:48:37",
"upload_time_iso_8601": "2022-12-07T13:48:37.243823Z",
"url": "https://files.pythonhosted.org/packages/84/5b/7e1aea447f96733cdbd2625ca4492b9e4d6fd41d8349d0b9e4de9356155b/smartsheet-python-sdk-3.0.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2022-12-07 13:48:37",
"github": false,
"gitlab": false,
"bitbucket": false,
"lcname": "smartsheet-python-sdk"
}