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

请求提供移除JSON根元素的JOLT转换规则

JOLT 转换规范:移除根元素RootElement

以下是满足需求的JOLT Specification:

[
  {
    "operation": "shift",
    "spec": {
      "RootElement": ""
    }
  }
]

说明:

  • 使用shift操作类型,将输入中RootElement对应的数组直接映射到输出的根节点(空字符串""代表根层级),从而移除原有的根元素包装。

输入示例:

{
  "RootElement": [
    {
      "External_Contact_ID": "6504668",
      "Email_Address": "test@gmail.com",
      "First_Name": "Test_Name",
      "Last_Name": "TestLastName",
      "Member_STATUS": "ACTIVE"
    },
    {
      "External_Contact_ID": "6506709",
      "Email_Address": "test1@gmail.com",
      "First_Name": "Test_Name1",
      "Last_Name": "TestLastName1",
      "Member_STATUS": "ACTIVE"
    }
  ]
}

输出结果:

[
  {
    "External_Contact_ID": "6504668",
    "Email_Address": "test@gmail.com",
    "First_Name": "Test_Name",
    "Last_Name": "TestLastName",
    "Member_STATUS": "ACTIVE"
  },
  {
    "External_Contact_ID": "6506709",
    "Email_Address": "test1@gmail.com",
    "First_Name": "Test_Name1",
    "Last_Name": "TestLastName1",
    "Member_STATUS": "ACTIVE"
  }
]

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

相关产品推荐
方舟 Agent Plan

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

最近更新时间:2026.07.02 23:08:11