Account
I am a
Developer
Product(s)
Earned badges
Achievement: Latest Unlocked
Preferences
Replies
Topics Started
Topic Started
Topics |
---|
Hello,
I have added signer SMS verification before sign of document. It show SMS sent. but user don't receive any SMS.
|
Hello,
Once all user sign the document, everyone get mail of signing completed & download the document link via email.
So my question is, I want to disable download email notifications to any si
|
Hello,
I am creating package. After that I am writing data in that PDF via fields extraction. And downloading that PDF that is written.
|
Hello,
I am uploading PDF via REST API PHP, along with signer users.
|
Hello,
I am using PHP REST API.
First i create draft package, then upload form with data, and then publish it. But there is disclosure electronic signatures document get created.
|
Replies Created
Reply to: create package from already created template with sign field & assign to signer
Wednesday, August 8, 2018 at 12:46amHello, I managed to create a package from template & updated the placeholder details with new signer details to sign in an iframe.
Now I just need two things in the script as,
1. While creating signer role, I want to add attachment field for the recipient (optional)
2. After signer sign or decline the package, it should redirect to the next page in our web application for further process. means how to redirect to perticular URL after user sign the document.? redirect URL.
Below is my whole code for it attached
'Package created from template through REST API', 'description' => 'Package created with the eSignLive REST API', 'emailMessage' => 'This message should be delivered to all signers', 'autocomplete' => true, 'type' => 'PACKAGE', 'visibility' => 'ACCOUNT', 'due' => NULL, 'language' => 'en', 'status' => 'DRAFT', 'roles' => array ( 0 => array ( 'id' => $placeholderId, 'type' => 'SIGNER', 'signers' => array ( 0 => array ( 'id' => $placeholderId, 'firstName' => $firstName, 'lastName' => $lastName, 'email' => $email, ), ), 'name' => 'Signer', ), ), ); $packageJSON = json_encode($build); $packageId = json_decode($this->sendRequest($this->packageAppend . $templateId . '/clone', $packageJSON, NULL, 'application/json'), true); return $packageId; } //Send Package public function buildSend($packageId) { $build = array( 'status' => 'SENT' ); $sendJSON = json_encode($build); $this->sendRequest($this->packageAppend . $packageId['id'], $sendJSON, NULL, 'application/json'); return NULL; } //Sender signs consent and contract documents public function buildSign($packageId) { $build = array( 'documents' => array( array( 'id' => 'contract', 'name' => 'GRENKE Contract' ) ) ); $signJSON = json_encode($build); $signatureAppend = $this->packageAppend . $packageId['id'] . '/documents/signed_documents'; $this->sendRequest($signatureAppend, $signJSON, NULL, 'application/json'); return NULL; } //Get a session token public function buildToken($packageId,$placeholderId) { $build = array( 'packageId' => $packageId['id'], 'signerId' => $placeholderId ); $tokenJSON = json_encode($build); $token = json_decode($this->sendRequest($this->tokenAppend, $tokenJSON, NULL, 'application/json'), true); return $token; } //cURL function to send requests to eSignLive private function sendRequest($type, $json, $document, $contentType) { if (is_null($document) && is_null($contentType)) { $postfields = array( "payload" => $json ); } else if (is_null($document) && !is_null($contentType)) { $postfields = $json; } else { $postfields = $document; } $headerOptions = array( 'Authorization: Basic ' . $this->key, 'Accept: application/json,application/zip,text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8' ); if (!is_null($contentType)) { $headerOptions[] = "Content-Type: $contentType"; } $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $this->url . $type); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_FAILONERROR, true); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); if (!is_null($postfields)) { curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields); if (!is_array($postfields)) { $headerOptions[] = 'Content-Length: ' . strlen($postfields); } } curl_setopt($ch, CURLOPT_HTTPHEADER, $headerOptions); $response = curl_exec($ch); $err = curl_error($ch); curl_close($ch); if ($err) { return $err; } else { return $response; }; } } ?>
Reply to: package status change to SENT issue
Tuesday, August 21, 2018 at 11:04amI think it is due to signature filed is not created for the PDF, may that's why it is unable to SENT status.
how to do in above code. I am following process as below for above code.
//create package $packageId = $package->buildPackage($application->id); //create document $package->buildDocument($packageId['id'],$application->id); //send the package $package->buildSend($packageId['id']); //create for sign $package->buildSign($packageId['id']); //create token for sign session $token = $package->buildToken($packageId['id'], $placeholderId);1. first creating draft package. 2. then uploading PDF with filling it. 3. then trying to make status SENT which gives error.
Reply to: package status change to SENT issue
Wednesday, August 22, 2018 at 04:29amI sent the document on mail, with a subject as this thread title.
Reply to: how to add text field in pdf, while creating package
Tuesday, October 30, 2018 at 03:42amokay. So I tried the solution you said. But then I got an error.
Here is the problem, according to my code logic, I am first creating draft package, with only roles. then after that I am uploading PDF with content depositions.
So, the problem, in the second i am unable to do “Position Extractionâ€. Is that possible in this setp?
Or I have to directly do both content deposition, “Position Extraction†& create package with PDF upload during buildPackage.?
Reply to: how to add text field in pdf, while creating package
Wednesday, October 31, 2018 at 01:55amHello,
So, I successfully integrated position extraction fields. but I am facing new issue. When I assign signature to user, so basically it has only 3 signature fields to be signed, but it show 4 signature due to which i am unable to submit form. it happen if i keep approval array. means postion extraction part. below is my code.
also attached screenshot.
public function buildDocument($packageId,$application_id) { $application = Application::find($application_id); $payment_term = PaymentTerm::where('application_id',$application->id)->first(); $director = unserialize($application->directors); $user = Auth::user(); $director_count = 1; $approvals = array(); $approvals[] = array ( 'fields' => array ( 0 => array ( 'type' => 'INPUT', 'extract' => true, 'subtype' => 'TEXTFIELD', 'name' => 'name_of_account', ), 1 => array ( 'type' => 'INPUT', 'extract' => true, 'subtype' => 'TEXTFIELD', 'name' => 'bsb_number', ), 2 => array ( 'type' => 'INPUT', 'extract' => true, 'subtype' => 'TEXTFIELD', 'name' => 'account_number', ), 3 => array ( 'type' => 'INPUT', 'extract' => true, 'subtype' => 'TEXTFIELD', 'name' => 'institution_name', ), 4 => array ( 'type' => 'INPUT', 'extract' => true, 'subtype' => 'TEXTFIELD', 'name' => 'institution_address1', ), 5 => array ( 'type' => 'INPUT', 'extract' => true, 'subtype' => 'TEXTFIELD', 'name' => 'institution_address2', ), ), 'role' => 'Signer1', ); $build = array( 'fields' => array( array( 'value' => $application->entity_name, 'name' => 'customer_name', ) , array( 'value' => $application->address, 'name' => 'customer_address', ) , array( 'value' => $application->phone, 'name' => 'telephone', ) , array( 'value' => $user->company_name, 'name' => 'supplier_name', ) , array( 'value' => $user->address, 'name' => 'supplier_address', ) , array( 'value' => $user->state.', '.$user->pincode, 'name' => 'supplier_address2', ) , array( 'value' => '', 'name' => 'email', ) , array( 'value' => $application->abn_number, 'name' => 'abn_number', ) , array( 'value' => $payment_term->installment, 'name' => 'installment', ) , array( 'value' => $payment_term->term, 'name' => 'month', ) , array( 'value' => $user->document_fee, 'name' => 'handling_fee', ) ) , 'approvals' => $approvals, 'extract' => true, 'name' => 'GRENKE - EQUIPMENT LEASE AGREEMENT FOR BUSINESS PURPOSES', 'id' => 'contract' ); if(isset($director[0]['f_name'])){ //directors $build['fields'][] = array( 'value' => $director[0]['f_name'].' '.$director[0]['l_name'], 'name' => 'director_name_1', ); } if(isset($director[1]['f_name'])){ $director_count = 2; $build['fields'][] = array( 'value' => $director[1]['f_name'].' '.$director[1]['l_name'], 'name' => 'director_name_2', ); } //items list 1st foreach ($application->items as $key => $value) { if(($key+1) == 5){ break; } $build['fields'][] = array( 'value' => $value->description, 'name' => 'item_'.($key+1), ); $build['fields'][] = array( 'value' => $value->quantity, 'name' => 'qty_'.($key+1), ); } //items list 2nd full if(count($application->items) > 4){ foreach ($application->items as $key => $value) { $build['fields'][] = array( 'value' => $value->description, 'name' => 'item_1_'.($key+1), ); $build['fields'][] = array( 'value' => $value->manufacturer, 'name' => 'manufacturer_1_'.($key+1), ); $build['fields'][] = array( 'value' => $value->quantity, 'name' => 'qty_1_'.($key+1), ); } } //items list 3rd if(count($application->items) items as $key => $value) { $build['fields'][] = array( 'value' => $value->description, 'name' => 'item_2_'.($key+1), ); $build['fields'][] = array( 'value' => $value->manufacturer, 'name' => 'manufacturer_2_'.($key+1), ); $build['fields'][] = array( 'value' => $value->quantity, 'name' => 'qty_2_'.($key+1), ); } }else{ //enter message to first row $build['fields'][] = array( 'value' => "Please see appendix", 'name' => 'item_2_1', ); $build['fields'][] = array( 'value' => "/equipment schedule.", 'name' => 'item_2_2', ); } $documentJSON = json_encode($build); if($director_count == 2){ $postdata = "--" . $this->MULTIPART_BOUNDARY . "\r\n"; $postdata .= "Content-Disposition: form-data; name=\"file\"; filename=\"application_pdf_form_d_2.pdf\"\r\n"; $postdata .= "Content-Type: application/pdf" . "\r\n\r\n"; $postdata .= file_get_contents(asset('upload/application_pdf_form_d_2.pdf')); $postdata .= "\r\n\r\n"; $postdata .= "--" . $this->MULTIPART_BOUNDARY . "\r\n"; $postdata .= "Content-Disposition: form-data; name=\"payload\"\r\n\r\n"; $postdata .= $documentJSON; $postdata .= "\r\n\r\n"; $postdata .= "--" . $this->MULTIPART_BOUNDARY . "--\r\n"; }else{ $postdata = "--" . $this->MULTIPART_BOUNDARY . "\r\n"; $postdata .= "Content-Disposition: form-data; name=\"file\"; filename=\"application_pdf_form_d_1.pdf\"\r\n"; $postdata .= "Content-Type: application/pdf" . "\r\n\r\n"; $postdata .= file_get_contents(asset('upload/application_pdf_form_d_1.pdf')); $postdata .= "\r\n\r\n"; $postdata .= "--" . $this->MULTIPART_BOUNDARY . "\r\n"; $postdata .= "Content-Disposition: form-data; name=\"payload\"\r\n\r\n"; $postdata .= $documentJSON; $postdata .= "\r\n\r\n"; $postdata .= "--" . $this->MULTIPART_BOUNDARY . "--\r\n"; } $status = $this->sendRequest($this->packageAppend . $packageId . '/documents', $documentJSON, $postdata, 'multipart/form-data; boundary=' . $this->MULTIPART_BOUNDARY); return $status; }
Subscriptions
Topics | Replies | Freshness | Views | Users |
---|---|---|---|---|
Hello,
I have added signer SMS verification before sign of document. It show SMS sent. but user don't receive any SMS.
|
3 | 5 years 2 months ago | 134 | |
Hello,
Once all user sign the document, everyone get mail of signing completed & download the document link via email.
So my question is, I want to disable download email notifications to any si
|
2 | 5 years 3 months ago | 92 | |
Hello,
I am creating package. After that I am writing data in that PDF via fields extraction. And downloading that PDF that is written.
|
1 | 5 years 4 months ago | 18 | |
Hello,
I am uploading PDF via REST API PHP, along with signer users.
|
6 | 5 years 4 months ago | 227 | |
Hello,
I am using PHP REST API.
First i create draft package, then upload form with data, and then publish it. But there is disclosure electronic signatures document get created.
|
1 | 5 years 5 months ago | 57 |
Subscriptions Release Notes
This user is not subscribed to any release notes.