smartsheet-dataframe
Python library to ease movement of data between a Smartsheet or report and a Pandas DataFrame.
This package can be used alongside the smartsheet-python-sdk
package or can be used standalone.
TODO:
- Implement functions to write to a sheet
- Implement usage of Pandas kwargs
Installation
Requirements
- Python 3+ (Tested using 3.8+)
- Pandas >= 0.24.0
- Requests >= 2.0.0
From PyPI
pip install smartsheet-dataframe
Usage
Sheet
To get a sheet as a dataframe:
from smartsheet_dataframe import get_as_df, get_sheet_as_df
# Standalone (without smartsheet-python-sdk)
df = get_sheet_as_df(token='smartsheet_auth_token',
sheet_id=sheet_id_int)
# Using 'generic' function (without smartsheet-python-sdk)
df = get_as_df(type_='sheet',
token='smartsheet_auth_token',
id_=sheet_id_int)
Alternatively, sheet objects can be used from the smartsheet-python-sdk package:
from smartsheet_dataframe import get_as_df, get_sheet_as_df
import smartsheet
# Using smartsheet-python-sdk
smartsheet_client = smartsheet.Smartsheet('smartsheet_auth_token')
sheet = smartsheet_client.Sheets.get_sheet(sheet_id_int)
df = get_sheet_as_df(sheet_obj=sheet)
# And using the 'generic' function
df = get_as_df(type_='sheet',
obj=sheet)
Report
To get a report as a dataframe:
from smartsheet_dataframe import get_as_df, get_report_as_df
# Standalone (without smartsheet-python-sdk)
df = get_report_as_df(token='smartsheet_auth_token',
report_id=report_id_int)
# Using 'generic' function (without smartsheet-python-sdk)
df = get_as_df(type_='report',
token='smartsheet_auth_token',
id_=report_id_int)
And using a report object from the smartsheet-python-sdk package:
from smartsheet_dataframe import get_as_df, get_report_as_df
import smartsheet
# Using smartsheet-python-sdk
smartsheet_client = smartsheet.Smartsheet('smartsheet_auth_token')
report = smartsheet_client.Reports.get_report(report_id_int)
df = get_report_as_df(report_obj=report)
# And using the 'generic' function
df = get_as_df(type_='report',
obj=report)
Metadata
Release files for smartsheet-dataframe 0.3.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| smartsheet_dataframe-0.3.7.tar.gz | 9.8 kB | Without provenance | Details for smartsheet_dataframe-0.3.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| smartsheet_dataframe-0.3.7-py3-none-any.whl | Python 3 | none | any | Details for smartsheet_dataframe-0.3.7-py3-none-any.whl |
Total release size: 17.0 kB
Release files / smartsheet_dataframe-0.3.7.tar.gz
| Download URL | smartsheet_dataframe-0.3.7.tar.gz |
|---|---|
| Size | 9.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
759d214676d837ead5ce6732ab08497e3ee012e452e39a74848a8f9bc418d71e
|
|
BLAKE2b-256 checksum How to use checksums |
66813e77fb54e9f8203eaa41bd5290fa2896b4880d402a97fc1ff7fbda77d6c5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Release files / smartsheet_dataframe-0.3.7-py3-none-any.whl
| Download URL | smartsheet_dataframe-0.3.7-py3-none-any.whl |
|---|---|
| Size | 7.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
820a1eebce5ba752b0f36509b061ac3e0869498ce6d47ec353f27d3c8368c775
|
|
BLAKE2b-256 checksum How to use checksums |
39a4da990c925fd02245ecec1bf25708511b7bc7d116a7240ae2263460f9fcfe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Security for smartsheet-dataframe 0.3.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.