Clients and Relays can have a Primary and Secondary setting set via right-click on the endpoint under Computers.
These are represented by the following client settings:
In addition there is a setting that allows a list of Relays :
Finally a last restort fail-over setting:
Please see the following guide to creating settings via actionscript:
These settings are used in the following order:
Please see the following Relay guide:
Please see the following Relay Health guide: