+ Start a Discussion
Pras MPras M 

Docusign and salesforce customization

I would like to send a dousign document from an external system but still want to track the docusign status and recipient status back in Sf. I configured the docusign& sf connection and tested it out, I see the docusign status come back to sf but is missing the account association, the signed docs are published back on the correct account but the Docusgin status which has an account and contact look up is missing,

Any direction on how to code to make the association?
Swiderski, ErikSwiderski, Erik
You'll probably need something in the docusign envelope data that you can use to lookup the account. We send our docusign envelopes in salesforce from a custom object record. The docusign object has a lookup relationship to this custom object. This step is already checked off for you if you are relating to an account.

Login to DocuSign, go to admin, open your salesforce connect settings, edit the docusign status object. Go down to the fields under "Update"
For us, the salesforce field on the left side is the field on the docusign status object that relates to the custom object. I'm mostly sure that this field has to be passed a record id and nothing else. The right side is "Envelope External ID" -since we send the docusign envelope from the the same record we want to relate the docusign status to, we get the record id when sending and store it in the envelope external id on the docusign envelope. Once created, it will relate to the record automatically.

If by some off chance you can include the salesforce account id when you send from the external system, you are golden. If not, you may need to use a trigger on the docusign recipient status record to query the contact object by email address, and then get its AccountId to then update the Account field on the docusign status record. Haven't tried it, but maybe you could accomplish the same thing with process builder.
Pras MPras M
Swiderski Erik,

Thanks for the thought process around the trigger.

I currently wrote a trigger on Dosuign status object this is what I did & works well:
1. Created a custom field on docusign status with the same field name as that on the Account.
2. When ever this field on Docusign status is populated with the same value as that on the account, I am associating it with the approproate account.

What I am struggling with is to update this field on docusign status from an external system using Docusign itself. meaning, I created a custom field on Docusign enveloped and mapped this field to Docusign custom field in salesforce in docusign <> sf configuration. But this data when inputted from the envelope is not coming though into salesforce.

I am not sure how we can accomplish this!!

Swiderski, ErikSwiderski, Erik
A code snippet would be very helpful here. Without it, I'm just guessing at this point:

How are you sending your DocuSign envelopes? Are they being sent directly from the docusign website or from another system that has an api integration with DocuSin (i.e., like how you can send docusign envelopes from salesforce via the api).

Start with looking at the envelope data in docusign. Not sure if you can see it from the same page that you view your envelopes, you may have to either enable debug logging in docusign settings, or export the envelope details to csv -either way you're ultimately trying to look at the data that the docusign envelope carried with it, including that custom field to see if the data inputted during the envelope send made it. If it did, then you know to check how that field is mapped to the docusign status object record in salesforce.