Purpose:
Allow integrations to discover the actions and features supported by the Host application
Sample Usage:
import host from '@elliemae/em-ssf-guest'
...
async function displayApplicationCapabilities() {
try {
const applicationObject = await host.getObject('application')
const applicationCapabilities = applicationObject.getCapabilities()
console.log(applicationCapabilities)
} catch (error) {
console.log({error})
}
}
displayApplicationCapabilities()
import host from '@elliemae/em-ssf-guest'
...
host.getObject('application')
.then(
(applicationObject) => {
const applicationCapabilities = applicationObject.getCapabilities()
console.log(applicationCapabilities)
}
)
.catch(
(error) => {
console.log({error})
}
)
Interface:
Input:
None
Returns:
Type: Object
An object containing supportedActions
and supportedFeatures
as array-valued attributes:
supportedActions
contains unique string-valued identifiers for each of the actions supported by the host application. The actions can be invoked via theperformAction
method exposed by theapplication
object.supportedFeatures
contains unique string-valued identifiers for the features exposed as functions on theapplication
objects interface, such asopen
andopenModal
.
{
supportedActions: ["getAvailableResources"],
supportedFeatures: ["open", "openModal"]
}