Skip to main content

Pardot API Client

Project description

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.update('', first_name='John')


  • 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


$ pip install pardot-api-client


  1. Obtain API authentication credentials from Pardot by following instructions at - you’ll need the following: email, password, user_key

  2. Review the supported Pardot API documentation at

  3. 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 ='')
    >>> print(r)
    >>> # update
    >>> r = client.prospect.update('', 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('', user_email='')
>>> client.prospect.update('', user_id=2544897)
>>> client.prospect.update('', group_id=5499876)
>>> # identify by id
>>> client.prospect.update(7142577, user_email='')
>>> client.prospect.update(7142577, user_id=2544897)
>>> client.prospect.update(7142577, group_id=5499876)

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pardot-api-client-0.0.1.tar.gz (6.7 kB view hashes)

Uploaded source

Built Distribution

pardot_api_client-0.0.1-py2-none-any.whl (7.9 kB view hashes)

Uploaded 2 7

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page