Insert a Business Agreement

To create a new business agreement:

1. Select the Project tab in TIBCO Business Studio.
2. Select project_name > INIT_REQ > write > op_insertbizagreement.

The process for insertbizagreement opens in the design window.

3. Select the resource ReadFile.
4. Select the Input tab.

In the Activity Input window, the fileName parameter shows which sample file is used for this operation: INSERTBusinessAgreementREQ.xml listed in GlobalVariables/CMI/cmi.doc.path.

5. To edit the sample XML file, go to BCCE_HOME\protocols\cmi\examples\SampleDocs\ INSERTBusinessAgreementREQ.xml.
6. Open the file with a text editor.

INSERTBusinessAgreementREQ.xml is as follows:

<?xml version="1.0" encoding="UTF-8" ?> 
- <INSERTBusinessAgreementREQ xmlns="http://www.tibco.com/AX/BC/CMI"    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"    xsi:schemaLocation="http://www.tibco.com/AX/BC/CMI../../src/com/tibco/ ax/cmi/resource/cmipayload.xsd">
<BizAgreement partner="Partner1" host="Host" validStart="2012-05-01" validEnd="2014-01-01" />
</INSERTBusinessAgreementREQ>
7. Modify the sample file so that it contains the appropriate information about the Host and the Partner (Host and Partner1)
8. Edit the dates when the agreement starts and end.
9. Save the sample file.
10. In the opened TIBCO Business Studio project, click the dropdown icon next to the BWApplication icon.
11. In the Run Configurations dialog, expand BusinessWorks Application > BWApplication.

The Select Processes to Load dialog appears.

12. Select the process op_insertbizagreement and click on Load and Start Current.
13. The process is executed.
If the operation is successful, you can see the Business Agreement Host-Partner1 added to the BusinessConnect Container Edition Admin Server under Partner Management> Business Agreements.
If the operation is not successful:

You can debug it in TIBCO Business Studio by checking the output tab of the SendRequest activity in op_instertbizagreement process.

Check the response file that has been created in the logs folder (path is provided for the global variable cmi.log.path).

You can also use the Log Viewer function in BusinessConnect Container Edition Admin Server to see the summary of this operation, including the failure causes.

To learn more about viewing audit logs, see Viewing Logs.