{
  "openapi": "3.1.0",
  "info": {
    "title": "PrimAI API: Swiss health insurance (Krankenkasse) premiums and help",
    "version": "1.0.0",
    "summary": "Free, keyless API for Swiss basic-insurance premiums 2027 (BAG open data) and honest help: cancellation, deadlines, deductibles, subsidies, market transparency.",
    "description": "Free public API of PrimAI (primai.ch) for Swiss compulsory health insurance (Grundversicherung, KVG). Premiums are the BAG-approved list premiums 2027 from opendata.swiss; facts come from the pages of primai.ch, each with source and date.\n\nEvery response carries: data, source, data_year, as_of, disclaimer, attribution, page (the matching human page), presentation and next_steps.\nDisclaimer: BAG-approved list premiums for 2027, not an offer. The policy and the insurer's confirmation are binding. PrimAI is not an insurer and not a government service.\n\nNo key, no personal data: only postcode, age or birth year, deductible, model and accident cover. Rate limit 60 requests per minute and IP; bulk data: https://www.primai.ch/ki/open-data.\nMCP server with the same tools: https://www.primai.ch/mcp (Streamable HTTP, no auth).\n\nDeutsch: Kostenlose, offene API von PrimAI für die Grundversicherung: Prämien 2027 aller Kassen (BAG), Kündigung und Fristen, Franchise, Prämienverbilligung, Markt-Transparenz und kostenlose Beratung mit Nicole Bohne. Antworten enthalten immer Quelle, Datenjahr, Stand, Hinweis und Link zur passenden Seite.",
    "termsOfService": "https://www.primai.ch/ki/nutzungsbedingungen",
    "contact": {
      "name": "PrimAI (Loaded AG)",
      "url": "https://www.primai.ch/ki"
    },
    "license": {
      "name": "Data: Open data (opendata.swiss). Freie Nutzung, Quellenangabe Pflicht.",
      "url": "https://opendata.swiss/de/dataset/health-insurance-premiums"
    }
  },
  "servers": [
    {
      "url": "https://www.primai.ch/api/v1",
      "description": "Production"
    }
  ],
  "security": [],
  "externalDocs": {
    "description": "API reference and connection guides (ChatGPT, Claude, Gemini)",
    "url": "https://www.primai.ch/ki"
  },
  "tags": [
    {
      "name": "Prämien",
      "description": "Premiums: compare, quote, household, deductible"
    },
    {
      "name": "Kassen",
      "description": "Insurers: list and facts"
    },
    {
      "name": "Fristen",
      "description": "Deadlines and cancellation"
    },
    {
      "name": "Hilfe",
      "description": "Help guides, subsidies, market transparency, consultation"
    },
    {
      "name": "Referenz",
      "description": "Regions, models, deductibles"
    }
  ],
  "paths": {
    "/premiums/compare": {
      "get": {
        "operationId": "compare_premiums",
        "summary": "Compare basic-insurance premiums",
        "description": "All Swiss insurers' 2027 basic-insurance list premiums (Grundversicherung, KVG) for one person and postcode, cheapest first, with yearly cost and optional saving against the current insurer.",
        "tags": [
          "Prämien"
        ],
        "x-description-de": "Vergleicht die genehmigten Listenprämien 2027 aller Krankenkassen für die Grundversicherung einer Person: ein Angebot je Kasse und Modell (günstigster Tarif), sortiert nach Monatsprämie, ohne bezahlte Platzierung. Mit heutiger Kasse oder Prämie zeigt es die Ersparnis.",
        "x-mcp-tool": "compare_premiums",
        "x-primai-page": "https://www.primai.ch/praemien-2027#praemienrechner",
        "parameters": [
          {
            "name": "postcode",
            "in": "query",
            "required": true,
            "description": "Swiss postcode of the place of residence (Postleitzahl, PLZ), 4 digits, e.g. \"8001\". P.O. box postcodes have no premium region.",
            "schema": {
              "type": "string",
              "pattern": "^[0-9]{4}$",
              "examples": [
                "8001"
              ]
            },
            "example": "8001"
          },
          {
            "name": "birth_year",
            "in": "query",
            "required": false,
            "description": "Year of birth (Jahrgang). More exact than age: the BAG uses the age reached in 2027 (2027 minus birth year). Children 0–18, young adults 19–25, adults 26+.",
            "schema": {
              "type": "integer",
              "minimum": 1900,
              "maximum": 2027,
              "examples": [
                1990
              ]
            },
            "example": 1990
          },
          {
            "name": "age",
            "in": "query",
            "required": false,
            "description": "Age reached in the premium year 2027 (Alter im Prämienjahr). Alternative to birth_year; one of the two is required.",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 120,
              "examples": [
                36
              ]
            },
            "example": 36
          },
          {
            "name": "franchise",
            "in": "query",
            "required": false,
            "description": "Annual deductible in CHF (Franchise). Adults and young adults: 300, 500, 1000, 1500, 2000, 2500. Children: 0, 100, 200, 300, 400, 500, 600. Default: 2500 for adults, 0 for children (stated in the notes).",
            "schema": {
              "type": "integer",
              "enum": [
                0,
                100,
                200,
                300,
                400,
                500,
                600,
                1000,
                1500,
                2000,
                2500
              ],
              "examples": [
                2500
              ]
            },
            "example": 2500
          },
          {
            "name": "model",
            "in": "query",
            "required": false,
            "description": "Insurance model (Versicherungsmodell): standard (freie Arztwahl), hausarzt (family doctor / GP), hmo (health centre), telmed (telephone first). Empty: all models.",
            "schema": {
              "type": "string",
              "enum": [
                "standard",
                "hausarzt",
                "hmo",
                "telmed"
              ],
              "examples": [
                "hausarzt"
              ]
            },
            "example": "hausarzt"
          },
          {
            "name": "accident",
            "in": "query",
            "required": false,
            "description": "Accident cover (Unfalldeckung), default true. false = without accident cover, which applies to people who work at least 8 hours a week for one employer and are accident-insured there (UVG).",
            "schema": {
              "type": "boolean",
              "examples": [
                true
              ]
            },
            "example": true
          },
          {
            "name": "municipality",
            "in": "query",
            "required": false,
            "description": "Municipality of residence (Wohngemeinde) or its BFS number. Relevant only for postcodes that span several premium regions; for those, the answer without a municipality is the error \"ambiguous_postcode\" with the list of municipalities.",
            "schema": {
              "type": "string",
              "examples": [
                "Zürich"
              ]
            },
            "example": "Zürich"
          },
          {
            "name": "current_insurer",
            "in": "query",
            "required": false,
            "description": "Current insurer (heutige Krankenkasse); the saving per offer is computed against it.",
            "schema": {
              "type": "string",
              "examples": [
                "CSS"
              ]
            },
            "example": "CSS"
          },
          {
            "name": "current_model",
            "in": "query",
            "required": false,
            "description": "Model of the current policy. Default: model, else standard.",
            "schema": {
              "type": "string",
              "enum": [
                "standard",
                "hausarzt",
                "hmo",
                "telmed"
              ],
              "examples": [
                "standard"
              ]
            },
            "example": "standard"
          },
          {
            "name": "current_premium",
            "in": "query",
            "required": false,
            "description": "Current monthly premium in CHF from the policy (heutige Monatsprämie). Overrides the computed current premium.",
            "schema": {
              "type": "number",
              "minimum": 1,
              "maximum": 5000,
              "examples": [
                498.6
              ]
            },
            "example": 498.6
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "description": "Number of offers to return (1–100, default 10). total_offers tells how many exist.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 10,
              "examples": [
                10
              ]
            },
            "example": 10
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "All Swiss insurers' 2027 basic-insurance list premiums (Grundversicherung, KVG) for one person and postcode, cheapest first, with yearly cost and optional saving against the current insurer.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/premiums/quote": {
      "get": {
        "operationId": "get_premium",
        "summary": "Get the exact premium of one insurer",
        "description": "Exact 2027 list premium of one insurer for one person and postcode: every tariff (product name such as \"Qualimed\" or \"SanaTel\"), cheapest per model.",
        "tags": [
          "Prämien"
        ],
        "x-description-de": "Gibt die genaue Listenprämie 2027 einer bestimmten Kasse für eine Person zurück: jeden Tarif mit Produktnamen und den günstigsten Tarif je Modell.",
        "x-mcp-tool": "get_premium",
        "x-primai-page": "https://www.primai.ch/praemien-2027#praemienrechner",
        "parameters": [
          {
            "name": "postcode",
            "in": "query",
            "required": true,
            "description": "Swiss postcode of the place of residence (Postleitzahl, PLZ), 4 digits, e.g. \"8001\". P.O. box postcodes have no premium region.",
            "schema": {
              "type": "string",
              "pattern": "^[0-9]{4}$",
              "examples": [
                "8001"
              ]
            },
            "example": "8001"
          },
          {
            "name": "insurer",
            "in": "query",
            "required": true,
            "description": "Health insurer (Krankenkasse): name (\"Helsana\", \"Groupe Mutuel\", \"Sympany\"), primai.ch slug (\"helsana\") or BAG number (\"1562\").",
            "schema": {
              "type": "string",
              "examples": [
                "Helsana"
              ]
            },
            "example": "Helsana"
          },
          {
            "name": "birth_year",
            "in": "query",
            "required": false,
            "description": "Year of birth (Jahrgang). More exact than age: the BAG uses the age reached in 2027 (2027 minus birth year). Children 0–18, young adults 19–25, adults 26+.",
            "schema": {
              "type": "integer",
              "minimum": 1900,
              "maximum": 2027,
              "examples": [
                1990
              ]
            },
            "example": 1990
          },
          {
            "name": "age",
            "in": "query",
            "required": false,
            "description": "Age reached in the premium year 2027 (Alter im Prämienjahr). Alternative to birth_year; one of the two is required.",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 120,
              "examples": [
                36
              ]
            },
            "example": 36
          },
          {
            "name": "franchise",
            "in": "query",
            "required": false,
            "description": "Annual deductible in CHF (Franchise). Adults and young adults: 300, 500, 1000, 1500, 2000, 2500. Children: 0, 100, 200, 300, 400, 500, 600. Default: 2500 for adults, 0 for children (stated in the notes).",
            "schema": {
              "type": "integer",
              "enum": [
                0,
                100,
                200,
                300,
                400,
                500,
                600,
                1000,
                1500,
                2000,
                2500
              ],
              "examples": [
                2500
              ]
            },
            "example": 2500
          },
          {
            "name": "model",
            "in": "query",
            "required": false,
            "description": "Insurance model (Versicherungsmodell): standard (freie Arztwahl), hausarzt (family doctor / GP), hmo (health centre), telmed (telephone first). Empty: all models.",
            "schema": {
              "type": "string",
              "enum": [
                "standard",
                "hausarzt",
                "hmo",
                "telmed"
              ],
              "examples": [
                "hausarzt"
              ]
            },
            "example": "hausarzt"
          },
          {
            "name": "accident",
            "in": "query",
            "required": false,
            "description": "Accident cover (Unfalldeckung), default true. false = without accident cover, which applies to people who work at least 8 hours a week for one employer and are accident-insured there (UVG).",
            "schema": {
              "type": "boolean",
              "examples": [
                true
              ]
            },
            "example": true
          },
          {
            "name": "municipality",
            "in": "query",
            "required": false,
            "description": "Municipality of residence (Wohngemeinde) or its BFS number. Relevant only for postcodes that span several premium regions; for those, the answer without a municipality is the error \"ambiguous_postcode\" with the list of municipalities.",
            "schema": {
              "type": "string",
              "examples": [
                "Zürich"
              ]
            },
            "example": "Zürich"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Exact 2027 list premium of one insurer for one person and postcode: every tariff (product name such as \"Qualimed\" or \"SanaTel\"), cheapest per model.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/premiums/household": {
      "post": {
        "operationId": "compare_household",
        "summary": "Compare premiums for a household",
        "description": "Total 2027 basic-insurance premiums per insurer for a whole household (up to 10 people) at one postcode, cheapest first, plus the cheapest split across insurers.",
        "tags": [
          "Prämien"
        ],
        "x-description-de": "Summiert die Listenprämien 2027 je Kasse für einen ganzen Haushalt (bis 10 Personen) und zeigt die günstigste Aufteilung auf verschiedene Kassen.",
        "x-mcp-tool": "compare_household",
        "x-primai-page": "https://www.primai.ch/familienrabatte-krankenkasse",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "postcode": {
                    "type": "string",
                    "description": "Swiss postcode of the place of residence (Postleitzahl, PLZ), 4 digits, e.g. \"8001\". P.O. box postcodes have no premium region.",
                    "pattern": "^[0-9]{4}$",
                    "examples": [
                      "8001"
                    ],
                    "example": "8001"
                  },
                  "members": {
                    "type": "array",
                    "description": "Household members (1–10). Each: birth_year or age, optional franchise, accident, label.",
                    "items": {
                      "type": "object",
                      "properties": {
                        "birth_year": {
                          "type": "integer",
                          "description": "Year of birth (Jahrgang). More exact than age: the BAG uses the age reached in 2027 (2027 minus birth year). Children 0–18, young adults 19–25, adults 26+.",
                          "minimum": 1900,
                          "maximum": 2027,
                          "examples": [
                            1990
                          ]
                        },
                        "age": {
                          "type": "integer",
                          "description": "Age reached in the premium year 2027 (Alter im Prämienjahr). Alternative to birth_year; one of the two is required.",
                          "minimum": 0,
                          "maximum": 120,
                          "examples": [
                            36
                          ]
                        },
                        "franchise": {
                          "type": "integer",
                          "description": "Annual deductible in CHF (Franchise). Adults and young adults: 300, 500, 1000, 1500, 2000, 2500. Children: 0, 100, 200, 300, 400, 500, 600. Default: 2500 for adults, 0 for children (stated in the notes).",
                          "enum": [
                            0,
                            100,
                            200,
                            300,
                            400,
                            500,
                            600,
                            1000,
                            1500,
                            2000,
                            2500
                          ],
                          "examples": [
                            2500
                          ]
                        },
                        "accident": {
                          "type": "boolean",
                          "description": "Accident cover (Unfalldeckung), default true. false = without accident cover, which applies to people who work at least 8 hours a week for one employer and are accident-insured there (UVG).",
                          "examples": [
                            true
                          ]
                        },
                        "label": {
                          "type": "string",
                          "description": "Optional role label such as \"Mutter\" or \"Kind 1\" (a role, not a name).",
                          "examples": [
                            "Kind 1"
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "minItems": 1,
                    "maxItems": 10,
                    "example": [
                      {
                        "birth_year": 1988,
                        "franchise": 2500
                      },
                      {
                        "birth_year": 1990,
                        "franchise": 1500
                      },
                      {
                        "birth_year": 2019,
                        "franchise": 0
                      }
                    ]
                  },
                  "model": {
                    "type": "string",
                    "description": "Insurance model (Versicherungsmodell): standard (freie Arztwahl), hausarzt (family doctor / GP), hmo (health centre), telmed (telephone first). Empty: all models.",
                    "enum": [
                      "standard",
                      "hausarzt",
                      "hmo",
                      "telmed"
                    ],
                    "examples": [
                      "hausarzt"
                    ],
                    "example": "hausarzt"
                  },
                  "municipality": {
                    "type": "string",
                    "description": "Municipality of residence (Wohngemeinde) or its BFS number. Relevant only for postcodes that span several premium regions; for those, the answer without a municipality is the error \"ambiguous_postcode\" with the list of municipalities.",
                    "examples": [
                      "Zürich"
                    ],
                    "example": "Zürich"
                  },
                  "limit": {
                    "type": "integer",
                    "description": "Number of insurers to return (default 10).",
                    "minimum": 1,
                    "maximum": 50,
                    "default": 10,
                    "examples": [
                      10
                    ],
                    "example": 10
                  }
                },
                "required": [
                  "postcode",
                  "members"
                ]
              },
              "example": {
                "postcode": "1004",
                "members": [
                  {
                    "birth_year": 1986,
                    "franchise": 2500
                  },
                  {
                    "birth_year": 1988,
                    "franchise": 2500
                  },
                  {
                    "birth_year": 2016
                  },
                  {
                    "birth_year": 2020
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Total 2027 basic-insurance premiums per insurer for a whole household (up to 10 people) at one postcode, cheapest first, plus the cheapest split across insurers.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "compare_household_get",
        "summary": "Compare premiums for a household (GET)",
        "description": "Same as POST, members as \"birth_year:franchise:accident\" list, e.g. \"1988:2500:1,2019:0:1\".",
        "tags": [
          "Prämien"
        ],
        "x-description-de": "Summiert die Listenprämien 2027 je Kasse für einen ganzen Haushalt (bis 10 Personen) und zeigt die günstigste Aufteilung auf verschiedene Kassen.",
        "x-mcp-tool": "compare_household",
        "x-primai-page": "https://www.primai.ch/familienrabatte-krankenkasse",
        "parameters": [
          {
            "name": "postcode",
            "in": "query",
            "required": true,
            "description": "Swiss postcode of the place of residence (Postleitzahl, PLZ), 4 digits, e.g. \"8001\". P.O. box postcodes have no premium region.",
            "schema": {
              "type": "string",
              "pattern": "^[0-9]{4}$",
              "examples": [
                "8001"
              ]
            },
            "example": "8001"
          },
          {
            "name": "members",
            "in": "query",
            "required": true,
            "description": "Comma-separated birth_year:franchise:accident, e.g. 1988:2500:1,2019:0:1",
            "schema": {
              "type": "string"
            },
            "example": "1988:2500:1,2019:0:1"
          },
          {
            "name": "model",
            "in": "query",
            "required": false,
            "description": "Insurance model (Versicherungsmodell): standard (freie Arztwahl), hausarzt (family doctor / GP), hmo (health centre), telmed (telephone first). Empty: all models.",
            "schema": {
              "type": "string",
              "enum": [
                "standard",
                "hausarzt",
                "hmo",
                "telmed"
              ],
              "examples": [
                "hausarzt"
              ]
            },
            "example": "hausarzt"
          },
          {
            "name": "municipality",
            "in": "query",
            "required": false,
            "description": "Municipality of residence (Wohngemeinde) or its BFS number. Relevant only for postcodes that span several premium regions; for those, the answer without a municipality is the error \"ambiguous_postcode\" with the list of municipalities.",
            "schema": {
              "type": "string",
              "examples": [
                "Zürich"
              ]
            },
            "example": "Zürich"
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "description": "Number of insurers to return (default 10).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 50,
              "default": 10,
              "examples": [
                10
              ]
            },
            "example": 10
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Total 2027 basic-insurance premiums per insurer for a whole household (up to 10 people) at one postcode, cheapest first, plus the cheapest split across insurers.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/regions/resolve": {
      "get": {
        "operationId": "resolve_region",
        "summary": "Resolve a postcode to canton and premium region",
        "description": "Canton, premium region (Prämienregion) and municipalities for a Swiss postcode. Flags postcodes that span several premium regions.",
        "tags": [
          "Referenz"
        ],
        "x-description-de": "Gibt Kanton, Prämienregion und Gemeinden einer Postleitzahl zurück und zeigt, ob die PLZ in mehreren Prämienregionen liegt.",
        "x-mcp-tool": "resolve_region",
        "x-primai-page": "https://www.primai.ch/kanton",
        "parameters": [
          {
            "name": "postcode",
            "in": "query",
            "required": true,
            "description": "Swiss postcode of the place of residence (Postleitzahl, PLZ), 4 digits, e.g. \"8001\". P.O. box postcodes have no premium region.",
            "schema": {
              "type": "string",
              "pattern": "^[0-9]{4}$",
              "examples": [
                "8001"
              ]
            },
            "example": "8001"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Canton, premium region (Prämienregion) and municipalities for a Swiss postcode. Flags postcodes that span several premium regions.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/insurers": {
      "get": {
        "operationId": "list_insurers",
        "summary": "List approved insurers",
        "description": "All health insurers in the BAG register with BAG number, cantons offered, models and median premium change 2026→2027.",
        "tags": [
          "Kassen"
        ],
        "x-description-de": "Alle Kassen im BAG-Verzeichnis mit BAG-Nummer, angebotenen Kantonen und Modellen und der mittleren Prämienveränderung 2026→2027.",
        "x-primai-page": "https://www.primai.ch/krankenkasse-wechseln",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "All health insurers in the BAG register with BAG number, cantons offered, models and median premium change 2026→2027.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/insurers/{insurer}": {
      "get": {
        "operationId": "insurer_facts",
        "summary": "Facts about one insurer",
        "description": "One insurer's 2027 median premium change, models and tariffs, cantons, cancellation address, deadlines, contact and supplementary products.",
        "tags": [
          "Kassen"
        ],
        "x-description-de": "Fakten zu einer Kasse: Prämienveränderung 2027, Modelle und Tarife, Kantone, Kündigungsadresse, Fristen, Kontakt, Zusatzversicherungen und Verbindungen zu Portalen.",
        "x-mcp-tool": "insurer_facts",
        "x-primai-page": "https://www.primai.ch/krankenkasse-wechseln",
        "parameters": [
          {
            "name": "insurer",
            "in": "path",
            "required": true,
            "description": "Health insurer (Krankenkasse): name (\"Helsana\", \"Groupe Mutuel\", \"Sympany\"), primai.ch slug (\"helsana\") or BAG number (\"1562\").",
            "schema": {
              "type": "string",
              "examples": [
                "Helsana"
              ]
            },
            "example": "Helsana"
          },
          {
            "name": "canton",
            "in": "query",
            "required": false,
            "description": "Optional canton (code \"ZH\" or name \"Zürich\") for canton-specific numbers.",
            "schema": {
              "type": "string",
              "examples": [
                "ZH"
              ]
            },
            "example": "ZH"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "One insurer's 2027 median premium change, models and tariffs, cantons, cancellation address, deadlines, contact and supplementary products.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/cancellation/{insurer}": {
      "get": {
        "operationId": "cancellation_help",
        "summary": "Help with cancelling a health insurance",
        "description": "Deadline (days left), cancellation address, steps, conditions and a letter template for cancelling basic (KVG) or supplementary (VVG) insurance with one insurer.",
        "tags": [
          "Fristen"
        ],
        "x-description-de": "Frist (mit verbleibenden Tagen), Kündigungsadresse, Schritte, Bedingungen und Briefvorlage für die Kündigung der Grund- oder Zusatzversicherung.",
        "x-mcp-tool": "cancellation_help",
        "x-primai-page": "https://www.primai.ch/krankenkasse-kuendigen",
        "parameters": [
          {
            "name": "insurer",
            "in": "path",
            "required": true,
            "description": "Health insurer (Krankenkasse): name (\"Helsana\", \"Groupe Mutuel\", \"Sympany\"), primai.ch slug (\"helsana\") or BAG number (\"1562\").",
            "schema": {
              "type": "string",
              "examples": [
                "Helsana"
              ]
            },
            "example": "Helsana"
          },
          {
            "name": "type",
            "in": "query",
            "required": false,
            "description": "basic = Grundversicherung (KVG, default); supplementary = Zusatzversicherung (VVG).",
            "schema": {
              "type": "string",
              "enum": [
                "basic",
                "supplementary"
              ],
              "default": "basic",
              "examples": [
                "basic"
              ]
            },
            "example": "basic"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Deadline (days left), cancellation address, steps, conditions and a letter template for cancelling basic (KVG) or supplementary (VVG) insurance with one insurer.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/franchise-check": {
      "get": {
        "operationId": "franchise_check",
        "summary": "Which deductible pays off",
        "description": "Which deductible (Franchise) is cheapest for expected yearly health costs: premiums + deductible + 10 % co-pay per level, and from which costs each level pays off.",
        "tags": [
          "Prämien"
        ],
        "x-description-de": "Rechnet für jede Franchise Prämien, Franchise und Selbstbehalt zusammen und zeigt, welche bei den erwarteten Kosten am günstigsten ist und ab welchen Kosten sich welche Franchise lohnt.",
        "x-mcp-tool": "franchise_check",
        "x-primai-page": "https://www.primai.ch/krankenkasse-franchise",
        "parameters": [
          {
            "name": "expected_costs",
            "in": "query",
            "required": true,
            "description": "Expected yearly health costs in CHF covered by basic insurance (doctor, hospital, medicines), before deductible.",
            "schema": {
              "type": "number",
              "minimum": 0,
              "maximum": 1000000,
              "examples": [
                1200
              ]
            },
            "example": 1200
          },
          {
            "name": "birth_year",
            "in": "query",
            "required": false,
            "description": "Year of birth (Jahrgang). More exact than age: the BAG uses the age reached in 2027 (2027 minus birth year). Children 0–18, young adults 19–25, adults 26+.",
            "schema": {
              "type": "integer",
              "minimum": 1900,
              "maximum": 2027,
              "examples": [
                1990
              ]
            },
            "example": 1990
          },
          {
            "name": "age",
            "in": "query",
            "required": false,
            "description": "Age reached in the premium year 2027 (Alter im Prämienjahr). Alternative to birth_year; one of the two is required.",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 120,
              "examples": [
                36
              ]
            },
            "example": 36
          },
          {
            "name": "postcode",
            "in": "query",
            "required": false,
            "description": "Swiss postcode of the place of residence (Postleitzahl, PLZ), 4 digits, e.g. \"8001\". P.O. box postcodes have no premium region.",
            "schema": {
              "type": "string",
              "pattern": "^[0-9]{4}$",
              "examples": [
                "8001"
              ]
            },
            "example": "8001"
          },
          {
            "name": "insurer",
            "in": "query",
            "required": false,
            "description": "Optional insurer for the reference tariff.",
            "schema": {
              "type": "string",
              "examples": [
                "Helsana"
              ]
            },
            "example": "Helsana"
          },
          {
            "name": "model",
            "in": "query",
            "required": false,
            "description": "Insurance model (Versicherungsmodell): standard (freie Arztwahl), hausarzt (family doctor / GP), hmo (health centre), telmed (telephone first). Empty: all models.",
            "schema": {
              "type": "string",
              "enum": [
                "standard",
                "hausarzt",
                "hmo",
                "telmed"
              ],
              "examples": [
                "hausarzt"
              ]
            },
            "example": "hausarzt"
          },
          {
            "name": "accident",
            "in": "query",
            "required": false,
            "description": "Accident cover (Unfalldeckung), default true. false = without accident cover, which applies to people who work at least 8 hours a week for one employer and are accident-insured there (UVG).",
            "schema": {
              "type": "boolean",
              "examples": [
                true
              ]
            },
            "example": true
          },
          {
            "name": "municipality",
            "in": "query",
            "required": false,
            "description": "Municipality of residence (Wohngemeinde) or its BFS number. Relevant only for postcodes that span several premium regions; for those, the answer without a municipality is the error \"ambiguous_postcode\" with the list of municipalities.",
            "schema": {
              "type": "string",
              "examples": [
                "Zürich"
              ]
            },
            "example": "Zürich"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Which deductible (Franchise) is cheapest for expected yearly health costs: premiums + deductible + 10 % co-pay per level, and from which costs each level pays off.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/subsidies/{canton}": {
      "get": {
        "operationId": "subsidy_info",
        "summary": "Premium subsidy in a canton",
        "description": "How the premium subsidy (Prämienverbilligung, IPV) works in one canton: office, procedure, where to apply, 2027 deadline, income basis, with a source per field.",
        "tags": [
          "Hilfe"
        ],
        "x-description-de": "Wie die Prämienverbilligung im Kanton funktioniert: Stelle, Verfahren, Antrag, Frist 2027, Einkommensgrundlage, je Feld mit Quelle.",
        "x-mcp-tool": "subsidy_info",
        "x-primai-page": "https://www.primai.ch/kanton",
        "parameters": [
          {
            "name": "canton",
            "in": "path",
            "required": true,
            "description": "Canton code (\"BE\") or name (\"Bern\", \"Genève\").",
            "schema": {
              "type": "string",
              "examples": [
                "BE"
              ]
            },
            "example": "BE"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "How the premium subsidy (Prämienverbilligung, IPV) works in one canton: office, procedure, where to apply, 2027 deadline, income basis, with a source per field.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/subsidies": {
      "get": {
        "operationId": "list_subsidies",
        "summary": "Premium subsidies in all cantons",
        "description": "Office, procedure, deadline and application link of the premium subsidy for all 26 cantons.",
        "tags": [
          "Hilfe"
        ],
        "x-description-de": "Übersicht der Prämienverbilligung in allen 26 Kantonen.",
        "x-primai-page": "https://www.primai.ch/kanton",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Office, procedure, deadline and application link of the premium subsidy for all 26 cantons.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/help": {
      "get": {
        "operationId": "find_help",
        "summary": "Find the right PrimAI guide for a problem",
        "description": "PrimAI guides on Swiss health-insurance rules, with sources: switching on 30 June by model and deductible, acceptance and pre-existing conditions, supplementary insurance, new residents, ombudsman, refused benefits, double insurance, brokers, cold calls, debt, moving, birth, retirement, subsidies.",
        "tags": [
          "Hilfe"
        ],
        "x-description-de": "Findet zum Problem in eigenen Worten den passenden PrimAI-Ratgeber und gibt ihn als Markdown mit Quellen zurück.",
        "x-mcp-tool": "find_help",
        "x-primai-page": "https://www.primai.ch/hilfe",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": true,
            "description": "The problem in plain words, German or English.",
            "schema": {
              "type": "string",
              "examples": [
                "Ich bin doppelt versichert"
              ]
            },
            "example": "Ich bin doppelt versichert"
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "description": "Number of matches (default 3).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 10,
              "default": 3,
              "examples": [
                3
              ]
            },
            "example": 3
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "PrimAI guides on Swiss health-insurance rules, with sources: switching on 30 June by model and deductible, acceptance and pre-existing conditions, supplementary insurance, new residents, ombudsman, refused benefits, double insurance, brokers, cold calls, debt, moving, birth, retirement, subsidies.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/market": {
      "get": {
        "operationId": "market_facts",
        "summary": "Who is behind a portal, broker or app",
        "description": "Who owns and operates a Swiss health-insurance comparison portal, broker, app or call centre and how it earns money, with source and date. Includes PrimAI's own ties.",
        "tags": [
          "Hilfe"
        ],
        "x-description-de": "Wer betreibt und besitzt Vergleichsportale, Makler, Apps und Callcenter, wie verdienen sie, mit Quelle und Datum. Mit den eigenen Verbindungen von PrimAI.",
        "x-mcp-tool": "market_facts",
        "x-primai-page": "https://www.primai.ch/markt",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "description": "Name of a portal, broker, app or call centre, or a question in plain words. Empty: all entities.",
            "schema": {
              "type": "string",
              "examples": [
                "Vergleichsportal"
              ]
            },
            "example": "Vergleichsportal"
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "description": "Number of results (default 5).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 20,
              "default": 5,
              "examples": [
                5
              ]
            },
            "example": 5
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Who owns and operates a Swiss health-insurance comparison portal, broker, app or call centre and how it earns money, with source and date. Includes PrimAI's own ties.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/consultation": {
      "get": {
        "operationId": "consultation_options",
        "summary": "Consultation options",
        "description": "What PrimAI's adviser Nicole Bohne (FINMA-registered, non-tied) helps with, that it is free, the booking link (a 30-minute video call) with the topic filled in, phone and e-mail, and how PrimAI earns. The tool itself books nothing.",
        "tags": [
          "Hilfe"
        ],
        "x-description-de": "Wobei Nicole Bohne hilft, dass es kostenlos ist, der Buchungslink (30 Minuten per Video-Call) mit Thema, Telefon und E-Mail und wie PrimAI verdient. Bucht nie selbst.",
        "x-mcp-tool": "consultation_options",
        "x-primai-page": "https://www.primai.ch/beratung",
        "parameters": [
          {
            "name": "topic",
            "in": "query",
            "required": false,
            "description": "Optional topic of a few words, e.g. \"Zusatzversicherung prüfen\" or \"Zweitmeinung nach Beratung\" (a topic, not names or health data). It is copied into the booking link.",
            "schema": {
              "type": "string",
              "examples": [
                "Zweitmeinung nach Beratung"
              ]
            },
            "example": "Zweitmeinung nach Beratung"
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "What PrimAI's adviser Nicole Bohne (FINMA-registered, non-tied) helps with, that it is free, the booking link (a 30-minute video call) with the topic filled in, phone and e-mail, and how PrimAI earns. The tool itself books nothing.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/models": {
      "get": {
        "operationId": "list_models",
        "summary": "Insurance models",
        "description": "The four basic-insurance models (Standard, Hausarzt, HMO, Telmed) with German labels and a short explanation.",
        "tags": [
          "Referenz"
        ],
        "x-description-de": "Die vier Modelle der Grundversicherung mit Erklärung.",
        "x-primai-page": "https://www.primai.ch/krankenkasse-modelle",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "The four basic-insurance models (Standard, Hausarzt, HMO, Telmed) with German labels and a short explanation.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/deductibles": {
      "get": {
        "operationId": "list_deductibles",
        "summary": "Deductible levels",
        "description": "Legal deductible levels (Franchise) per age group, the ordinary franchise and the co-payment cap.",
        "tags": [
          "Referenz"
        ],
        "x-description-de": "Franchisestufen je Altersgruppe, ordentliche Franchise, Selbstbehalt und Fristen.",
        "x-primai-page": "https://www.primai.ch/krankenkasse-franchise",
        "parameters": [
          {
            "name": "birth_year",
            "in": "query",
            "required": false,
            "description": "Year of birth (Jahrgang). More exact than age: the BAG uses the age reached in 2027 (2027 minus birth year). Children 0–18, young adults 19–25, adults 26+.",
            "schema": {
              "type": "integer",
              "minimum": 1900,
              "maximum": 2027,
              "examples": [
                1990
              ]
            },
            "example": 1990
          },
          {
            "name": "age",
            "in": "query",
            "required": false,
            "description": "Age reached in the premium year 2027 (Alter im Prämienjahr). Alternative to birth_year; one of the two is required.",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 120,
              "examples": [
                36
              ]
            },
            "example": 36
          }
        ],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Legal deductible levels (Franchise) per age group, the ordinary franchise and the co-payment cap.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/deadlines": {
      "get": {
        "operationId": "deadlines",
        "summary": "Switching deadlines",
        "description": "Current switching deadlines of the basic insurance for today in Zurich (30 November / 31 March), days left, franchise change rules and switch conditions.",
        "tags": [
          "Fristen"
        ],
        "x-description-de": "Aktuelle Wechselfristen der Grundversicherung mit verbleibenden Tagen.",
        "x-primai-page": "https://www.primai.ch/krankenkasse-kuendigen",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Result in the PrimAI envelope (data + source, data_year, as_of, disclaimer, page).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "data",
                    "source",
                    "data_year",
                    "as_of",
                    "disclaimer",
                    "page"
                  ],
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Current switching deadlines of the basic insurance for today in Zurich (30 November / 31 March), days left, franchise change rules and switch conditions.",
                      "additionalProperties": true
                    },
                    "source": {
                      "type": "object",
                      "description": "Primary data source (BAG Prämien for premiums).",
                      "additionalProperties": true
                    },
                    "data_year": {
                      "type": "integer",
                      "description": "Premium year of the data.",
                      "example": 2027
                    },
                    "as_of": {
                      "type": "string",
                      "description": "Date of the data (YYYY-MM-DD, or YYYY-MM).",
                      "example": "2026-09-29"
                    },
                    "disclaimer": {
                      "type": "string",
                      "description": "German disclaimer: list premiums, not an offer."
                    },
                    "disclaimer_en": {
                      "type": "string"
                    },
                    "page": {
                      "type": "string",
                      "format": "uri",
                      "description": "Matching human page on primai.ch."
                    },
                    "attribution": {
                      "type": "string",
                      "description": "How to credit the data."
                    },
                    "presentation": {
                      "type": "string",
                      "description": "How the figures are meant to be shown: exactly as returned, with source and page; list premiums, not an offer."
                    },
                    "next_steps": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Related operations for common follow-up questions."
                    },
                    "operation": {
                      "type": "string"
                    },
                    "api_version": {
                      "type": "string"
                    },
                    "more": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Unknown postcode, insurer or no premiums for the combination.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Ambiguous input: the postcode spans several premium regions (choose municipality) or the insurer name matches several.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit (60 requests per minute and IP).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Error": {
        "type": "object",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "e.g. invalid_parameter, unknown_postcode, ambiguous_postcode (choose a municipality from options), unknown_insurer, rate_limited"
              },
              "message": {
                "type": "string",
                "description": "German message for the user."
              },
              "options": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": true
                },
                "description": "Choices when the input was ambiguous."
              }
            },
            "additionalProperties": true
          }
        }
      }
    }
  }
}