MessengerExtensions.getSupportedFeatures()

Messenger 확장 기능 SDK

이 메서드는 Messenger 확장 기능 SDK의 일부입니다. 사이트에 SDK를 포함하는 데 관한 정보는 Messenger 확장 기능 SDK 추가를 참조하세요.

Contents

Method

MessengerExtensions.getSupportedFeatures(success, error)

Example

MessengerExtensions.getSupportedFeatures(function success(result) {
  let features = result.supported_features;
}, function error(err) {
  // error retrieving supported features
});

Parameters

Parameter Type Description

success

Function

Success callback function. Receives an array of features supported in the current webview.

error

Function

Error callback function. Called if Messenger was unable to retrieve supported features.

Returns

An object with the supported features is returned to the success callback.

{
  "supported_features":[
    "payments",
    "context",
    "sharing_broadcast",
    "sharing_direct",
    "sharing_open_graph"
  ]
}

Properties

Property Type Description

supported_features

Array<String>

A list of features supported in the current webview. For details, see Features

Features

The following values may be returned in the supported_features array:

기능설명

payments

이 클라이언트에서 결제가 지원되는지 나타냅니다.

sharing_broadcast

이 클라이언트에서 beginShareFlow()를 사용하여 방송 플로를 열 수 있습니다.

sharing_direct

이 클라이언트에서 beginShareFlow()를 사용하여 현재 대화에 공유 할 수 있습니다.

sharing_open_graph

오픈 그래프 메시지 공유 기능을 사용할 수 있습니다.

context

getContext()는 WebView에서 사용할 수 있습니다.