Create Midi Port with MBS

I just buy MBS Audio plugin and taking a look the sample code.

I need to create my own MidiPort with Output and Input. Is there a way to do this ?

for macOS?
See MidiClientMBS class, where you can create virtual sources or destinations.