from__future__importprint_functionimporttimeimportbraangoimportbraango.modelsimportbraango.apisfrombraango.restimportApiExceptionfrompprintimportpprint''' @author braango Sample code showing how to delete all email for personnel'''#TEST auth token. Please contact#sales@braango.com to have one#created for youbraango.configuration.api_key['auth_token']='ISNWF0P30WM0CMK'# create an instance of the API classapi_instance=braango.EmailsApi()# str | id of _sub_dealer_subdealerid='subdealers2004'# str | if of _personnel_salespersonid='c5313913-5768-4eef-b5ea-447cc8f5aec3'# str | API Key to access this dealer's resources. #Value was returned when create_account api was called and #dealer was created first time api_key='ISNMdzuNiKG7jhl9d9v'#Set the account type to partner for#virtual dealer and partner hosted#accountsaccount_type="partner"# bool | Specifies to get ADF CRM email records or plain email records.#If not specified, default is false i.e. regular email ID accounts type_adf_crm=Truetry:# Delete emailapi_response=api_instance.delete_email(subdealerid,salespersonid,api_key,account_type,type_adf_crm=type_adf_crm)pprint(api_response)exceptApiExceptionase:print("Exception when calling EmailsApi->delete_email: %s\n"%e)
Comments (0)
HTTPSSSH
You can clone a snippet to your computer for local editing.
Learn more.