BonjourDevAPIFinder lets you find your local development API servers automatically and choose it instead of the production API in run-time.
Objective-C Ruby JavaScript
Latest commit 89b255d Nov 28, 2014 @tkopczuk tkopczuk Improved comment.


Version License Platform


Switch to local network development server, discovered by Bonjour

Production to Development

Switch back to using the original API address

Development to Production


BonjourDevAPIFinder is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "BonjourDevAPIFinder"


To run the example project, clone the repo, and run pod install from the Example directory first.

Enabling Tweaks

BonjourDevAPIFinder uses Tweaks.

You need to make sure Tweaks have a way to be opened (see Tweaks docs).

Adding APIs

Anywhere in your project, before using an api address execute:

[BonjourDevAPIFinder.sharedInstance addApiService:@"API server"

identifier is the Bonjour advertised name for your service.

To retrieve currently chosen API address use:

[BonjourDevAPIFinder.sharedInstance apiAddressForIdentifier:@"example"

That's it!

Tip: you can add more than just one address.

Enabling the server to advertise it's existence


var mdns = require("mdns");
var ad = mdns.createAdvertisement(mdns.tcp(advertisedName), port);

Sample Bonjour-enabled node server project attached in the Server Example folder.


Tomek Kopczuk,

Swing Development


BonjourDevAPIFinder is available under the MIT license. See the LICENSE file for more info.