You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

JobPosting Schema JSON代码报错求助:缺失'}'或对象成员名

问题定位与修复方案

你的JSON代码存在两个关键语法错误,直接导致了解析失败:

  • 中文双引号误用:jobLocation对象里的“@type"使用了中文左双引号,JSON语法强制要求所有键名和字符串必须使用英文双引号,这个错误会让解析器无法识别合法的键名,从而抛出Missing '}' or object member name提示。
  • 未转义的换行符:description字段的字符串包含原生换行,JSON标准中字符串内的换行必须用\n转义,否则会触发语法错误。

修复后的完整代码

{
    "@context": "http://schema.org",
    "@type": "JobPosting",
    "title": "Varsity Squash Coach at Léman Manhattan Preparatory School",
    "description": "The responsibilities of the Head Coach include: \n\n\nOrganizing daily sessions taking attendance, communication with players and parents. \n\nProven ability to exemplify the highest standards of leadership, sportsmanship, and respect\n\nExcellent organizational skills and the ability to communicate effectively with all constituents\n\nWillingness and ability to work evenings as dictated by game schedule",
    "identifier": {
        "@type": "PropertyValue",
        "name": "Léman Manhattan Preparatory School",
        "value": "SG183"
    },
    "datePosted": "2022-09-12",
    "validThrough": "2022-11-11",
    "employmentType": "TEMPORARY",
    "hiringOrganization": {
        "@type": "Organization",
        "name": "Léman Manhattan Preparatory School",
        "sameAs": "https://www.lemanmanhattan.org/",
        "logo" : "https://v5.airtableusercontent.com/v1/7/7/1663804800000/NP8X2ipIaw46UWmRKjo34Q/f6dZOI2Z0GjagfFsHhf7KT28qq7EBvzKwvoSLV7XczwvLpCAjzo3yYYWQSJpeS8fx6jK89TlrnYRuJDBiHOv4g/l1QsKwP2dRMo_vZ_zqRZq8fUwCKJmHXDzgBTXkr5Iao"
    },
    "jobLocation": {
        "@type": "Place",
        "address": {
            "@type": "PostalAddress",
            "streetAddress": "41 Broad St",
            "addressLocality": "New York",
            "addressRegion": "NY",
            "postalCode": "10004",
            "addressCountry": "USA"
        }
    }
}

验证说明

将修复后的代码复制到结构化数据测试工具中,即可通过语法校验,同时确保所有字段符合JobPosting Schema的规范要求。

内容的提问来源于stack exchange,提问作者Fabien Sarran

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.19 18:15:48