facebook-graph-apifacebook-workplace

This resource is not available for Workplace applications in Facebook Graph API


I want to search user by name in the workplace integration. So I'm using graph API and sending this request

GET  https://graph.facebook.com/search?q=jay&type=user&access_token={access_token}&appsecret_proof={sha256 hash of access token and app secret}

But it gives me an error saying

{
  "error": {
      "message": "(#3) This resource is not available for Workplace applications.",
      "type": "OAuthException",
      "code": 3,
      "fbtrace_id": "D7Zu8E7sIkY"
  }
}

Somebody, please help me, My aim is to find the user's information by their name instead of email id or user id.

P.S. I've given all the permissions to my integration. enter image description here


Solution

  • in workplace you can't search users by name, but only by id or email address.

    In order to search a user by email the call is

    GET /scim/v1/Users?filter=userName%20eq%20%22juliusc@example.com%22 HTTP/1.1
    Host: www.facebook.com 
    Authorization: Bearer {your access token}