Take a look here: XML Reference Guide
That shows you how you can set the XML so that a user can add the reference in the Modeler.
And what you can do is check other widgets on GitHub for some good code examples.
Try the RadioButtonList widget for example.