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.Caller
depending 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 aCalleeApp
property with a hash of the app bridged to, andCalleeName
, 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 aToken
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 }
]
*/