Below is how i am sending doc for sign i need to run AutoPlace on this attached doc but iam not able to make it work. This code is working but not placing autoplace that i had set in this template.
$client = new DocuSign\Rest\Client([
'username' => config("docusign.DOCUSIGN_USERNAME"),
'password' => config("docusign.DOCUSIGN_PASSWORD"),
'integrator_key' => config("docusign.DOCUSIGN_INTEGRATOR_KEY"),
]);
$templateRole = $client->templateRole([
'email' => <email>,
'name' => <name>,
'role_name' => 'Client',
]);
$envelopeDefinition = $client->envelopeDefinition([
'status' => 'sent',
'email_subject' => 'Signature Required On Your Order ',
'template_id' => '<docusign template id>',
'template_roles' => [
$templateRole,
],
]);
$doc = Storage::disk('local')->url('mypdf.pdf');
$envelopeOptions = $client->envelopes->createEnvelopeOptions([
'documents' => [
'documentBase64' => base64_encode($doc),
'name' => 'mypdf.pdf',
],
]);
$envelopeSummary = $client->envelopes->createEnvelope($envelopeDefinition, $envelopeOptions);
print_R($envelopeSummary);
die();
Can you please suggest me how can i add that code.. Thanks in advance.