{
  "title": "Remove duplicates from a JSON array",
  "human_url": "https://happytails.ai/en/developer-tools/json-array-unique/",
  "agent_url": "https://happytails.ai/agents/en/developer-tools/json-array-unique/",
  "language": "en",
  "markdown_url": "https://happytails.ai/en/developer-tools/json-array-unique.md",
  "content": "Remove duplicates from a JSON array\nKeep one copy of each distinct JSON value.\nHow can we improve this tool?\nReport a problem or share an idea.\nPlease leave out private information. Your message and the tool name go to our team via PostHog.\nHow to use Remove duplicates from a JSON array\nPaste a JSON array. Structural equality ignores the order of object keys, but keeps number and string types distinct. The first occurrence is retained.\nThe two objects collapse into one. The string \"1\" and number 1 both remain, because they have different types. Nested array order matters.\nUseful next steps\nSort JSON keys\nJSON formatter\nCSV remove duplicates\nHow to use it\nPaste a JSON array. Structural equality ignores the order of object keys, but keeps number and string types distinct. The first occurrence is retained.\nTry a small example\nThe two objects collapse into one. The string \"1\" and number 1 both remain, because they have different types. Nested array order matters.\nWhat to know\nKeeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.",
  "content_format": "text/plain",
  "visibility": "public",
  "links": [
    {
      "name": "Sort JSON keys",
      "url": "https://happytails.ai/en/developer-tools/json-key-sorter/"
    },
    {
      "name": "JSON formatter",
      "url": "https://happytails.ai/en/developer-tools/json-formatter/"
    },
    {
      "name": "CSV remove duplicates",
      "url": "https://happytails.ai/en/data-tools/csv-remove-duplicates/"
    }
  ],
  "tool": {
    "id": "json-array-unique",
    "category": "developer-tools",
    "built": true,
    "requirements": "Keeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.",
    "implementation": {
      "fields": [],
      "live": true,
      "note": "Keeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.",
      "experience": {
        "automatic": true,
        "single": false,
        "inputMaxLength": 1000000,
        "inputMode": "text",
        "label": "JSON",
        "placeholder": "{\"name\":\"Ada\",\"count\":2}",
        "help": "Use double-quoted property names and valid JSON values. Results update as you type. Up to 1,000,000 characters.",
        "action": null
      },
      "mode": "automatic",
      "interactive": false
    },
    "execution": "Browser interface",
    "api": null,
    "browser_agent": {
      "supported": true,
      "name": "run_current_tool",
      "discovery": "WebMCP on the human page in a supporting browser",
      "verification": "See audit/API-AUDIT.md; availability is not verification"
    }
  },
  "markdown": "# Remove duplicates from a JSON array\n\n- Human page: https://happytails.ai/en/developer-tools/json-array-unique/\n- Markdown: https://happytails.ai/en/developer-tools/json-array-unique.md\n- Structured JSON: https://happytails.ai/agents/en/developer-tools/json-array-unique/index.json\n- Visibility: public\n\n## Tool capabilities\n\n| Property | Value |\n| --- | --- |\n| Tool ID | `json-array-unique` |\n| Category | developer-tools |\n| Implementation | Registered implementation. Registration alone is not a production-quality guarantee. |\n| Browser execution | Automatic updates after valid input or file selection. |\n| Browser processing | Browser; see tool notes for network behavior. |\n| HTTP API | Not callable through HTTP. |\n| Browser-agent interface | run_current_tool |\n\n### Implementation notes\n\nKeeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.\n\n### Inputs and settings\n\nText input: JSON.\n\nExample or placeholder shown in the interface (not a validated fixture):\n\n```text\n{\"name\":\"Ada\",\"count\":2}\n```\n\nUse double-quoted property names and valid JSON values. Results update as you type. Up to 1,000,000 characters.\n\nNo additional settings are declared for this tool.\n\n### Browser-agent workflow\n\n1. Open the human page in a browser that supports WebMCP.\n2. Discover the interface exposed by that page; use its actual schema.\n3. Select files on the page first when the tool requires files.\n4. Call `run_current_tool` with valid input and settings.\n5. Inspect the returned result or error and the displayed output. Retrieve files from the displayed download links.\n\nCalls do not automatically copy or download results. Browser permissions still apply. Interface availability alone is not proof of successful execution.\n\n### Planning specification\n\nKeeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.\n\nThis describes intended requirements. Use the implementation notes, interface schema and observed output to determine current support.\n\n### Complete machine-readable capability record\n\n```json\n{\n  \"id\": \"json-array-unique\",\n  \"category\": \"developer-tools\",\n  \"built\": true,\n  \"requirements\": \"Keeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.\",\n  \"implementation\": {\n    \"fields\": [],\n    \"live\": true,\n    \"note\": \"Keeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.\",\n    \"experience\": {\n      \"automatic\": true,\n      \"single\": false,\n      \"inputMaxLength\": 1000000,\n      \"inputMode\": \"text\",\n      \"label\": \"JSON\",\n      \"placeholder\": \"{\\\"name\\\":\\\"Ada\\\",\\\"count\\\":2}\",\n      \"help\": \"Use double-quoted property names and valid JSON values. Results update as you type. Up to 1,000,000 characters.\",\n      \"action\": null\n    },\n    \"mode\": \"automatic\",\n    \"interactive\": false\n  },\n  \"execution\": \"Browser interface\",\n  \"api\": null,\n  \"browser_agent\": {\n    \"supported\": true,\n    \"name\": \"run_current_tool\",\n    \"discovery\": \"WebMCP on the human page in a supporting browser\",\n    \"verification\": \"See audit/API-AUDIT.md; availability is not verification\"\n  }\n}\n```\n\n## Page guide\n\nKeep one copy of each distinct JSON value.\n\nHow can we improve this tool?\n\nReport a problem or share an idea.\n\nPlease leave out private information. Your message and the tool name go to our team via PostHog.\n\n### How to use Remove duplicates from a JSON array\n\n1. Paste a JSON array. Structural equality ignores the order of object keys, but keeps number and string types distinct. The first occurrence is retained.\n2. The two objects collapse into one. The string \"1\" and number 1 both remain, because they have different types. Nested array order matters.\n\n## Useful next steps\n\n- [Sort JSON keys](https://happytails.ai/en/developer-tools/json-key-sorter/) ([Markdown](https://happytails.ai/en/developer-tools/json-key-sorter.md))\n\n- [JSON formatter](https://happytails.ai/en/developer-tools/json-formatter/) ([Markdown](https://happytails.ai/en/developer-tools/json-formatter.md))\n\n- [CSV remove duplicates](https://happytails.ai/en/data-tools/csv-remove-duplicates/) ([Markdown](https://happytails.ai/en/data-tools/csv-remove-duplicates.md))\n\n## How to use it\n\nPaste a JSON array. Structural equality ignores the order of object keys, but keeps number and string types distinct. The first occurrence is retained.\n\n### Try a small example\n\nThe two objects collapse into one. The string \"1\" and number 1 both remain, because they have different types. Nested array order matters.\n\n### What to know\n\nKeeps the first occurrence of each structurally equal JSON value. Object key order is ignored; array order and types matter. The first object’s original key order is kept.\n"
}