Sample XML service request: Add product instance with spec

The AttributeValueBObj/Value element must be placed in CDATA to prevent them from being parsed by the request parser.

<?xml version="1.0" encoding="UTF-8"?>
<TCRMService xmlns="http://www.ibm.com/mdm/schema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ibm.com/mdm/schema MDMDomains.xsd">
    <RequestControl>
        <requestID>800001</requestID>
        <DWLControl>
            <requesterName>cusadmin</requesterName>
            <requesterLanguage>100</requesterLanguage>
        </DWLControl>
    </RequestControl>
    <TCRMTx>
        <TCRMTxType>addProductInstance</TCRMTxType>
        <TCRMTxObject>FinancialProductBObj</TCRMTxObject>
        <TCRMObject>
            <FinancialProductBObj>
                <ProductTypeId>713119747765799789</ProductTypeId>
                <Name>Financial loan</Name>
                <ProductStructureType>100001</ProductStructureType>
                <ProductStructureValue>Structure 01</ProductStructureValue>
                <ProductSpecValueBObj>
                    <SpecFormatId>11</SpecFormatId>
                    <EndDate>2015-01-01</EndDate>
                    <AttributeValueBObj>
                        <Value><![CDATA[
						              <prodspec:LoanProductSpec xmlns="http://www.ibm.com/mdm/data/specs
                              /LoanProductSpec/internal/00000001"
                              xmlns:prodspec="http://www.ibm.com/mdm/data/specs/LoanProductSpec
                              /internal/00000001"> 
													   <LoanPurpose>1</LoanPurpose>
													   <RateType>1</RateType>
													   <TermOptions>9</TermOptions>
													   <PaymentFrequencyType>2</PaymentFrequencyType>
													   <PrepayPenaltyAmount>500</PrepayPenaltyAmount>
													   <MinimumCreditAmount>1000</MinimumCreditAmount>
													   <MaximumCreditAmount>1000000</MaximumCreditAmount>
													   <SetUpFee>150</SetUpFee>
													   <InterestRate>5</InterestRate>
													</prodspec:LoanProductSpec>
												]]&gt;</Value>
                    </AttributeValueBObj>
                </ProductSpecValueBObj>
                <FinancialProductLastUpdateDate/>
            </FinancialProductBObj>
        </TCRMObject>
    </TCRMTx>
</TCRMService>

Response format – success

A transaction returns either a successful or failed response.

A successful transaction returns a successful result code along with its business objects. The response content under AttributeValueBObj/Value can be wrapped with CDATA based on the configuration setting.

When the CDATA configuration setting is set to OFF, the response format is as follows:

<?xml version="1.0" encoding="UTF-8"?>
<TCRMService xmlns="http://www.ibm.com/mdm/schema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ibm.com/mdm/schema MDMDomains.xsd">
	<ResponseControl>
		<ResultCode>SUCCESS</ResultCode>
		<ServiceTime>886</ServiceTime>
		<DWLControl>
			<requesterLanguage>100</requesterLanguage>
			<requesterLocale>en</requesterLocale>
			<requesterName>cusadmin</requesterName>
			<requestID>800001</requestID>
		</DWLControl>
	</ResponseControl>
	<TxResponse>
		<RequestType>addProductInstance</RequestType>
		<TxResult>
			<ResultCode>SUCCESS</ResultCode>
		</TxResult>
		<ResponseObject>
			<FinancialProductBObj>
				<DWLStatus>
					<Status>0</Status>
				</DWLStatus>
				<ComponentID>4130</ComponentID>
				<ProductId>281119747809265858</ProductId>
				<ProductTypeId>713119747765799789</ProductTypeId>
				<Name>Financial loan</Name>
				<ProductStructureType>100001</ProductStructureType>
				<ProductStructureValue>Structure 01</ProductStructureValue>
				<ProductLastUpdateDate>2007-12-12 11:48:12.658</ProductLastUpdateDate>
				<ProductLastUpdateUser>cusadmin</ProductLastUpdateUser>
				<ProductLastUpdateTxId>805119747809203547</ProductLastUpdateTxId>
				<ProductSpecValueBObj>
					<ComponentID>4117</ComponentID>
					<ProductSpecValueId>762119747809272976</ProductSpecValueId>
					<SpecId>1</SpecId>
					<SpecFormatId>11</SpecFormatId>
					<ProductId>281119747809265858</ProductId>
					<StartDate>2007-12-12 11:48:12.037</StartDate>
					<EndDate>2015-01-01 00:00:00.0</EndDate>
					<ProductSpecValueLastUpdateDate>
             2007-12-12 11:48:12.73
           </ProductSpecValueLastUpdateDate>
					<ProductSpecValueLastUpdateUser>cusadmin</ProductSpecValueLastUpdateUser>
					<ProductSpecValueLastUpdateTxId>
             805119747809203547
           </ProductSpecValueLastUpdateTxId>
					<AttributeValueBObj>	
						<Value>&lt;prodspec:LoanProductSpec xmlns:prodspec=
               &quot;http://www.ibm.com/mdm/data/specs/LoanProductSpec
               /internal/00000001&quot;xmlns=&quot;http://www.ibm.com/mdm/data/specs
               /LoanProductSpec/internal/00000001&quot;&gt;&lt;LoanPurpose&gt;1&lt;
               /LoanPurpose&gt;&lt;RateType&gt;1&lt;/RateType&gt;&lt;TermOptions&gt;9&lt;
               /TermOptions&gt;&lt;PaymentFrequencyType&gt;2&lt;
               /PaymentFrequencyType&gt;&lt;PrepayPenaltyAmount&gt;500&lt;
               /PrepayPenaltyAmount&gt;&lt;MinimumCreditAmount&gt;1000&lt;
               /MinimumCreditAmount&gt;&lt;MaximumCreditAmount&gt;1000000&lt;
               /MaximumCreditAmount&gt;&lt;SetUpFee&gt;150&lt;
               /SetUpFee&gt;&lt;InterestRate&gt;5&lt;/InterestRate&gt;&lt;
               /prodspec:LoanProductSpec&gt;
             </Value>
					</AttributeValueBObj>
					<DWLStatus>
						<Status>0</Status>
					</DWLStatus>
				</ProductSpecValueBObj>
				<FinancialProductLastUpdateDate>
           2007-12-12 11:48:12.825
         </FinancialProductLastUpdateDate>
			</FinancialProductBObj>
		</ResponseObject>
	</TxResponse>
