{
  "openapi": "3.1.1",
  "info": {
    "title": "IPv6 Readiness Explorer API",
    "version": "1.0.0",
    "summary": "Is a domain reachable over IPv6? Web, DNS and mail checks, address classes and a scored report.",
    "description": "Every endpoint performs the same calculation as the human page and returns inputs, result, units, assumptions, sources, warnings and computedAt. MCP endpoint: /mcp."
  },
  "servers": [
    {
      "url": "https://ipv6readinessexplorer.usefulweb.site"
    }
  ],
  "paths": {
    "/api/v1/calculate": {
      "post": {
        "operationId": "calculate",
        "summary": "Is a domain reachable over IPv6? Web, DNS and mail checks, address classes and a scored report.",
        "description": "Checks AAAA records for a domain and its www host, IPv6 addresses of its name servers and mail servers, classifies every IPv6 address (global unicast vs ULA, link-local, documentation, 6to4, Teredo, NAT64 …), optionally opens a TCP connection to port 443 over IPv6, and turns it into a score with every check explained.\n\nMethodology:\n- Resolves A and AAAA for the domain and www.<domain>, the NS host names and the MX host names (up to 10) with this server's resolver.\n- Every IPv6 address is classified against the IANA IPv6 special-purpose registry: only global unicast (2000::/3 minus special blocks) is reachable from the internet.\n- Score (points, n/a checks are excluded from the maximum): apex AAAA 25, www AAAA 15, any name server with IPv6 20, all name servers with IPv6 10, MX with IPv6 15 (pro rata), no special-purpose addresses 5, TCP 443 over IPv6 10. Grade A ≥ 90, B ≥ 75, C ≥ 50, D ≥ 25.\n- Connect test: up to 3 global AAAA addresses of the domain/www, TCP handshake on port 443 with a 5 s timeout. If this server itself has no IPv6 route (ENETUNREACH/EADDRNOTAVAIL), the test is reported as not possible instead of counted as a failure.",
        "tags": [
          "infrastructure"
        ],
        "x-mcp-tool": "ipv6_readiness_explorer",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Ipv6ReadinessExplorerInput"
              },
              "examples": {
                "example1": {
                  "summary": "Pasted record set: partial IPv6",
                  "value": {
                    "mode": "pasted",
                    "pasted": "{\n \"domain\": \"example.net\",\n \"hosts\": [\n  {\n   \"name\": \"example.net\",\n   \"ipv4\": [\n    \"93.184.215.14\"\n   ],\n   \"ipv6\": [\n    \"2606:2800:21f:cb07:6820:80da:af6b:8b2c\"\n   ]\n  },\n  {\n   \"name\": \"www.example.net\",\n   \"ipv4\": [\n    \"93.184.215.14\"\n   ],\n   \"ipv6\": []\n  }\n ],\n \"nameservers\": [\n  {\n   \"name\": \"ns1.dns-host.example\",\n   \"ipv4\": [\n    \"198.51.100.53\"\n   ],\n   \"ipv6\": [\n    \"2a00:1450:4001:c0f::35\"\n   ]\n  },\n  {\n   \"name\": \"ns2.dns-host.example\",\n   \"ipv4\": [\n    \"203.0.113.53\"\n   ],\n   \"ipv6\": []\n  }\n ],\n \"mx\": [\n  {\n   \"name\": \"mail.example.net\",\n   \"priority\": 10,\n   \"ipv4\": [\n    \"198.51.100.25\"\n   ],\n   \"ipv6\": [\n    \"fd00:25::1\"\n   ]\n  }\n ],\n \"connect\": [\n  {\n   \"host\": \"example.net\",\n   \"address\": \"2606:2800:21f:cb07:6820:80da:af6b:8b2c\",\n   \"ok\": false,\n   \"code\": \"ENETUNREACH\",\n   \"ms\": null\n  }\n ]\n}"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Calculation result envelope.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Ipv6ReadinessExplorerResult"
                }
              }
            }
          },
          "400": {
            "description": "Malformed JSON body.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "422": {
            "description": "Invalid input (see errors[]).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit exceeded (see Retry-After).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/tool": {
      "get": {
        "operationId": "getToolDefinition",
        "summary": "Inputs, output schema and examples for this tool",
        "responses": {
          "200": {
            "description": "Tool definition.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Problem": {
        "type": "object",
        "description": "RFC 9457 problem details. 422 responses include per-field `errors`.",
        "required": [
          "type",
          "title",
          "status",
          "detail"
        ],
        "properties": {
          "type": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "integer"
          },
          "detail": {
            "type": "string"
          },
          "code": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "field",
                "message"
              ],
              "properties": {
                "field": {
                  "type": "string"
                },
                "message": {
                  "type": "string"
                }
              }
            }
          }
        }
      },
      "Ipv6ReadinessExplorerInput": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "mode": {
            "title": "Mode",
            "type": "string",
            "enum": [
              "live",
              "pasted"
            ],
            "default": "live"
          },
          "domain": {
            "title": "Domain",
            "type": "string",
            "maxLength": 253
          },
          "connectTest": {
            "title": "Also try a TCP connection to port 443 over IPv6 from this server",
            "type": "boolean",
            "default": true
          },
          "pasted": {
            "title": "Record set (JSON)",
            "description": "Pasted mode: {domain, hosts:[{name, ipv4, ipv6}], nameservers:[…], mx:[{name, priority, ipv4, ipv6}], connect?:[{host, address, ok, code}]}",
            "type": "string",
            "maxLength": 100000
          }
        },
        "required": []
      },
      "Ipv6ReadinessExplorerResult": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "schemaVersion",
          "tool",
          "computedAt",
          "inputs",
          "summary",
          "result",
          "units",
          "assumptions",
          "sources",
          "warnings",
          "presentation",
          "links"
        ],
        "properties": {
          "schemaVersion": {
            "type": "string",
            "const": "1.0"
          },
          "tool": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "name",
              "version"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            }
          },
          "computedAt": {
            "type": "string",
            "format": "date-time"
          },
          "inputs": {
            "type": "object",
            "description": "Normalised inputs actually used, including applied defaults."
          },
          "summary": {
            "type": "string"
          },
          "result": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "domain",
              "score",
              "grade",
              "points",
              "maxPoints",
              "checks",
              "hosts",
              "nameservers",
              "mx",
              "addresses",
              "connect",
              "serverHasNoIpv6"
            ],
            "properties": {
              "domain": {
                "type": "string"
              },
              "score": {
                "type": "integer",
                "minimum": 0,
                "maximum": 100
              },
              "grade": {
                "type": "string",
                "enum": [
                  "A",
                  "B",
                  "C",
                  "D",
                  "F"
                ]
              },
              "points": {
                "type": "integer"
              },
              "maxPoints": {
                "type": "integer"
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "id",
                    "label",
                    "status",
                    "points",
                    "max",
                    "detail"
                  ],
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    },
                    "status": {
                      "type": "string",
                      "enum": [
                        "pass",
                        "fail",
                        "partial",
                        "n/a"
                      ]
                    },
                    "points": {
                      "type": "integer"
                    },
                    "max": {
                      "type": "integer"
                    },
                    "detail": {
                      "type": "string"
                    }
                  }
                }
              },
              "hosts": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "name",
                    "ipv4",
                    "ipv6"
                  ],
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "ipv4": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "ipv6": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  }
                }
              },
              "nameservers": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "name",
                    "ipv4",
                    "ipv6"
                  ],
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "ipv4": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "ipv6": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  }
                }
              },
              "mx": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "name",
                    "ipv4",
                    "ipv6",
                    "priority"
                  ],
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "ipv4": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "ipv6": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "priority": {
                      "type": "integer"
                    }
                  }
                }
              },
              "addresses": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "host",
                    "role",
                    "address",
                    "global",
                    "kind"
                  ],
                  "properties": {
                    "host": {
                      "type": "string"
                    },
                    "role": {
                      "type": "string"
                    },
                    "address": {
                      "type": "string"
                    },
                    "global": {
                      "type": "boolean"
                    },
                    "kind": {
                      "type": "string"
                    }
                  }
                }
              },
              "connect": {
                "type": [
                  "array",
                  "null"
                ],
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "host",
                    "address",
                    "ok",
                    "code",
                    "ms"
                  ],
                  "properties": {
                    "host": {
                      "type": "string"
                    },
                    "address": {
                      "type": "string"
                    },
                    "ok": {
                      "type": "boolean"
                    },
                    "code": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "ms": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    }
                  }
                }
              },
              "serverHasNoIpv6": {
                "type": "boolean"
              }
            }
          },
          "units": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "assumptions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "sources": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "required": [
                "title"
              ],
              "properties": {
                "title": {
                  "type": "string"
                },
                "url": {
                  "type": "string"
                },
                "publisher": {
                  "type": "string"
                },
                "retrievedAt": {
                  "type": "string"
                },
                "note": {
                  "type": "string"
                }
              }
            }
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "presentation": {
            "type": "array",
            "items": {
              "type": "object"
            },
            "description": "Display blocks used by the human page (same data)."
          },
          "links": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "human",
              "api",
              "openapi",
              "methodology"
            ],
            "properties": {
              "human": {
                "type": "string",
                "format": "uri"
              },
              "api": {
                "type": "string",
                "format": "uri"
              },
              "openapi": {
                "type": "string",
                "format": "uri"
              },
              "methodology": {
                "type": "string",
                "format": "uri"
              }
            }
          }
        }
      }
    }
  }
}