Django application for Hubspot API integration
Project description
mitol-django-hubspot-api
This is the Open Learning Hubspot API integration app. It provides helper functions for Hubspot CRM API calls:
- CRUD functions for custom properties and property groups
- CRUD functions for deals, line items, products, and contacts
- Search/retrieve specific objects or lists of objects of a certain type
Getting started
pip install mitol-django-hubspot-api
Add the hubspot app:
INSTALLED_APPS = [
...
"mitol.hubspot_api.apps.HubspotApp",
]
Settings
Hubspot app settings
All settings for the mitol-django-hubspot-api
app are namespaced in django settings with MITOL_HUBSPOT_API
prefix.
MITOL_HUBSPOT_API_PRIVATE_TOKEN
- the private app token to be used for authentication (required)MITOL_HUBSPOT_API_RETRIES
- the number of times to retry API calls on failures (default=3)MITOL_HUBSPOT_API_ID_PREFIX
- a prefix used for generating custom unique object ids (default="app")
Usage
Instantiate an API client to make custom hubspot requests
from mitol.hubspot_api.api import HubspotApi, HubspotObjectType
client = HubspotApi()
client.crm.objects.basic_api.update(
simple_public_object_input=input_body,
object_id=123,
object_type=HubspotObjectType.DEALS.value,
)
Use helper functions to make common hubspot requests
from mitol.hubspot_api.api import find_product
hubspot_product = find_product("Product #1", price="123.99")
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 Distribution
Built Distribution
Close
Hashes for mitol-django-hubspot-api-1.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9ce13e2e2fbb8e81dde8a96d2ad9856109c5519b2ece69455cc7dbe4396fdfe8 |
|
MD5 | 375d0c17cff7958bdc8d50f502baf3e6 |
|
BLAKE2b-256 | 8ff4f6f19a997522577816535cb437184424d0b4960304d5b9c86f3b2239c8a5 |
Close
Hashes for mitol_django_hubspot_api-1.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 19c93d966dcae9bc65d4067cf2c6fdbd1580ea1c5abd02f9f108abfff093a5fa |
|
MD5 | 31df4d13c4410c7ad142a89643142d09 |
|
BLAKE2b-256 | 8db8d9e0791bb33f497a2b9b329be44886c290c25ecc55da1f03c626d58949a7 |