{
  "title": "API Enum Migration Mapper",
  "human_url": "https://happytails.ai/en/developer-tools/api-enum-migration-mapper/",
  "agent_url": "https://happytails.ai/agents/en/developer-tools/api-enum-migration-mapper/",
  "language": "en",
  "markdown_url": "https://happytails.ai/en/developer-tools/api-enum-migration-mapper.md",
  "content": "API Enum Migration Mapper\nMap the values of an old enum to a new one and see which values are unmapped, removed or new. Works with JSON Schema, OpenAPI, GraphQL, protobuf and plain lists.\nHow to use API Enum Migration Mapper\nPaste the old enum definition.\nPaste the new enum definition and choose how values are matched.\nAdd confirmed overrides for values that were renamed.\nRun the mapping and download the from,to CSV and the review table.\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.\nUseful next steps\nDataset value mapper\nJSON schema validator\nYAML to JSON\nAccepts up to 200,000 characters per definition and up to 10,000 values per enum. Matching is done in your browser. Downloads are two CSV files and a JSON report.\nMatching\nIdentical values of the same JSON type map exactly. Normalized matching also ignores letter case, spaces, dashes and underscores while preserving other punctuation and Unicode characters. When two new values could match, the old value is marked ambiguous instead of guessing. Distinct values in one enum that have identical CSV text, such as 1 and \"1\", are rejected because a two-column migration file cannot distinguish them. Overrides entered as from,to CSV win; an empty to marks a removed value.\nWhere enums are found\nFor JSON or YAML the tool uses the only enum array in the document, or the one your JSON Pointer names. For GraphQL SDL and .proto files it uses the only enum, or the one you name. A plain list uses one value per line.\nUsing the result\nThe from,to CSV contains only mapped values, ready for Dataset value mapper. The review CSV lists every old value with its status and every new value that nothing maps to. The tool builds the map; it does not change your data.",
  "content_format": "text/plain",
  "visibility": "public",
  "links": [
    {
      "name": "Dataset value mapper",
      "url": "https://happytails.ai/en/data-tools/dataset-value-mapper/"
    },
    {
      "name": "JSON schema validator",
      "url": "https://happytails.ai/en/developer-tools/json-schema-validator/"
    },
    {
      "name": "YAML to JSON",
      "url": "https://happytails.ai/en/data-tools/yaml-to-json/"
    }
  ],
  "tool": {
    "id": "api-enum-migration-mapper",
    "category": "developer-tools",
    "built": true,
    "requirements": "Accepts up to 200,000 characters per definition and up to 10,000 values per enum. Matching is done in your browser. Downloads are two CSV files and a JSON report.",
    "implementation": {
      "fields": [
        {
          "key": "next",
          "label": "New enum definition",
          "value": "",
          "type": "textarea",
          "maxLength": 200000,
          "help": "Paste the new version in the same kinds of format as the old one."
        },
        {
          "key": "format",
          "label": "Definition format",
          "value": "auto",
          "type": "select",
          "values": [
            "auto",
            "json",
            "yaml",
            "graphql",
            "proto",
            "list"
          ]
        },
        {
          "key": "pointer",
          "label": "JSON Pointer to the enum, optional",
          "value": "",
          "type": "text",
          "maxLength": 2000,
          "help": "For JSON or YAML with several enums, such as /components/schemas/Status."
        },
        {
          "key": "name",
          "label": "Enum name, optional",
          "value": "",
          "type": "text",
          "maxLength": 200,
          "help": "For GraphQL or protobuf files with several enums."
        },
        {
          "key": "matching",
          "label": "Automatic matching",
          "value": "normalized",
          "type": "select",
          "values": [
            "normalized",
            "case-insensitive",
            "exact"
          ]
        },
        {
          "key": "overrides",
          "label": "Confirmed overrides, optional",
          "value": "",
          "type": "textarea",
          "maxLength": 200000,
          "help": "CSV with the headers from,to. Leave to empty to mark a value as removed."
        }
      ],
      "registrationFamily": "api-contracts-reference",
      "codeDirection": "ltr",
      "inputMaxLength": 200000,
      "inputErrorCode": "API_CONTRACTS_REFERENCE_TOO_LONG",
      "note": "Runs in your browser in a background worker. Accepts up to 200000 characters per definition and 10000 enum values.",
      "experience": {
        "automatic": false,
        "single": false,
        "inputMaxLength": 200000,
        "inputMode": "text",
        "label": "Old enum definition",
        "placeholder": "enum: [pending, on_hold, shipped]",
        "help": "JSON Schema, OpenAPI, GraphQL enum, .proto enum or one value per line. Up to 200,000 characters. Review the settings before running.",
        "helpParts": [
          "JSON Schema, OpenAPI, GraphQL enum, .proto enum or one value per line.",
          "Up to 200,000 characters.",
          "Review the settings before running."
        ],
        "action": null
      },
      "mode": "explicit",
      "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": "# API Enum Migration Mapper\n\n- Human page: https://happytails.ai/en/developer-tools/api-enum-migration-mapper/\n- Markdown: https://happytails.ai/en/developer-tools/api-enum-migration-mapper.md\n- Structured JSON: https://happytails.ai/agents/en/developer-tools/api-enum-migration-mapper/index.json\n- Visibility: public\n\n## Tool capabilities\n\n| Property | Value |\n| --- | --- |\n| Tool ID | `api-enum-migration-mapper` |\n| Category | developer-tools |\n| Implementation | Registered implementation. Registration alone is not a production-quality guarantee. |\n| Browser execution | Use the visible action or interactive controls. |\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\nRuns in your browser in a background worker. Accepts up to 200000 characters per definition and 10000 enum values.\n\n### Inputs and settings\n\nText input: Old enum definition.\n\nExample or placeholder shown in the interface (not a validated fixture):\n\n```text\nenum: [pending, on_hold, shipped]\n```\n\nJSON Schema, OpenAPI, GraphQL enum, .proto enum or one value per line. Up to 200,000 characters. Review the settings before running.\n\n| Setting | Meaning | Control type | Default | Constraints |\n| --- | --- | --- | --- | --- |\n| `next` | New enum definition | textarea | \"\" |  |\n| `format` | Definition format | select | \"auto\" | Allowed: auto, json, yaml, graphql, proto, list |\n| `pointer` | JSON Pointer to the enum, optional | text | \"\" |  |\n| `name` | Enum name, optional | text | \"\" |  |\n| `matching` | Automatic matching | select | \"normalized\" | Allowed: normalized, case-insensitive, exact |\n| `overrides` | Confirmed overrides, optional | textarea | \"\" |  |\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\nAccepts up to 200,000 characters per definition and up to 10,000 values per enum. Matching is done in your browser. Downloads are two CSV files and a JSON report.\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\": \"api-enum-migration-mapper\",\n  \"category\": \"developer-tools\",\n  \"built\": true,\n  \"requirements\": \"Accepts up to 200,000 characters per definition and up to 10,000 values per enum. Matching is done in your browser. Downloads are two CSV files and a JSON report.\",\n  \"implementation\": {\n    \"fields\": [\n      {\n        \"key\": \"next\",\n        \"label\": \"New enum definition\",\n        \"value\": \"\",\n        \"type\": \"textarea\",\n        \"maxLength\": 200000,\n        \"help\": \"Paste the new version in the same kinds of format as the old one.\"\n      },\n      {\n        \"key\": \"format\",\n        \"label\": \"Definition format\",\n        \"value\": \"auto\",\n        \"type\": \"select\",\n        \"values\": [\n          \"auto\",\n          \"json\",\n          \"yaml\",\n          \"graphql\",\n          \"proto\",\n          \"list\"\n        ]\n      },\n      {\n        \"key\": \"pointer\",\n        \"label\": \"JSON Pointer to the enum, optional\",\n        \"value\": \"\",\n        \"type\": \"text\",\n        \"maxLength\": 2000,\n        \"help\": \"For JSON or YAML with several enums, such as /components/schemas/Status.\"\n      },\n      {\n        \"key\": \"name\",\n        \"label\": \"Enum name, optional\",\n        \"value\": \"\",\n        \"type\": \"text\",\n        \"maxLength\": 200,\n        \"help\": \"For GraphQL or protobuf files with several enums.\"\n      },\n      {\n        \"key\": \"matching\",\n        \"label\": \"Automatic matching\",\n        \"value\": \"normalized\",\n        \"type\": \"select\",\n        \"values\": [\n          \"normalized\",\n          \"case-insensitive\",\n          \"exact\"\n        ]\n      },\n      {\n        \"key\": \"overrides\",\n        \"label\": \"Confirmed overrides, optional\",\n        \"value\": \"\",\n        \"type\": \"textarea\",\n        \"maxLength\": 200000,\n        \"help\": \"CSV with the headers from,to. Leave to empty to mark a value as removed.\"\n      }\n    ],\n    \"registrationFamily\": \"api-contracts-reference\",\n    \"codeDirection\": \"ltr\",\n    \"inputMaxLength\": 200000,\n    \"inputErrorCode\": \"API_CONTRACTS_REFERENCE_TOO_LONG\",\n    \"note\": \"Runs in your browser in a background worker. Accepts up to 200000 characters per definition and 10000 enum values.\",\n    \"experience\": {\n      \"automatic\": false,\n      \"single\": false,\n      \"inputMaxLength\": 200000,\n      \"inputMode\": \"text\",\n      \"label\": \"Old enum definition\",\n      \"placeholder\": \"enum: [pending, on_hold, shipped]\",\n      \"help\": \"JSON Schema, OpenAPI, GraphQL enum, .proto enum or one value per line. Up to 200,000 characters. Review the settings before running.\",\n      \"helpParts\": [\n        \"JSON Schema, OpenAPI, GraphQL enum, .proto enum or one value per line.\",\n        \"Up to 200,000 characters.\",\n        \"Review the settings before running.\"\n      ],\n      \"action\": null\n    },\n    \"mode\": \"explicit\",\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\nMap the values of an old enum to a new one and see which values are unmapped, removed or new. Works with JSON Schema, OpenAPI, GraphQL, protobuf and plain lists.\n\n### How to use API Enum Migration Mapper\n\n1. Paste the old enum definition.\n2. Paste the new enum definition and choose how values are matched.\n3. Add confirmed overrides for values that were renamed.\n4. Run the mapping and download the from,to CSV and the review table.\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## Useful next steps\n\n- [Dataset value mapper](https://happytails.ai/en/data-tools/dataset-value-mapper/) ([Markdown](https://happytails.ai/en/data-tools/dataset-value-mapper.md))\n\n- [JSON schema validator](https://happytails.ai/en/developer-tools/json-schema-validator/) ([Markdown](https://happytails.ai/en/developer-tools/json-schema-validator.md))\n\n- [YAML to JSON](https://happytails.ai/en/data-tools/yaml-to-json/) ([Markdown](https://happytails.ai/en/data-tools/yaml-to-json.md))\n\nAccepts up to 200,000 characters per definition and up to 10,000 values per enum. Matching is done in your browser. Downloads are two CSV files and a JSON report.\n\n## Matching\n\nIdentical values of the same JSON type map exactly. Normalized matching also ignores letter case, spaces, dashes and underscores while preserving other punctuation and Unicode characters. When two new values could match, the old value is marked ambiguous instead of guessing. Distinct values in one enum that have identical CSV text, such as 1 and \"1\", are rejected because a two-column migration file cannot distinguish them. Overrides entered as from,to CSV win; an empty to marks a removed value.\n\n### Where enums are found\n\nFor JSON or YAML the tool uses the only enum array in the document, or the one your JSON Pointer names. For GraphQL SDL and .proto files it uses the only enum, or the one you name. A plain list uses one value per line.\n\n### Using the result\n\nThe from,to CSV contains only mapped values, ready for Dataset value mapper. The review CSV lists every old value with its status and every new value that nothing maps to. The tool builds the map; it does not change your data.\n"
}