Function: WebService WSDL

DocumentService.wsdl

The WSDL file for the SOAP service is needed to define the API paramters and the API functions in it. This WSDL Should go unmodified with exception of the target URL in the bottom of this file. The plugin functions are defined to work with this WSDL file.

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<wsdl:definitions name="DocumentService"
	targetNamespace="https://programdesign.no/Documentservice/" 
	xmlns:soap="https://schemas.xmlsoap.org/wsdl/soap/" 
	xmlns:tns="https://programdesign.no/Documentservice/" 
	xmlns:wsdl="https://schemas.xmlsoap.org/wsdl/" 
	xmlns:xsd="https://www.w3.org/2001/XMLSchema">
	 <wsdl:documentation>
    Service: DocumentService
    Version: 1.0
    Owner: HORNEKS ANS
    Author: Ole Kristian Ek Hornnes
  </wsdl:documentation>
	<wsdl:types>
		<xsd:schema targetNamespace="https://programdesign.no/Documentservice/">
			<xsd:element name="Header">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="UN" type="xsd:string" />
						<xsd:element name="PW" type="xsd:string" />
						<xsd:element name="Key" type="xsd:string"  minOccurs="0" maxOccurs="1"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element name="GetDocumentParams">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="FileName" type="xsd:string" />
						<xsd:element name="Path" type="xsd:string" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element name="GetDocumentResponse">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="Status" type="xsd:string" />
						<xsd:element name="Message" type="xsd:string" />
						<xsd:element name="File" type="xsd:base64Binary"  minOccurs="0" maxOccurs="1"/>
						<xsd:element name="FileName" type="xsd:string"  minOccurs="0" maxOccurs="1"/>
						<xsd:element name="Type" type="xsd:string"  minOccurs="0" maxOccurs="1"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element name="SaveDocumentParams">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="FileName" type="xsd:string" />
						<xsd:element name="Path" type="xsd:string" />
						<xsd:element name="File" type="xsd:base64Binary" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
      
            <xsd:element name="SaveDocumentResponse">
            	<xsd:complexType>
            	 	<xsd:sequence>
          				<xsd:element name="Status" type="xsd:string"/>
         		 		<xsd:element name="Message" type="xsd:string"/>
    		     		<xsd:element name="FileName" type="xsd:string" minOccurs="0" maxOccurs="1"/>
	      			</xsd:sequence>
            	</xsd:complexType>
            </xsd:element>      
        </xsd:schema>
  </wsdl:types>
  <wsdl:message name="GetDocumentRequest">
    <wsdl:part element="tns:Header" name="Header"/>
    <wsdl:part name="GetDocument" element="tns:GetDocumentParams" />
  </wsdl:message>
  <wsdl:message name="GetDocumentResponse">
    <wsdl:part element="tns:GetDocumentResponse" name="body"/>
  </wsdl:message>
  <wsdl:message name="SaveDocumentRequest">
  	<wsdl:part name="Header" element="tns:Header"/>
  	<wsdl:part name="SaveDocument" element="tns:SaveDocumentParams" />
  </wsdl:message>
  <wsdl:message name="SaveDocumentResponse">
  	<wsdl:part name="body" element="tns:SaveDocumentResponse"/>
  	
  </wsdl:message>
  <wsdl:portType name="DocumentService">
  <wsdl:documentation>GetDocument and SaveDocument are get and store functions to OS level on target machine</wsdl:documentation>
    <wsdl:operation name="GetDocument">
      <wsdl:documentation>Retrieve document from document store. 
Given path and document name, return document or error codes
</wsdl:documentation>
      <wsdl:input message="tns:GetDocumentRequest"/>
      <wsdl:output message="tns:GetDocumentResponse"/>
    </wsdl:operation>
    <wsdl:operation name="SaveDocument">
    	<wsdl:documentation>Save documet back to store, given path, filename and file content (hexBinary) 
Return status if OK. </wsdl:documentation>
    	<wsdl:input message="tns:SaveDocumentRequest"/>
    	<wsdl:output message="tns:SaveDocumentResponse"/>
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:binding name="DocumentServicesSOAP" type="tns:DocumentService">
    <soap:binding style="document" transport="https://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="GetDocument">
      <soap:operation soapAction="GetDocument"/>
      <wsdl:input>
        <soap:header message="tns:GetDocumentRequest" part="Header" use="literal"/>
        <soap:body parts="GetDocument" use="literal"/>
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal"/>
      </wsdl:output>
    </wsdl:operation>
       <wsdl:operation name="SaveDocument">
      <soap:operation soapAction="SaveDocument"/>
      <wsdl:input>
         <soap:header message="tns:SaveDocumentRequest" part="Header" use="literal"/>
        <soap:body parts="SaveDocument" use="literal"/>
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal"/>
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:service name="DocumentServices">
    <wsdl:documentation>A document exchange service for use in other systems
that require access to given documents. As an alternative to OS-level document copy operations
(Volume not available issues, etc)</wsdl:documentation>
    <wsdl:port binding="tns:DocumentServicesSOAP" name="DocumentServicesSOAP">
      <soap:address location="https://horneks.no/ws/doc/"/>
    </wsdl:port>
  </wsdl:service>
</wsdl:definitions>