When you use RTI Connector, all the types, topics, domain, and entities must be defined in an XML file that gets loaded when the Connector object is created.
For example, the following snippet loads the required definitions from "config.xml" and then instantiates a new Connector object for the domain participant "MyParticipant" defined in the participant library "MyParticipantLib"
const rti = require('rticonnextdds-connector');
var connector = new rti.Connector("MyParticipantLib::MyParticipant", "config.xml");