When a third-party service like Zoho Sign sends out an email on your behalf, it may be considered as spoofing or phishing attempts, and be marked as spam by the recipients' email services, or even quarantined or blocked. Verifying your email domain in Zoho Sign using the DomainKeys Identified Mail (DKIM) method will prevent such a situation from arising. To do so:
Note: It may take a few hours for your domain to get verified based on the TTL (Time To Live) value specified in the TXT record. The TXT record must not be removed from your domain host console, unless you want to stop using your email address to send Zoho Sign mails.
This can be done from the Deals module inside Zoho CRM by making use of the Zoho Sign extension together with the templates option—either Zoho Sign templates or CRM's mail-merge templates.
Using Zoho Sign templates:Create a template inside the Zoho Sign application by uploading the document and configuring the prefill and signer fields.
Navigate to the module inside Zoho CRM and open the respective record. Click the Send for Zoho Sign button.Configure the sign workflow by importing the Zoho Sign template, mapping prefill fields with record fields, adding the recipient, and setting up reminders.
Click the Quick Send button to send the document out for signing. Using Mail Merge templates:Create a mail-merge template inside Zoho CRM by uploading the document and inserting the record fields to be merged.
Navigate to the module inside Zoho CRM and open the respective record. Click the Send for Zoho Sign button.Configure the sign workflow by importing the mail-merge template and creating a merged document, adding the recipient, and setting up reminders.
Proceed with the workflow and verify the details once again in the Zoho Sign interface.Add any additional signer fields in the Document Viewer screen, if required, and send the document out for signing.
The signed document will be stored back onto the CRM as an attachment in the document record inside the ZohoSign Documents custom module.
An example URL for a custom module named References:
https://extensions.zoho.com/plugin/zohosign/handler?action=createZohoSignDocument&module= References &rec_id= $ &rec_name= $ &crmzgid= 1xxxxxxx09
Note: However, do note that creating a button to send documents for signatures from custom modules will not extend the Zoho Sign extension's behaviour of attaching a copy of the signed documents back to the associated record.
This can be done by doing the registration via a Zoho Form, and integrating it with a template created inside the Zoho Sign application. To do so:
This can be done by creating the necessary form on Zoho Forms, creating the document template on Zoho Sign, and integrating it with the form to create a self-serviced sign workflow. To do so:
This can be easily achieved by using the Zoho Writer tool, an online word processor, and the Zoho Sign integration for Writer. To do this:
//Fetching keys for merge fields
getfields = invokeurl
[
url :"https://writer.zoho.com/api/v1/documents/ /mergefields"
type :GET
connection:" "
];
info getfields;
//Fetching candidate data by ID
candidate = zoho.recruit.getRecordById("Candidates",id);
currentDateTime = now;
sent_on = currentDateTime.getDate();
cand_email = candidate.get("Email");
//Construct key-value variable for mapping all mail merge fields with candidate data
//Example illustrated below is for an offer letter document
fields = Map();
fields.put( "Sent_On",sent_on );
fields.put( "Lead_Name",candidate.get("First Name") + " " + candidate.get("Last Name") );
fields.put( "Lead_Name.First_Name",candidate.get("First Name") );
fields.put( "Lead_Name.Posting_Title",candidate.get("Posting Title") );
fields.put( "Expected_Joining_Date",candidate.get("Expected Date of Joining") );
fields.put( "org.company_name","zoho" );
//Construct key-value variable for output settings
output_settings = Map();
output_settings.put( "doc_name","Document Name" );
//Performing merge and store using Writer
resp = zoho.writer.mergeAndStore(" ",fields,output_settings," ");
info response;
doc_id = response.get("document_id");
//Adding recipient email and configuring sign workflow settings
recipientsList=List();
recipientsList.add( "test@example.com" );
recipientsList.add(cand_email);
inputMap=Map();
inputMap.put( "subject","Please sign this offer letter." );
inputMap.put( "is_sequential",true );
You may refer to the Deluge guide, especially the Writer tasks section, for detailed information on further modification and customization of this function.
- Do not click Save and Execute.
- After the function is saved, search for the function using the function's name. Click the ellipses next to the function name and select REST API.
Note:
- This can only be done by Zoho CRM admin.
- After saving this function, you will need to make this webhook as an invokable URL. In order to do this, click on setting icon next to the function name and choose Rest API. In the dialog box that appears, turn on the API key option. Copy the generated unique URL and note it for later reference.
When documents are sent for signature from CRM using Zoho Sing's extension, the documents will be updated in CRM. However, in other instances such as automation and workflow, this will not be done. You need to create a custom callback function, which can be done by following the steps from Question 1. Paste the following code:
crmAPIRequestMap = crmAPIRequest.toMap(); request_body = crmAPIRequestMap.get("body"); info request_body; requestMap = request_body.toMap(); response = Map(); response.put("status_code",200); response.put("Content-Type","application/json"); hasRequests = requestMap.containKey("requests"); if(requestMap.containKey("requests") && requestMap.containKey("notifications")) < notificationMap = requestMap.get("notifications").toMap(); requestStr = requestMap.get("requests"); requestObj = requestStr.toMap(); response.put("body",); if(requestObj.containKey("request_status") && notificationMap.containKey("operation_type")) < operationType = notificationMap.get("operation_type"); //if(requestObj.get("request_status").equals("completed")) if(operationType.equals("RequestCompleted") || operationType.equals("RequestSigningSuccess") || operationType.equals("RequestRecalled") || operationType.equals("RequestRejected") || operationType.equals("RequestExpired")) < requestStatus = "Out for Signature"; if(operationType.equals("RequestCompleted")) < requestStatus = "Signed"; >else if(operationType.equals("RequestRecalled")) < requestStatus = "Recalled"; >else if(operationType.equals("RequestRejected")) < requestStatus = "Declined"; >else if(operationType.equals("RequestExpired")) < requestStatus = "Expired"; >requestId = requestObj.get("request_id"); //Check if already exists zsignrecord = zoho.crm.searchRecords("zohosign__ZohoSign_Documents","(zohosign__ZohoSign_Document_ID:equals:" + requestId + ")"); if(zsignrecord.size() > 0 && zsignrecord.get(0).containKey("zohosign__DeleteEdit_Preview_or_Position_Signature_Fields")) < info "Record already present"; response.put("body",); if(zsignrecord.get(0).get("zohosign__DeleteEdit_Preview_or_Position_Signature_Fields") == false) < //Needs to be updated zsrecordId = zsignrecord.get(0).get("id"); recordInfo = ; resp = zoho.crm.createRecord("zohosign__ZohoSign_Documents",zsrecordId,recordInfo); if(resp.containKey("id")) < response.put("body",); > > else < return ; > > else < response.put("body",); associatedModule = "Contacts"; associatedModuleKey = "zohosign__Contact"; actions = requestObj.get("actions"); email = actions.get(0).get("recipient_email"); records = zoho.crm.searchRecords("Contacts","(Email:equals:" + email + ")"); if(records.size() 0) < associatedModule = "Leads"; associatedModuleKey = "zohosign__Lead"; >> if(records.size() > 0) < info "Record found"; leadid = records.get(0).get("id"); recordInfo = ; //Create ZohoSign Record in CRM resp = zoho.crm.createRecord("zohosign__ZohoSign_Documents",recordInfo); if(resp.containKey("id")) < zsDocId = resp.get("id"); respDoc = zoho.sign.downloadDocument(requestId); zoho.crm.attachFile("zohosign__ZohoSign_Documents",zsDocId,respDoc); response.put("body",); //Create zoho sign recipients record for all recipients for each action in actions < recpStatus = "Waiting for Signature"; if(action.get("action_status").equals("SIGNED")) < recpStatus = "Signed"; >else if(action.get("action_status").equals("DECLINED")) < recpStatus = "Cancelled"; >recpRecordInfo = ; zoho.crm.createRecord("zohosign__ZohoSign_Recipients",recpRecordInfo); > > else < response.put("body",); > > > > else < response.put("body",); > > else < response.put("body",); > > else < info "Error"; response.put("body",); > return ; |