Hi.
I'm Lauren Dunne, Senior Salesforce Evangelist
here at DocuSign and Salesforce MVP.
I'm joined today by Fred Wade, Director of Engineering.
And we're going to talk about the Apex Toolkit.
[MUSIC PLAYING]
Thanks for joining me, Fred.
Of course.
It's my pleasure.
So Fred, we met last year at Dreamforce 2018.
I love a good origin story.
How did it come About how did we create the Apex Toolkit?
So through my tenuring at DocuSign,
I've had the opportunity to speak very frequently with some
of our customers and partners.
I love talking tech with them.
I love getting feedback on our products.
One of the common things or questions we heard
were why can't DocuSign for Salesforce do this?
Why can't I integrate e-signature into to Process
Builder, for example.
Or why can't I keep a signature within my customer community?
And to be honest, we didn't really
have great answers for this.
With the launch of Salesforce Essentials in 2018,
we recognized the opportunity to streamline and simplify
our e-signature process.
And in that process, we created the Apex Toolkit.
So we built a clean object model and imported it over our code
from the older product.
We slapped the global modifier on some of our key classes.
And we built a very modern lightning first native
UI on top of that, proving that we
could build a fully functional e-signature solution on top
of the Apex Toolkit.
And now we're offering that to the rest
of our friends, our developers.
What different actions can be invoked
within the Apex Toolkit?
What can we do with it?
Yeah.
So the Apex Toolkit is primarily an e-signature solution.
So sending envelopes, retrieving envelope, status.
That's kind of our bread and butter with APEX tool kit.
There are also some interesting use cases
that we enable through the Apex Toolkit that
are not available in our prepackaged Salesforce
solutions.
So for example, bulk sending envelopes,
sending a copy of an envelope to a mailing list,
think sending a permission slip to a group
of parents for a field trip.
Or maybe something like embedded signing, so keeping
your customers or partners within your community
and allowing them to sign documents
from within that community.
Yep.
That's a big one.
So it's my favorite time of year.
Dreamforce 2019 is next week.
Do we have any sneak peeks that we can share?
Sure.
Very quick sneak peek.
We have something we're calling envelope multi-send, which is
distinct from our bulk sending.
The difference is you can send arbitrary envelopes
to a list of recipients in a single Apex
transaction, something that our customers have
asked for time and time again.
We'll be talking a lot more about this
at our breakout sessions at Dreamforce,
so definitely come visit us and check out our sessions.
Yep.
Can't wait.
So you've talked about it.
Can I see it?
Will you give us a demo?
Absolutely.
It would be my pleasure.
Excellent.
So I've already installed the Apex Toolkit
into my Salesforce org here.
So the first thing I'm going to do
is log into my DocuSign Developer Sandbox.
And let me complete the OF flow here.
And once it's complete, I'm ready to start coding.
So I'll select my account.
And now I am good to go.
So for this demonstration, I created a contact,
creatively named Apex Toolkit.
And on this contact, I attached a simple agreement,
again just for demonstration purposes.
I want to send this to my contact.
Cool.
All right.
So I'm going to switch over to developer console here.
And I've already put together the code here
but I'll walk through each step.
So I'm going to pass in my contact ID
that I just showed you.
And I'm going to let the Apex Toolkit do
all the heavy lifting.
So first I'm going to do is get an empty envelope
and link it to my contact.
Next I'm going to add documents that are linked to my contact.
Again, you can see here that I'm not actually
passing in a specific agreement ID or anything like that.
I'm going to add recipients.
In this case, it's again pointing to the contact.
So it's going to pull the contact details
and send it to them.
And I'm going to set the email subject and message
that I want to send.
Next thing I'm going to do is this method here called
Send Envelope, and I'm going to say send it now
instead of creating a draft.
And then going to print out the result of that,
which is the DocuSign assigned envelope ID.
And then I'm going to request status for my contacts.
And any envelopes attached to that contact record
will come back here.
In this case, I'm only asking for one in the first one.
And then I'm going to print out what the status was,
returned by the DocuSign API.
So let's see how that works.
So I'm just going to call my test method here.
Again, just passing in the contact
ID that I created previously.
Let's let the gears turn a little bit.
And here we go.
We can see the log output that I specified,
which is the DocuSign envelope ID and the status
of the envelope, which is sent, which
is exactly what I would hope.
Then we go to my inbox here and I
can see that I already received the email.
And it has my subject that I specified
plus the message I specified.
And I can go ahead and go through the DocuSIgn signing
experience that we all know and love.
Awesome.
Thank you.
So where can our audience go to access all the Apex Toolkit?
So I'd recommend you go to our developer center.
You can go to the developers.docus
ign.com/salesforce.
There we have complete reference documentation for the Apex
Toolkit as well as instructions on how
to install it, coding guides, and some code examples.
So for developers facing trouble with Apex Toolkit
or getting off the ground, where can they go to get some help?
Yeah.
So I think the first stop should be Stack Overflow.
That's where you get the quickest response.
Just make sure to tag your questions with DocuSign API.
We're also hosting a webinar on December 5th for the Apex
Toolkit.
And the link to that webinar for registration
will be in our video's description.
I'm so excited to get started with the Apex Toolkit.
Thank you so much, Fred, for sharing this amazing content.
And if you are ready to get going on the Apex Toolkit,
please check out the documentation on our developer
website.
The link is below in the description.
And please join us next month for the next Developer Deep
Dive.
If you liked that video, be sure to subscribe
to our channel for the latest DocuSign developer content.
If you want to see a specific topic in a future video,
comment below.
For everything else, visit the DocuSign Developer Center.
[MUSIC PLAYING]