</TCRMService>

When the CDATA configuration setting is set to ON, the response format is as follows:

<?xml version="1.0" encoding="UTF-8"?>
<TCRMService xmlns="http://www.ibm.com/mdm/schema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ibm.com/mdm/schema MDMDomains.xsd">
	<ResponseControl>
		<ResultCode>SUCCESS</ResultCode>
		<ServiceTime>886</ServiceTime>
		<DWLControl>
			<requesterLanguage>100</requesterLanguage>
			<requesterLocale>en</requesterLocale>
			<requesterName>cusadmin</requesterName>
			<requestID>800001</requestID>
		</DWLControl>
	</ResponseControl>
	<TxResponse>
		<RequestType>addProductInstance</RequestType>
		<TxResult>
			<ResultCode>SUCCESS</ResultCode>
		</TxResult>
		<ResponseObject>
			<FinancialProductBObj>
				<DWLStatus>
					<Status>0</Status>
				</DWLStatus>
				<ComponentID>4130</ComponentID>
				<ProductId>281119747809265858</ProductId>
				<ProductTypeId>713119747765799789</ProductTypeId>
				<Name>Financial loan</Name>
				<ProductStructureType>100001</ProductStructureType>
				<ProductStructureValue>Structure 01</ProductStructureValue>
				<ProductLastUpdateDate>2007-12-12 11:48:12.658</ProductLastUpdateDate>
				<ProductLastUpdateUser>cusadmin</ProductLastUpdateUser>
				<ProductLastUpdateTxId>805119747809203547</ProductLastUpdateTxId>
				<ProductSpecValueBObj>
					<ComponentID>4117</ComponentID>
					<ProductSpecValueId>762119747809272976</ProductSpecValueId>
					<SpecId>1</SpecId>
					<SpecFormatId>11</SpecFormatId>
					<ProductId>281119747809265858</ProductId>
					<StartDate>2007-12-12 11:48:12.037</StartDate>
					<EndDate>2015-01-01 00:00:00.0</EndDate>
					<ProductSpecValueLastUpdateDate>
             2007-12-12 11:48:12.73
           </ProductSpecValueLastUpdateDate>
					<ProductSpecValueLastUpdateUser>cusadmin</ProductSpecValueLastUpdateUser>
					<ProductSpecValueLastUpdateTxId>
             805119747809203547
           </ProductSpecValueLastUpdateTxId>
					<AttributeValueBObj>	
						<Value> <![CDATA[ <prodspec:LoanProductSpec xmlns:prodspec=
               “http://www.ibm.com/mdm/data/specs/LoanProductSpec
               /internal/00000001” xmlns”http://www.ibm.com/mdm/data/specs
               /LoanProductSpec/internal/00000001”><LoanPurpose>1<
               /LoanPurpose><RateType>1</RateType><TermOptions>9<
               /TermOptions><PaymentFrequencyType>2<
               /PaymentFrequencyType><PrepayPenaltyAmount>500<
               /PrepayPenaltyAmount><MinimumCreditAmount>1000<
               /MinimumCreditAmount><MaximumCreditAmount>1000000<
               /MaximumCreditAmount><SetUpFee>150<
               /SetUpFee><InterestRate>5</InterestRate><
               /prodspec:LoanProductSpec>]]&gt;
             </Value>
					</AttributeValueBObj>
					<DWLStatus>
						<Status>0</Status>
					</DWLStatus>
				</ProductSpecValueBObj>
				<FinancialProductLastUpdateDate>
           2007-12-12 11:48:12.825
         </FinancialProductLastUpdateDate>
			</FinancialProductBObj>
		</ResponseObject>
	</TxResponse>
</TCRMService>