getBridges()

This function allows your app to examine which bridges have been put in place.

Returns

An array of objects with aSide property that will be either: HC.Bridge.Callee or HC.Bridge.Callerdepending which side of the bridge the app is on.

  • If Side is Callerr, i.e. this is the app making calls over the bridge, then object will also contain a CalleeApp property with a hash of the app bridged to, and CalleeName, with the name of the app bridged to.

  • If Side is Callee, i.e. this is the app receiving calls over the bridge, then object will also contain a Token property with the value of the token that gives access to Caller app.

expand_less JS example
debug(JSON.stringify(getBridges()))
/*
[
  {"Side": 0, "CalleeName": "clutter", "CalleeApp": "QmY8Mzg9F69e5P9AoQPYat655HEhc1TVGs11tmfNSzkqto"},
  {"Token":"0393828348751323", "Side": 1 }
]
*/