【问题标题】:The following required properties are missing: og:url, og:type, og:title, og:image, og:description, fb:app_id缺少以下必需属性:og:url、og:type、og:title、og:image、og:description、fb:app_id
【发布时间】:2026-02-16 14:55:02
【问题描述】:

我们正在使用Facebook Share Debugger 测试https://www.roadgoat.com 的开放图形标签。 我们不断收到错误消息:The following required properties are missing: og:url, og:type, og:title, og:image, og:description, fb:app_id

我们已经尝试过上述解决方案,例如:

  • 确保任何标签都没有重复条目
  • 使用图片的http版本而不是https
  • 检查每个条目以确保没有问题
  • 添加 og:locale
  • 确保 SSL 有效

我还测试了我们的 JS 站点和页面 https://www.roadgoat.com?_escaped_fragment_= 的预渲染版本,但在这两种情况下仍然存在问题。除了 Facebook 之外,它似乎在我测试的任何网站上都通过了。

我还检查了See exactly what our scraper sees for your URL,我看到了所有标签,正如预期的那样

【问题讨论】:

    标签: facebook facebook-graph-api facebook-opengraph facebook-sharer


    【解决方案1】:

    来自您的网站:

    <meta content='{{metadata.description}}' name='description' ng-if='metadata.description'>
    <meta content='en_US' property='og:locale'>
    <meta content='519642741544020' property='fb:app_id'>
    <meta content='{{og_meta.type}}' ng-if='og_meta.type' property='og:type'>
    <meta content='{{og_meta.url}}' ng-if='og_meta.url' property='og:url'>
    <meta content='{{og_meta.title}}' ng-if='og_meta.title' property='og:title'>
    <meta content='{{og_meta.image}}' ng-if='og_meta.image' property='og:image'>
    <meta content='{{og_meta.image_width}}' ng-if='og_meta.image_width' property='og:image:width'>
    <meta content='{{og_meta.image_height}}' ng-if='og_meta.image_height' property='og:image:height'>
    <meta content='{{og_meta.description}}' ng-if='og_meta.description' property='og:description'>
    <meta content='RoadGoat' property='og:site_name'>
    

    该网站呈现的是标签而不是值,Facebook 没有任何问题! og:urlog:image 等某些内容值无效,调试器会针对这些值抛出错误。

    【讨论】:

    • 但是我在一个预先渲染了所有值的页面上遇到了同样的错误。尝试输入这个网址,看看我的意思:roadgoat.com?_escaped_fragment_=
    • Facebook 也可以渲染 JS。这正是 Facebook 看到的:developers.facebook.com/tools/debug/echo/…
    • 我能发现您的网站和社交媒体目标网站之间的唯一区别是属性和内容的位置位置,(它们首先具有属性,然后是内容)。您的 og: 属性被检测为自动(并且它们是正确的),该站点将在 Facebook 上看起来与预期一样。如果您即将发布某些内容,请稍后修复警告。你能改变属性和内容的位置吗?