{
  "openapi" : "3.1.0",
  "info" : {
    "title" : "LiveMap Routing Facade (v1)",
    "description" : "## Choose this contract for existing comparison clients\nv1 returns GeoJSON LineStrings, distances in meters, and times in milliseconds.\nIt remains available for existing widget, intranet, and transport integrations.\nOperations are deprecated for new integrations; this does not announce a removal date.\nv2 is not wire-compatible: see [the navigation contract](/api/v2/routing/openapi.json)\nfor polyline6 navigation routes and durations in seconds.\n\n## Client workflow\n1. Read `GET /api/v1/routing/profiles` for available product IDs.\n2. Send `points` as at least two `[longitude, latitude]` pairs and a nonempty `profiles` list.\n3. Inspect `status`, `routes`, `routeErrors`, and `omittedVariants`; HTTP 200 alone does not mean every profile has a route.\nSuccessful variants can be withheld by configured alternative criteria when a requested baseline succeeds.\nProfile deprecation does not change an ID's routing meaning.\n\n## Scope and deployment\nThis is the routing **engine** contract, not the frontend's public facade.\nFrontend authentication, payload dispatch, presentation/localization, and proxy 502/504 errors\nare owned by that facade and are not described here. The engine defines no bearer-token scheme;\na deployment gateway may impose its own access controls.\nUse `Content-Type: application/json` for POST requests. Examples are illustrative, not a\npromise of route availability or an exhaustive profile catalog.\nThis document describes the serving build; `info.version` is its service version.\nRead `/api/version` separately for build/data identity. Rendered documentation is at `/docs`.\n",
    "version" : "1.0.0-SNAPSHOT"
  },
  "servers" : [ {
    "url" : "/",
    "description" : "Same-origin routing engine or reverse proxy"
  } ],
  "tags" : [ {
    "name" : "Routing v1",
    "description" : "LiveMap facade for product-profile route comparison. Transitional: superseded by the v2 navigation surfaces (/api/v2/routing/route + /plan). Frozen to maintenance; see decision-log.md and ADR-0018."
  } ],
  "paths" : {
    "/api/v1/routing/openapi.json" : {
      "get" : {
        "tags" : [ "Routing v1" ],
        "summary" : "Return the v1 OpenAPI document",
        "description" : "OpenAPI 3.1 contract for the v1 facade, generated at runtime from the live resource. v2 navigation has its own document at /api/v2/routing/openapi.json.",
        "operationId" : "v1GetOpenApi",
        "responses" : {
          "200" : {
            "description" : "OpenAPI 3.1 JSON document",
            "content" : {
              "application/json" : {
                "schema" : { }
              }
            }
          }
        }
      }
    },
    "/api/v1/routing/profiles" : {
      "get" : {
        "tags" : [ "Routing v1" ],
        "summary" : "Return the configured LiveMap product profile catalog",
        "operationId" : "v1GetProfiles",
        "responses" : {
          "200" : {
            "description" : "Profile catalog keyed by product profile id. Each value carries base_profile and the per-dimension preference weights, plus `deprecated` / `superseded_by` where set. The policy blocks are served by GET /api/v2/routing/profiles.",
            "content" : {
              "application/json" : {
                "schema" : {
                  "$ref" : "#/components/schemas/ProfileCatalogV1"
                },
                "examples" : {
                  "Active profile" : {
                    "value" : {
                      "foot_fast" : {
                        "base_profile" : "foot_base",
                        "weights" : {
                          "tree" : 0.0,
                          "lights" : 0.0,
                          "accident" : 0.0,
                          "crime" : 0.0,
                          "presence" : 0.0,
                          "noise" : 0.0,
                          "water" : 0.0,
                          "green" : 0.0,
                          "incline" : 0.0,
                          "main_roads" : 0.0
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated" : true
      }
    },
    "/api/v1/routing/route" : {
      "post" : {
        "tags" : [ "Routing v1" ],
        "summary" : "Calculate one route per requested LiveMap product profile",
        "description" : "Resolves the temporal bucket, then routes each requested product profile over the LiveMap-weighted graph. Deprecated: use POST /api/v2/routing/plan for fully-navigable multi-profile alternatives (OSRM-compatible), with an explicit client adaptation. Existing GeoJSON/millisecond consumers can continue using v1. Some profiles may fail independently (`routeErrors`), or successful variants may be withheld by configured alternative criteria (`omittedVariants`). Filtering needs the configured baseline to be requested and successfully routed; it is not fetched implicitly.",
        "operationId" : "v1PostRoute",
        "parameters" : [ {
          "name" : "telemetry",
          "in" : "query",
          "description" : "Internal diagnostic telemetry for measurement tooling. The frontend need not forward this flag.",
          "schema" : {
            "type" : "boolean",
            "default" : false
          }
        } ],
        "requestBody" : {
          "content" : {
            "application/json" : {
              "schema" : {
                "$ref" : "#/components/schemas/LivemapRouteRequest"
              },
              "examples" : {
                "Compare profiles" : {
                  "value" : {
                    "points" : [ [ 8.5417, 47.3769 ], [ 8.55, 47.38 ] ],
                    "profiles" : [ "foot_fast", "foot_green" ],
                    "bucket" : "auto"
                  }
                }
              }
            }
          },
          "required" : true
        },
        "responses" : {
          "200" : {
            "description" : "Routing result. `status=ok` means at least one route survives; `status=no_route` means `routes` is empty. Inspect optional `routeErrors` and `omittedVariants` for requested profiles absent from `routes`.",
            "content" : {
              "application/json" : {
                "schema" : {
                  "$ref" : "#/components/schemas/LivemapRouteResponse"
                },
                "examples" : {
                  "Success" : {
                    "value" : {
                      "status" : "ok",
                      "resolvedBucket" : "wd_am",
                      "routes" : [ {
                        "profile" : "foot_fast",
                        "distanceMeters" : 120,
                        "timeMillis" : 90000,
                        "geometry" : {
                          "type" : "LineString",
                          "coordinates" : [ [ 8.54, 47.37 ], [ 8.541, 47.371 ] ]
                        },
                        "instructions" : [ {
                          "text" : "Continue",
                          "distance" : 120,
                          "time" : 90000,
                          "sign" : 0,
                          "interval" : [ 0, 1 ]
                        } ]
                      } ]
                    }
                  },
                  "Partial success" : {
                    "value" : {
                      "status" : "ok",
                      "resolvedBucket" : "wd_am",
                      "routes" : [ {
                        "profile" : "foot_fast",
                        "distanceMeters" : 120,
                        "timeMillis" : 90000,
                        "geometry" : {
                          "type" : "LineString",
                          "coordinates" : [ [ 8.54, 47.37 ], [ 8.541, 47.371 ] ]
                        },
                        "instructions" : [ {
                          "text" : "Continue",
                          "distance" : 120,
                          "time" : 90000,
                          "sign" : 0,
                          "interval" : [ 0, 1 ]
                        } ]
                      } ],
                      "routeErrors" : [ {
                        "profile" : "foot_green",
                        "code" : "NO_ROUTE",
                        "message" : "No route found"
                      } ]
                    }
                  },
                  "No route" : {
                    "value" : {
                      "status" : "no_route",
                      "resolvedBucket" : "wd_am",
                      "routes" : [ ],
                      "routeErrors" : [ {
                        "profile" : "foot_green",
                        "code" : "NO_ROUTE",
                        "message" : "No route found"
                      } ]
                    }
                  }
                }
              }
            }
          },
          "400" : {
            "description" : "Invalid routing input or undecodable JSON. Routing validation uses a string code; the framework JSON-decoding response uses numeric code 400.",
            "content" : {
              "application/json" : {
                "schema" : {
                  "oneOf" : [ {
                    "$ref" : "#/components/schemas/FacadeValidationError"
                  }, {
                    "$ref" : "#/components/schemas/JsonDecodingError"
                  } ]
                },
                "examples" : {
                  "Validation error" : {
                    "value" : {
                      "status" : "error",
                      "code" : "INVALID_REQUEST",
                      "message" : "Unknown profile: unknown"
                    }
                  },
                  "Malformed JSON" : {
                    "value" : {
                      "code" : 400,
                      "message" : "Unable to process JSON"
                    }
                  }
                }
              }
            }
          },
          "500" : {
            "description" : "Misconfigured profile catalog or unexpected server error",
            "content" : {
              "application/json" : {
                "schema" : {
                  "$ref" : "#/components/schemas/FacadeInternalError"
                }
              }
            }
          }
        },
        "deprecated" : true
      }
    }
  },
  "components" : {
    "schemas" : {
      "BaselineComparison" : {
        "description" : "Internal diagnostic comparison with the configured baseline profile, emitted only for measurement tooling.",
        "properties" : {
          "baselineProfile" : {
            "type" : "string",
            "description" : "Configured baseline product profile id"
          },
          "lengthRatio" : {
            "type" : "number",
            "format" : "double",
            "description" : "Candidate distance divided by baseline distance"
          },
          "geometryOverlap" : {
            "type" : "number",
            "format" : "double",
            "description" : "Fraction of candidate geometry within the configured tolerance of the baseline geometry"
          }
        }
      },
      "Geometry" : {
        "properties" : {
          "type" : {
            "type" : "string",
            "enum" : [ "LineString" ]
          },
          "coordinates" : {
            "type" : "array",
            "items" : {
              "$ref" : "#/components/schemas/ResponseCoordinate"
            }
          }
        },
        "required" : [ "type", "coordinates" ]
      },
      "Instruction" : {
        "properties" : {
          "text" : {
            "type" : "string"
          },
          "distance" : {
            "type" : "number",
            "description" : "Meters"
          },
          "time" : {
            "type" : "integer",
            "description" : "Milliseconds"
          },
          "sign" : {
            "type" : "integer",
            "format" : "int32"
          },
          "interval" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Zero-based geometry coordinate index"
            },
            "minItems" : 2,
            "maxItems" : 2,
            "description" : "Inclusive [first, last] geometry coordinate indices."
          }
        },
        "required" : [ "text", "distance", "time", "sign", "interval" ]
      },
      "LivemapRouteResponse" : {
        "properties" : {
          "status" : {
            "type" : "string",
            "enum" : [ "ok", "no_route" ],
            "description" : "ok when at least one route survives, including partial success; no_route otherwise."
          },
          "resolvedBucket" : {
            "$ref" : "#/components/schemas/ResolvedBucket"
          },
          "routes" : {
            "type" : "array",
            "items" : {
              "$ref" : "#/components/schemas/RouteResult"
            }
          },
          "routeErrors" : {
            "type" : "array",
            "items" : {
              "$ref" : "#/components/schemas/RouteError"
            }
          },
          "omittedVariants" : {
            "type" : "array",
            "items" : {
              "$ref" : "#/components/schemas/OmittedVariant"
            }
          }
        },
        "required" : [ "status", "resolvedBucket", "routes" ],
        "oneOf" : [ {
          "type" : "object",
          "properties" : {
            "status" : {
              "type" : "string",
              "enum" : [ "ok" ]
            },
            "routes" : {
              "type" : "array",
              "items" : {
                "$ref" : "#/components/schemas/RouteResult"
              },
              "minItems" : 1
            }
          },
          "required" : [ "status", "routes" ]
        }, {
          "type" : "object",
          "properties" : {
            "status" : {
              "type" : "string",
              "enum" : [ "no_route" ]
            },
            "routes" : {
              "type" : "array",
              "items" : {
                "$ref" : "#/components/schemas/RouteResult"
              },
              "maxItems" : 0
            }
          },
          "required" : [ "status", "routes" ]
        } ]
      },
      "OmittedVariant" : {
        "properties" : {
          "profile" : {
            "type" : "string"
          },
          "reason" : {
            "type" : "string"
          },
          "lengthRatio" : {
            "type" : "number",
            "format" : "double"
          },
          "geometryOverlap" : {
            "type" : "number",
            "format" : "double"
          }
        },
        "required" : [ "profile", "reason" ]
      },
      "RouteError" : {
        "properties" : {
          "profile" : {
            "type" : "string"
          },
          "code" : {
            "type" : "string"
          },
          "message" : {
            "type" : "string"
          }
        },
        "required" : [ "profile", "code", "message" ]
      },
      "RouteResult" : {
        "properties" : {
          "profile" : {
            "type" : "string"
          },
          "distanceMeters" : {
            "type" : "number",
            "description" : "Meters"
          },
          "timeMillis" : {
            "type" : "integer",
            "description" : "Milliseconds"
          },
          "geometry" : {
            "$ref" : "#/components/schemas/Geometry"
          },
          "instructions" : {
            "type" : "array",
            "items" : {
              "$ref" : "#/components/schemas/Instruction"
            }
          },
          "details" : {
            "type" : "object",
            "additionalProperties" : {
              "type" : "array",
              "items" : {
                "type" : "array",
                "items" : { },
                "minItems" : 3,
                "maxItems" : 3,
                "prefixItems" : [ {
                  "type" : "integer",
                  "description" : "First geometry index"
                }, {
                  "type" : "integer",
                  "description" : "Last geometry index"
                }, { } ]
              }
            },
            "description" : "Requested path detail names map to [first index, last index, value] intervals."
          },
          "debug" : {
            "type" : "object",
            "properties" : {
              "baseProfile" : {
                "type" : "string"
              },
              "resolvedBucket" : {
                "$ref" : "#/components/schemas/ResolvedBucket"
              },
              "priority" : {
                "type" : "array",
                "items" : {
                  "type" : "string"
                }
              }
            },
            "required" : [ "baseProfile", "resolvedBucket", "priority" ]
          },
          "baselineComparison" : {
            "$ref" : "#/components/schemas/BaselineComparison"
          }
        },
        "required" : [ "profile", "distanceMeters", "timeMillis", "geometry", "instructions" ]
      },
      "LivemapErrorResponse" : {
        "properties" : {
          "status" : {
            "type" : "string",
            "enum" : [ "error" ]
          },
          "code" : {
            "type" : "string"
          },
          "message" : {
            "type" : "string",
            "description" : "Exception message; omitted when the exception has no message."
          }
        },
        "required" : [ "status", "code" ]
      },
      "LivemapRouteRequest" : {
        "description" : "v1 multi-profile route request.",
        "properties" : {
          "points" : {
            "type" : "array",
            "description" : "Ordered waypoints as [longitude, latitude] pairs (at least 2). Each pair has exactly two finite numbers: longitude in [-180, 180], latitude in [-90, 90].",
            "example" : [ [ 8.5417, 47.3769 ], [ 8.55, 47.38 ] ],
            "items" : {
              "type" : "array",
              "items" : {
                "type" : "number",
                "description" : "WGS84 degrees"
              },
              "minItems" : 2,
              "maxItems" : 2,
              "description" : "Exactly [longitude, latitude], WGS84 degrees.",
              "prefixItems" : [ {
                "type" : "number",
                "description" : "Longitude",
                "minimum" : -180,
                "maximum" : 180
              }, {
                "type" : "number",
                "description" : "Latitude",
                "minimum" : -90,
                "maximum" : 90
              } ]
            },
            "minItems" : 2
          },
          "profiles" : {
            "type" : "array",
            "description" : "Product profile ids to route, at least one. The authoritative list is served by GET /api/v1/routing/profiles; an entry flagged `deprecated` there still routes and names its replacements in `superseded_by`. An unknown id is a 400.",
            "example" : [ "foot_fast", "foot_lowcrash" ],
            "items" : {
              "type" : "string",
              "minLength" : 1
            },
            "minItems" : 1
          },
          "bucket" : {
            "type" : "string",
            "default" : "auto",
            "description" : "Temporal safety/presence bucket. \"auto\" resolves against Europe/Zurich wall-clock time (weekday/weekend x morning/afternoon/night).",
            "enum" : [ "auto", "wd_am", "wd_pm", "wd_nt", "we_am", "we_pm", "we_nt" ]
          },
          "debug" : {
            "type" : "boolean",
            "default" : false,
            "description" : "Internal direct-use only; the frontend API need not forward this."
          },
          "details" : {
            "type" : "boolean",
            "default" : false,
            "description" : "When true, each route carries a details object with per-edge path details (edge_id, osm_way_id, road_class, lm_* dims at the resolved bucket)."
          }
        },
        "required" : [ "points", "profiles" ]
      },
      "ResponseCoordinate" : {
        "type" : "array",
        "items" : {
          "type" : "number",
          "description" : "WGS84 degrees"
        },
        "minItems" : 2,
        "maxItems" : 2,
        "description" : "Exactly [longitude, latitude], WGS84 degrees.",
        "prefixItems" : [ {
          "type" : "number",
          "description" : "Longitude",
          "minimum" : -180,
          "maximum" : 180
        }, {
          "type" : "number",
          "description" : "Latitude",
          "minimum" : -90,
          "maximum" : 90
        } ]
      },
      "ResolvedBucket" : {
        "type" : "string",
        "enum" : [ "wd_am", "wd_pm", "wd_nt", "we_am", "we_pm", "we_nt" ]
      },
      "ProfileWeights" : {
        "type" : "object",
        "properties" : {
          "tree" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "lights" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "accident" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "crime" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "presence" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "noise" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "water" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "green" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "incline" : {
            "type" : "number",
            "description" : "Preference weight"
          },
          "main_roads" : {
            "type" : "number",
            "description" : "Preference weight"
          }
        },
        "required" : [ "tree", "lights", "accident", "crime", "presence", "noise", "water", "green", "incline", "main_roads" ]
      },
      "ProfileV1" : {
        "type" : "object",
        "properties" : {
          "base_profile" : {
            "type" : "string"
          },
          "weights" : {
            "$ref" : "#/components/schemas/ProfileWeights"
          },
          "deprecated" : {
            "type" : "boolean",
            "enum" : [ true ],
            "description" : "Present only when deprecated; omission means active."
          },
          "superseded_by" : {
            "type" : "array",
            "items" : {
              "type" : "string"
            },
            "description" : "Replacement product IDs; omitted when empty."
          },
          "sunset" : {
            "type" : "string",
            "format" : "date",
            "description" : "Agreed removal date, YYYY-MM-DD; absent until agreed, including on deprecated profiles."
          }
        },
        "required" : [ "base_profile", "weights" ]
      },
      "ProfileV2" : {
        "type" : "object",
        "properties" : {
          "base_profile" : {
            "type" : "string"
          },
          "weights" : {
            "$ref" : "#/components/schemas/ProfileWeights"
          },
          "deprecated" : {
            "type" : "boolean",
            "enum" : [ true ],
            "description" : "Present only when deprecated; omission means active."
          },
          "superseded_by" : {
            "type" : "array",
            "items" : {
              "type" : "string"
            },
            "description" : "Replacement product IDs; omitted when empty."
          },
          "sunset" : {
            "type" : "string",
            "format" : "date",
            "description" : "Agreed removal date, YYYY-MM-DD; absent until agreed, including on deprecated profiles."
          },
          "noise" : {
            "$ref" : "#/components/schemas/ProfilePolicy_noise"
          },
          "lights" : {
            "$ref" : "#/components/schemas/ProfilePolicy_lights"
          },
          "green" : {
            "$ref" : "#/components/schemas/ProfilePolicy_green"
          },
          "water" : {
            "$ref" : "#/components/schemas/ProfilePolicy_water"
          },
          "tree" : {
            "$ref" : "#/components/schemas/ProfilePolicy_tree"
          },
          "accident" : {
            "$ref" : "#/components/schemas/ProfilePolicy_accident"
          },
          "ordinal" : {
            "$ref" : "#/components/schemas/ProfilePolicy_ordinal"
          },
          "incline" : {
            "$ref" : "#/components/schemas/ProfilePolicy_incline"
          },
          "main_roads" : {
            "$ref" : "#/components/schemas/ProfilePolicy_main_roads"
          }
        },
        "required" : [ "base_profile", "weights", "noise", "lights", "green", "water", "tree", "accident", "ordinal", "incline", "main_roads" ]
      },
      "ProfilePolicy_noise" : {
        "type" : "object",
        "properties" : {
          "source" : {
            "type" : "string",
            "enum" : [ "ordinal", "raw" ]
          },
          "thresholds" : {
            "type" : "object",
            "properties" : {
              "day" : {
                "type" : "array",
                "items" : {
                  "type" : "number",
                  "description" : "Configured policy value"
                }
              },
              "night" : {
                "type" : "array",
                "items" : {
                  "type" : "number",
                  "description" : "Configured policy value"
                }
              }
            },
            "required" : [ "day", "night" ]
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          },
          "min_receiver_count" : {
            "type" : "integer",
            "description" : "Configured policy value"
          },
          "evidence_kind_factors" : {
            "type" : "object",
            "properties" : {
              "direct_p90" : {
                "anyOf" : [ {
                  "type" : "number",
                  "description" : "Evidence attenuation factor"
                }, {
                  "type" : "null"
                } ]
              },
              "los_ring_p90" : {
                "anyOf" : [ {
                  "type" : "number",
                  "description" : "Evidence attenuation factor"
                }, {
                  "type" : "null"
                } ]
              },
              "ring_p90_occluded" : {
                "anyOf" : [ {
                  "type" : "number",
                  "description" : "Evidence attenuation factor"
                }, {
                  "type" : "null"
                } ]
              },
              "no_receiver_in_range" : {
                "type" : "number",
                "description" : "Configured policy value"
              },
              "out_of_source_extent" : {
                "type" : "number",
                "description" : "Configured policy value"
              }
            },
            "required" : [ "direct_p90", "los_ring_p90", "ring_p90_occluded", "no_receiver_in_range", "out_of_source_extent" ]
          }
        },
        "required" : [ "source", "thresholds", "full_weight_targets", "min_receiver_count", "evidence_kind_factors" ]
      },
      "ProfilePolicy_lights" : {
        "type" : "object",
        "properties" : {
          "source" : {
            "anyOf" : [ {
              "type" : "string",
              "enum" : [ "ordinal", "lit_fraction_bands" ]
            }, {
              "type" : "null"
            } ]
          },
          "bands_pct" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Configured policy value"
            }
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "source", "bands_pct", "full_weight_targets" ]
      },
      "ProfilePolicy_green" : {
        "type" : "object",
        "properties" : {
          "source" : {
            "type" : "string",
            "enum" : [ "ordinal", "raw_fraction" ]
          },
          "thresholds_pct" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Configured policy value"
            }
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "source", "thresholds_pct", "full_weight_targets" ]
      },
      "ProfilePolicy_water" : {
        "type" : "object",
        "properties" : {
          "source" : {
            "type" : "string",
            "enum" : [ "ordinal", "raw_fraction" ]
          },
          "thresholds_pct" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Configured policy value"
            }
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "source", "thresholds_pct", "full_weight_targets" ]
      },
      "ProfilePolicy_tree" : {
        "type" : "object",
        "properties" : {
          "source" : {
            "type" : "string",
            "enum" : [ "ordinal", "raw_fraction" ]
          },
          "thresholds_pct" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Configured policy value"
            }
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "source", "thresholds_pct", "full_weight_targets" ]
      },
      "ProfilePolicy_accident" : {
        "type" : "object",
        "properties" : {
          "source" : {
            "type" : "string",
            "enum" : [ "ordinal", "raw_counts" ]
          },
          "severity_weights" : {
            "type" : "object",
            "properties" : {
              "fatal" : {
                "type" : "number",
                "description" : "Configured policy value"
              },
              "serious" : {
                "type" : "number",
                "description" : "Configured policy value"
              },
              "total" : {
                "type" : "number",
                "description" : "Configured policy value"
              }
            },
            "required" : [ "fatal", "serious", "total" ]
          },
          "predicate" : {
            "type" : "object",
            "properties" : {
              "min_fatal" : {
                "type" : "integer",
                "description" : "Configured policy value"
              },
              "min_serious" : {
                "type" : "integer",
                "description" : "Configured policy value"
              },
              "min_total" : {
                "type" : "integer",
                "description" : "Configured policy value"
              }
            },
            "required" : [ "min_fatal", "min_serious", "min_total" ]
          },
          "severity_threshold" : {
            "type" : "number",
            "description" : "Configured policy value"
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "source", "severity_weights", "predicate", "severity_threshold", "full_weight_targets" ]
      },
      "ProfilePolicy_ordinal" : {
        "type" : "object",
        "properties" : {
          "thresholds" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Configured policy value"
            }
          },
          "penalty_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          },
          "reward_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "thresholds", "penalty_targets", "reward_targets" ]
      },
      "ProfilePolicy_incline" : {
        "type" : "object",
        "properties" : {
          "thresholds_pct" : {
            "type" : "array",
            "items" : {
              "type" : "integer",
              "description" : "Configured policy value"
            }
          },
          "full_weight_targets" : {
            "type" : "array",
            "items" : {
              "type" : "number",
              "description" : "Configured policy value"
            }
          }
        },
        "required" : [ "thresholds_pct", "full_weight_targets" ]
      },
      "ProfilePolicy_main_roads" : {
        "type" : "object",
        "properties" : {
          "full_weight_targets" : {
            "type" : "object",
            "properties" : {
              "trunk_primary" : {
                "type" : "number",
                "description" : "Configured policy value"
              },
              "secondary" : {
                "type" : "number",
                "description" : "Configured policy value"
              },
              "tertiary" : {
                "type" : "number",
                "description" : "Configured policy value"
              }
            },
            "required" : [ "trunk_primary", "secondary", "tertiary" ]
          }
        },
        "required" : [ "full_weight_targets" ]
      },
      "ProfileCatalogV1" : {
        "type" : "object",
        "additionalProperties" : {
          "$ref" : "#/components/schemas/ProfileV1"
        }
      },
      "ProfileCatalogV2" : {
        "type" : "object",
        "additionalProperties" : {
          "$ref" : "#/components/schemas/ProfileV2"
        }
      },
      "FacadeValidationError" : {
        "type" : "object",
        "properties" : {
          "status" : {
            "type" : "string",
            "enum" : [ "error" ]
          },
          "code" : {
            "type" : "string",
            "enum" : [ "INVALID_REQUEST" ]
          },
          "message" : {
            "type" : "string",
            "description" : "Exception message; omitted when the exception has no message."
          }
        },
        "required" : [ "status", "code" ]
      },
      "FacadeInternalError" : {
        "type" : "object",
        "properties" : {
          "status" : {
            "type" : "string",
            "enum" : [ "error" ]
          },
          "code" : {
            "type" : "string",
            "enum" : [ "INTERNAL_ERROR" ]
          },
          "message" : {
            "type" : "string",
            "description" : "Exception message; omitted when the exception has no message."
          }
        },
        "required" : [ "status", "code" ]
      },
      "JsonDecodingError" : {
        "type" : "object",
        "properties" : {
          "code" : {
            "type" : "integer",
            "enum" : [ 400 ]
          },
          "message" : {
            "type" : "string"
          }
        },
        "required" : [ "code", "message" ],
        "description" : "Framework response before routing validation when JSON cannot be decoded. Unlike routing errors, code is the numeric HTTP status."
      }
    }
  },
  "security" : [ ]
}