Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to call NetDocuments SOAP API by java?
    primarykey
    data
    text
    <p>I can call NetDocuments SOAP API by C# as following:</p> <pre><code>// Authenticate to the NetDocuments directory service ndDir.Directory ndDirectory = new ndDir.Directory(); ndDirectory.CookieContainer = new System.Net.CookieContainer(); // enable cookie handling ndDirectory.Login( username, password ); // Connect to the NetDocuments storage service ndStor.storage ndStorage = new ndStor.storage(); ndStorage.CookieContainer = ndDirectory.CookieContainer; // share cookies with the directory service XmlNode searchRes = ndStorage.Search( criteria, attrList ); </code></pre> <p>However, when I call NetDocuments SOAP API by java with Axis 1.4, I receive error: "No authentication session. The authentication session has timed out or was not established prior to this call."</p> <pre><code>DirectorySoapStub stubDir = new DirectorySoapStub(new URL("https://vault.netvoyage.com/ndApi/directory.asmx"), new DirectoryLocator()); StorageSoapStub stubSto = new StorageSoapStub(new URL("https://vault.netvoyage.com/ndApi/storage.asmx"), new StorageLocator()); stubSto.setMaintainSession(true); stubDir.login(username, password); javax.xml.soap.MimeHeaders mhds = stubDir._getCall().getMessageContext().getCurrentMessage().getMimeHeaders(); java.util.Iterator iterator = mhds.getAllHeaders(); while (iterator.hasNext()) { javax.xml.soap.MimeHeader mhd = (javax.xml.soap.MimeHeader)iterator.next(); if ("set-cookie".indexOf(mhd.getName()) &gt;= 0) { stubSto._setProperty(mhd.getName(), mhd.getValue()); } } stubSto.search(criteria, attrList); </code></pre> <p>Is there similar thing of CookieContainer in Java? How can I call NetDocuments SOAP API by java with Axis 1.4?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload