pardot-api-client
A Python client for the Pardot API.
It provides object notation for interacting with resources on the API in clean and simple idiomatic statements like:
>>> client.prospect.read('someone@example.com')
>>> client.prospect.update('someone@example.com', first_name='John')
Features
Supports Python 2 and 3
Supports API version 3
Supports all API entities: Account, Campaign, Custom Field, Custom Redirect, Dynamic Content, Email, Email Clicks, Form, Identified Company, Lifecycle History, Lifecycle Stage, List, List Membership, Opportunity, Profile, Profile Criteria, Prospect, Prospect Account, Tag, Tag Object, User, Visit, Visitor, Visitor Activity, Visitor Page View, Visitor Referrer
Supports most API operations: query, assign, unassign, create, read, update, upsert, delete
Supports un-setting of field values
Handles API session timeouts implicitly
Transparent API error feedback
Optional request retries with incremental back-off
Planned features
Support for API version 4
Support for API batch operations: batchCreate, batchUpdate, batchUpsert
Supports result set manipulation, eg specifying fields, limit, offset, sort_by, sort_order
Implicit results pagination
Implicit chunking for batch operationss
Installation
$ pip install pardot-api-client
Usage
Obtain API authentication credentials from Pardot by following instructions at http://developer.pardot.com/#authentication - you’ll need the following: email, password, user_key
Review the supported Pardot API documentation at http://developer.pardot.com/#official-pardot-api-documentation
Use the Python API client to interact with the API:
>>> from pardot.client import APIClient >>> client = APIClient( ... 'pardot-email', ... 'pardot-password', ... 'pardot-user_key') ... >>> # read >>> r = client.prospect.read('someone@example.com') >>> print(r) >>> # update >>> r = client.prospect.update('someone@example.com', first_name='John') >>> print(r) >>> # query >>> for r in client.prospect.query(new=True): ... print(r) ...
Arguments vs keyword arguments
To keep the client’s API simple it makes educated guesses about the identifiers passed in resource operation calls.
To make this work all required parameters (except user_key and api_key, which are automatically added) must be passed as positional arguments and any optional parameters passed as keyword arguments.
For instance, the API documentation states that “assign” operations on “prospect” resources may use either “email” or “id” as identifiers and must supply one of the following parameters: “user_email” or “user_id” or “group_id”. Any of the forms below could be used to make this call from the client:
>>> # identify by email
>>> client.prospect.update('someone@example.com', user_email='someone-else@example.com')
>>> client.prospect.update('someone@example.com', user_id=2544897)
>>> client.prospect.update('someone@example.com', group_id=5499876)
>>> # identify by id
>>> client.prospect.update(7142577, user_email='someone-else@example.com')
>>> client.prospect.update(7142577, user_id=2544897)
>>> client.prospect.update(7142577, group_id=5499876)
Metadata
Release files for pardot-api-client 0.0.1
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 |
|---|---|---|---|---|
| pardot-api-client-0.0.1.tar.gz | 6.7 kB | Without provenance | Details for pardot-api-client-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pardot_api_client-0.0.1-py2-none-any.whl | Python 2 | none | any | Details for pardot_api_client-0.0.1-py2-none-any.whl |
Total release size: 14.6 kB
Release files / pardot-api-client-0.0.1.tar.gz
| Download URL | pardot-api-client-0.0.1.tar.gz |
|---|---|
| Size | 6.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
85ce982bc394a84e5d3af426892806da8d8a00d6442693745a994d4fc26e8398
|
|
BLAKE2b-256 checksum How to use checksums |
b7f3cc50e5bba39facc88a7a12fb2119a735af0b8c2aa65e98eff3eef8b60bd0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / pardot_api_client-0.0.1-py2-none-any.whl
| Download URL | pardot_api_client-0.0.1-py2-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 2 |
|
SHA-256 checksum How to use checksums |
3eaa54abeb5a1ae75175ff7f06d8039685467643ba53cddd5bcc9c1d3d2cfa22
|
|
BLAKE2b-256 checksum How to use checksums |
587155e7dd9c272e9bc8334bbe6272c393b18e271f5ecef0aebee2098ca2b152
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for pardot-api-client 0.0.1
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.