To set up the AlarmPoint Java Client to send messages to the xMatters Node, inspect the “APAgent.xml” file located in the “etc” subfolder of the k installation directory. The mode attribute of the <alarmpoint-agent> tag should be “enterprise”:
<alarmpoint-agent version="1.0" mode="enterprise">
Add the following as a child of the <alarmpoint-agent> XML tag:
<alarmpoint-agent-client id="HelloWorld" filename="integrations/HelloWorld.xml" />
To call the new Event Domain from the k, create a new XML integration file named “HelloWorld.xml” in the “etc/integrations” subfolder of the k installation directory. The following code illustrates a sample integration file:
<?xml version="1.0" encoding="UTF-8"?>
<alarmpoint-agent-client id="HelloWorld">
<mapped-input method="add" subclass="action">
<parameter index="1" type="string">action_script_set</parameter>
<parameter index="2" type="string">person_or_group_id</parameter>
<parameter index="3" type="string">incident_id</parameter>
</mapped-input>
<input-action name="Add Action" method="Add" subclass="Action">
<module type="filter">
<configuration>
<filters />
</configuration>
</module>
</input-action>
<input-action name="Add" method="Add">
<module type="filter">
<configuration>
<filters />
</configuration>
</module>
</input-action>
</alarmpoint-agent-client>
The integration file expects three parameters: the action script name (“HelloWorld”), the person/group (“companyadmin”), and an incident ID that should be unique each time a message is sent.
Stop and then restart the k. Ensure that the application can successfully connect to the xMatters Node.
Next topic: Testing the example script