You create an agent as a SWC file and link it into the Flex application by using the include-libraries compiler option. You can link multiple agents in any number of SWC files to the same Flex application. However, to use multiple agents at the same time, you must use the same environment configuration files for all agents.
The general process for creating a custom agent is:
The RECORD event handler in the agent gets an AutomationRecordEvent whose target is the object on which recording happened. The automationManager.createID() method converts the object to a string that can be recorded on the screen. Some tools may require the entire automation hierarchy that needs to be generated in this method.
You also use the custom agent class to enable and disable recording of automation events.
For more information on creating a custom agent, see Creating a recording agent.