-
Notifications
You must be signed in to change notification settings - Fork 17
Home
Mike McCann edited this page Feb 1, 2019
·
3 revisions
Python wrapper for the Help Scout API
- Python 2.7
- requests
- json
- base64
import hsapi
client = hsapi.ApiClient()
client.API_KEY = "your-api-key-here"
mailboxes = client.mailboxes()
folders = mailboxes.folders
for f in folders:
#do things here
customer = client.customer(customer-id-here)
if customers.socialProfiles != None:
for s in customers.socialProfiles:
#do things
Field selectors are given as a list of Strings. When field selectors are used, the appropriate object is created with the fields provided.
Each method can accept a field selector as an addition parameter.
- mailboxes()
- mailbox(int mailbox_id)
- folders(int mailbox_id)
- conversations_for_folder(int mailbox_id, int folder_id)
- conversations_for_mailbox(int mailbox_id)
- conversations_for_customerByMailbox(int mailbox_id, int customer_id)
- conversation(Integer conversation_id)
- attachment_data(int attachment_id)
- customers()
- customer(int customer_id)
- users()
- users_for_mailbox(int mailbox_id)
- user(int user_id)