AnsweredAssumed Answered

consumo de un webservice de alfresco

Question asked by carlosalvet on Nov 3, 2010
Latest reply on Nov 4, 2010 by rmonteiro
Actualmente me encuentro en un proyecto que se encuentra desarrollado con Alfresco, este web service solo nos pasaron la api y nos digeron,el sdk contenia ejemplos y que de alli lo podiamos consumir pero

no le entiendo nada!

jajaj, es la operacion de createUser, e

¿es necesario usar el sdk par que el webservice me de acceso a consumirlo?

esta es la direccion del webservice

<wsdlsoap:operation soapAction="http://www.alfresco.org/ws/service/administration/1.0/createUsers'/>

en resumidas cuentas este es el webservice


Los tipos estan concentrados en 2 archivos el principal wsdl, donde esta todo y un types.xsd que nunca habia visto que le hicieran asi.

Types

         <complexType name="UserDetails">
            <sequence>
               <element name="userName" type="xsd:string"/>
               <element name="properties" type="cms:NamedValue" maxOccurs="unbounded" minOccurs="0"/>
            </sequence>
         </complexType>
         <element name="UserDetails" type="admin:UserDetails"/>

         <complexType name="NewUserDetails">
            <sequence>
               <element name="userName" type="xsd:string"/>
               <element name="password" type="xsd:string"/>
               <element name="properties" type="cms:NamedValue" maxOccurs="unbounded" minOccurs="0"/>
            </sequence>
         </complexType>
         <element name="NewUserDetails" type="admin:NewUserDetails"/> 

         <element name="createUsers">
            <complexType>
               <sequence>
                  <element name="newUsers" type="admin:NewUserDetails" maxOccurs="unbounded" minOccurs="0"/>
               </sequence>
            </complexType>
         </element>

         <element name="createUsersResponse">
            <complexType>
               <sequence>
                  <element name="result" type="admin:UserDetails" maxOccurs="unbounded" minOccurs="0"/>
               </sequence>
            </complexType>
         </element>



–types.xsd   

   <xsd:simpleType name="Name">
        <xsd:annotation>
           <xsd:documentation>TODO: Define constraints</xsd:documentation>
        </xsd:annotation>
        <xsd:restriction base="xsd:string">
         <xsd:minLength value="1"/>
      </xsd:restriction>
   </xsd:simpleType>

    <xsd:complexType name="NamedValue">
       <xsd:sequence>
          <xsd:element name="name" type="cms:Name"></xsd:element>
          <xsd:element name="isMultiValue" type="xsd:boolean" nillable="true"></xsd:element>
          <xsd:element name="value" type="xsd:string" nillable="true"></xsd:element>
          <xsd:element name="values" type="xsd:string" nillable="true" maxOccurs="unbounded" minOccurs="0"></xsd:element>
       </xsd:sequence>
    </xsd:complexType>
******************************************************************************************************************
.wsdl otra vez
<!– Message definitions –>

   <wsdl:message name="createUsersRequest">
      <wsdl:part element="admin:createUsers" name="parameters"/>
   </wsdl:message>

   <wsdl:message name="createUsersResponse">
      <wsdl:part element="admin:createUsersResponse" name="parameters"/>
   </wsdl:message>

<!– Port and binding definitions –>

      <wsdl:operation name="createUsers">
         <wsdl:documentation>Create new users with the details provided.</wsdl:documentation>
         <wsdl:input message="admin:createUsersRequest" name="createUsersRequest"/>
         <wsdl:output message="admin:createUsersResponse" name="createUsersResponse"/>
         <wsdl:fault message="admin:AdministrationFault" name="AdministrationFault"/>
      </wsdl:operation>

      <wsdl:operation name="createUsers">
         <wsdl:documentation>Create new users with the details provided.</wsdl:documentation>
         <wsdl:input message="admin:createUsersRequest" name="createUsersRequest"/>
         <wsdl:output message="admin:createUsersResponse" name="createUsersResponse"/>
         <wsdl:fault message="admin:AdministrationFault" name="AdministrationFault"/>
      </wsdl:operation>

      <wsdl:operation name="createUsers">
         <wsdlsoap:operation soapAction="http://www.alfresco.org/ws/service/administration/1.0/createUsers'/>
         <wsdl:input>
            <wsdlsoap:body use="literal"/>
         </wsdl:input>
         <wsdl:output>
            <wsdlsoap:body use="literal"/>
         </wsdl:output>

   <!– Service definition –>
   
    <wsdl:service name="AdministrationService">
       <wsdl:documentation>Administration service.</wsdl:documentation>
       <wsdl:port binding="admin:AdministrationServiceSoapBinding" name="AdministrationService">
          <wsdlsoap:address location="http://localhost:8080/alfresco/api/AdministrationService'/>
       </wsdl:port>
    </wsdl:service>


de antemano gracias!!

Outcomes