Get data from Salesforce reports with python
Project description
Get data straight from your Salesforce reports via python using the Analytics API.
Install
Install via pip:
pip install salesforce-reporting
Examples
Authentication
Connect to the Salesforce Analytics API and request data from a report:
import salesforce_reporting my_sf = salesforce_reporting.Connection('your_id', 'your_secret', 'your_username', 'your_password', 'your_instance') my_sf.get_report('report_id', includeDetails=True)
Get records from report
Use the ReportParser to access all the records included in a report:
report = my_sf.get_report('report_id', includeDetails=True) parser = salesforce_reporting.ReportParser(report) parser.records()
Extract series from matrix report
For a matrix report grouped across the top by Calendar Month doing:
report = my_sf.get_report('report_id') matrix_parser = salesforce_reporting.MatrixParser(report) matrix_parser.series_down('May 2012')
Will return all values for ‘May 2012’ as values in a dictionary with the row groupings as keys.
Coming Soon
Simplified Authentication process
Access to Dashboards
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for salesforce_reporting-0.1.3-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15bcc58c3e7002dbe39e6227c5d3b14122d0741cb2a0c8c3d91cc606055a1bdc |
|
MD5 | 4ab3b18f28d56fb339f777b88b579f24 |
|
BLAKE2b-256 | 5a1041aaec354b4862f5491a62f5685133731f998e4c5c66ba935b627daac7b3 |