There isn't an official supported API. There are some community samples though which are developed by the Service Broker team or related teams in MS which you can use as a starting point, but they are not officially supported (you cannot call product support and report a bug):
- WCF Transport Channel for SQL Server Service Broker
- SQL Server Service Broker Product Samples
- Service Broker Interface (a .Net API for programming SSB, part of the samples linked above)