Workflow is not triggering when a record is created through code

Workflow is not triggering when a record is created through code

I have a custom function that populates mailing lists, the basic operation of which is:
Get Mailing List --> Delete everyone from it --> Decide who needs to be added --> Add them. 

Every time a contact is added or deleted from a mailing list, a record entry in a linking module Contacts X Mailing Lists is created or deleted accordingly. There are also two workflows that I would like to run on those operations, a workflow that executes when a record is created and another workflow when a record is deleted. 

The issue is that when a record in Contacts X Mailing is created via the custom function using the code:
response = zoho.crm.createRecord("Contacts_X_Mailing_lists",myMap); , the workflow rule (with a trigger on create/edit) is not triggered. However, the workflow rule on delete is successfully triggered for every deleted record via the custom function. The delete code is: 
theUrl = "https://www.zohoapis.com/crm/v2/Contacts_X_Mailing_lists/" + OneCheckML.get("id");
deleteLMResponse = invokeurl
[
url :theUrl
type :DELETE
connection:"zoho_crm87"
];

To summarise the issue, the workflow rule on create/edit is not triggered by the custom function while the workflow rule on delete is successfully triggered. 

Note: Repeat this workflow whenever a contacts x mailing lists is edited is ticked on both workflow rules.

How should I go about triggering the workflow on edit/create? Is there a difference between the two techniques of modifying records invokeurl and createRecord()?