How to create defect programmatically
One answer
Take a look at Ralph's blog post on getting started with RTC APIs https://rsjazz.wordpress.com/2015/09/30/learning-to-fly-getting-started-with-the-rtc-java-apis/ - It's a great starting point for understanding the APIs and how to use them create things in EWM.