Hi All,

I am trying to add a policy(addPolicy) using Identity Server 5.4.0
Entitlement API as described in*[1]*. When compare the API with the
document it has many differences, so raised the doc Jira*[2]*.

But while having further look on this, I have a doubt whether this API is
correct since the content has lastModifiedTime, lastModifiedUser kind of
fields which are unnecessary for the request as I believe.
So I tried with the request content as mentioned in the document replacing
the actual one and it worked.
*Is this a bug in admin service?* what is the correct request for
*addPolicy?*

Below is the *addPolicy* operation according to the IS5.4.0 admin service

*<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/
<http://schemas.xmlsoap.org/soap/envelope/>"
xmlns:xsd="http://org.apache.axis2/xsd <http://org.apache.axis2/xsd>"
xmlns:xsd1="http://dto.entitlement.identity.carbon.wso2.org/xsd
<http://dto.entitlement.identity.carbon.wso2.org/xsd>">*
*    <soapenv:Header/>*
*    <soapenv:Body>*
*       <xsd:addPolicy>*
*          <!--Optional:-->*
*          <xsd:policyDTO>*
*             <!--Optional:-->*
*             <xsd1:active>?</xsd1:active>*
*             <!--Zero or more repetitions:-->*
*             <xsd1:attributeDTOs>*
*                <!--Optional:-->*
*                <xsd1:attributeDataType>?</xsd1:attributeDataType>*
*                <!--Optional:-->*
*                <xsd1:attributeId>?</xsd1:attributeId>*
*                <!--Optional:-->*
*                <xsd1:attributeValue>?</xsd1:attributeValue>*
*                <!--Optional:-->*
*                <xsd1:category>?</xsd1:category>*
*             </xsd1:attributeDTOs>*
*             <!--Optional:-->*
*             <xsd1:lastModifiedTime>?</xsd1:lastModifiedTime>*
*             <!--Optional:-->*
*             <xsd1:lastModifiedUser>?</xsd1:lastModifiedUser>*
*             <!--Optional:-->*
*             <xsd1:policy>?</xsd1:policy>*
*             <!--Optional:-->*
*             <xsd1:policyEditor>?</xsd1:policyEditor>*
*             <!--Zero or more repetitions:-->*
*             <xsd1:policyEditorData>?</xsd1:policyEditorData>*
*             <!--Optional:-->*
*             <xsd1:policyId>?</xsd1:policyId>*
*             <!--Zero or more repetitions:-->*
*             <xsd1:policyIdReferences>?</xsd1:policyIdReferences>*
*             <!--Optional:-->*
*             <xsd1:policyOrder>?</xsd1:policyOrder>*
*             <!--Zero or more repetitions:-->*
*             <xsd1:policySetIdReferences>?</xsd1:policySetIdReferences>*
*             <!--Optional:-->*
*             <xsd1:policyType>?</xsd1:policyType>*
*             <!--Optional:-->*
*             <xsd1:promote>?</xsd1:promote>*
*             <!--Optional:-->*
*             <xsd1:version>?</xsd1:version>*
*          </xsd:policyDTO>*
*       </xsd:addPolicy>*
*    </soapenv:Body>*
* </soapenv:Envelope>*

[1] https://docs.wso2.com/display/IS540/Entitlement+with+APIs
[2] https://wso2.org/jira/browse/DOCUMENTATION-7322

-- 
Thanks & Regards

*Chaminda Jayawardena*
Associate Technical Lead - QA
WSO2 Inc. - http://wso2.com
+94-77-7725234
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to