facebookads

When creating Facebook ads through API, it prompts “enroll_status was not provided”


The question like https://developers.facebook.com/community/threads/1369234493639891/

I added the parameter standard_enhancements > enroll_status > OPT_OUT but I still failed to create an ad. Part of the request parameters are as follows:

{
  "object_story_spec": {
    "page_id": "xxxxx",
    "video_data": {
      "call_to_action": {
        "type": "INSTALL_APP",
        "value": {
          "link": ""
        }
      },
      "image_hash": "{result=videoThumbnailRequestxxxxxxxxxxxxx:$.images.*.hash}",
      "title": "",
      "video_id": "{result=videoRequestxxxxxxxxxxxxx:$.id}"
    }
  },
  "title": "test",
  "body": "test",
  "degrees_of_freedom_spec": {
    "creative_features_spec": {
      "standard_enhancements": {
        "enroll_status": "OPT_OUT"
      }
    }
  }
}

The error is as follows:

[
  {
    "error": {
      "message": "Invalid parameter",
      "type": "OAuthException",
      "code": 100,
      "error_subcode": 3858082,
      "is_transient": false,
      "error_user_title": "Creative Must Provide enroll_status for Standard Enhancements",
      "error_user_msg": "This creative is eligible for Standard Enhancements, but enroll_status was not provided. Please choose whether you want to turn on standard enhancements or not. Learn more here: https://fburl.com/hyth50xo",
      "fbtrace_id": "AZGGOCEVV3jyJ09T0SV0yXO"
    }
  },
  {
    "error": {
      "message": "Request aborted. This could happen if a dependent request failed or the entire request timed out.",
      "type": "FacebookApiException",
      "code": 960,
      "fbtrace_id": "A1m-jT3shoLxOqMFdVxhxdU"
    }
  }
]

https://developers.facebook.com/docs/marketing-api/advantage-catalog-ads/standard-enhancements


Solution

  • this issue has been fixed by the Meta. Please check if you encounter the same problem. You can verify by examining the sample request body below, it is working fine for me.

    {
        'name': 'test - Creative',
        'object_story_spec': {
            'page_id': '<page_id>',
            'link_data': {
                'description': '',
                'image_hash': '<image_hash>',
                'link': '<link>',
                'message': 'message',
                'name': 'headline',
                'call_to_action': {
                    'type': 'LEARN_MORE',
                    'value': {
                        'link': '<link>',
                        'link_caption': ''
                    }
                }
            }
        },
        'degrees_of_freedom_spec': {
            'creative_features_spec': {
                'standard_enhancements': {
                    'enroll_status': 'OPT_OUT'
                }
            }
        }
    }