Page 1 of 1

Webservice-SOAP create document

Posted: Fri Feb 08, 2019 5:09 pm
by kentorkskie
I am able to integrate LD(8.2) with my custom application, the issue i have is with creating document with my custom application, the document is created successfully, but the infromation passed using name and stringValue of the attributes Parameter are not passed to the form.
I have attached a screen shot, i dont know if there is something i am during differently. the pdf version of the form is created successfully, but the stringValue are not passed to the form

public function createDocument(){

$authClient = new \SoapClient ('http://xx.x.xx.xxx:8080/services/Auth?wsdl' );
$session_id = $authClient->login (['username' => 'xxxx', 'password' => 'xxxxxxx']);


$formClient = new SoapClient ('http://10.1.13.250:8080/services/Form?wsdl');
$results = $formClient->createDocument(['sid'=>$session_id->return,'formId'=>3358365,
'doc'=>[
'fileName'=>'Kehinde Adedipe',
'creatorId'=>0,
'id'=>0,
'immutable'=>0,
'indexed'=>0,
'nature'=>0,
'pages'=>-1,
'published'=>1,
'publisherId'=>0,
'signed'=>0,
'stamped'=>0,
'status'=>0,
'exportStatus'=>1,
'fileSize'=>0,
'language'=>'en',
'folderId'=>3313774,
'attributes'=>[
['name'=>"surnamebio", 'stringValue'=>'Jesse', 'mandatory'=>0,'position'=>0,'type'=>0,'editor'=>0],
['name'=>"firstnamebio",'stringValue'=>'Ademola','mandatory'=>0,'position'=>2,'type'=>0, 'editor'=>1]
]

]
]);

Re: Webservice-SOAP create document

Posted: Tue Feb 12, 2019 4:53 pm
by agaspa
Hi kentorkskie,
I tested the method with LD 8.1.1 and it seems to work correctly.

Keep in mind that in the doc array you must specify the templateId element
Without this element the system will not be able to find the template of the document and store the attribute values

See example in attachment
Br.
Alex