Features of the Messenger Extensions SDK available in the webview vary depending on what version of the Messenger bot the webview is opened in. For this reason, it is important to check that the feature you are using is available when the webview is opened.
To do this. you can call getSupportedFeatures()
to get an array of features that are supported on the current client. If a feature you depend on is not available, you can use this opportunity to fail gracefully with a message telling the user to upgrade.
The following Messenger Extensions SDK features are available in the webview:
기능 | 설명 |
---|---|
| 이 클라이언트에서 결제가 지원되는지 나타냅니다. |
| 이 클라이언트에서 |
| 이 클라이언트에서 |
| 오픈 그래프 메시지 공유 기능을 사용할 수 있습니다. |
|
|
For a complete list of method parameters, see the getSupportedFeatures() Reference.
MessengerExtensions.getSupportedFeatures(function success(result) { let features = result.supported_features; }, function error(err) { // error retrieving supported features });
getSupportedFeatures()
will return an array containing the featured supported in the current webview to the success callback. For details on the returned array values, see Features below.
{
"supported_features":[
"payments",
"context",
"sharing_broadcast",
"sharing_direct",
"sharing_open_graph"
]
}