[{"data":1,"prerenderedAt":1939},["ShallowReactive",2],{"navigation":3,"\u002Fintegrations\u002Fweb\u002Foverview":335,"\u002Fintegrations\u002Fweb\u002Foverview-surround":1934},[4,27,73,95,121,135,305,331],{"title":5,"icon":6,"path":7,"stem":8,"children":9,"page":26},"Getting started","i-lucide-rocket","\u002Fgetting-started","1.getting-started",[10,14,18,22],{"title":11,"path":12,"stem":13},"Introduction","\u002Fgetting-started\u002Fintroduction","1.getting-started\u002F1.introduction",{"title":15,"path":16,"stem":17},"Installation","\u002Fgetting-started\u002Finstallation","1.getting-started\u002F2.installation",{"title":19,"path":20,"stem":21},"Quick start","\u002Fgetting-started\u002Fquick-start","1.getting-started\u002F3.quick-start",{"title":23,"path":24,"stem":25},"MSRV","\u002Fgetting-started\u002Fmsrv","1.getting-started\u002F9.msrv",false,{"title":28,"icon":29,"path":30,"stem":31,"children":32,"page":26},"Schemas","i-lucide-shapes","\u002Fschemas","2.schemas",[33,37,41,45,49,53,57,61,65,69],{"title":34,"path":35,"stem":36},"Strings","\u002Fschemas\u002Fstrings","2.schemas\u002F1.strings",{"title":38,"path":39,"stem":40},"Custom rules","\u002Fschemas\u002Frules","2.schemas\u002F10.rules",{"title":42,"path":43,"stem":44},"Numbers","\u002Fschemas\u002Fnumbers","2.schemas\u002F2.numbers",{"title":46,"path":47,"stem":48},"Booleans, literals and enums","\u002Fschemas\u002Fprimitives","2.schemas\u002F3.primitives",{"title":50,"path":51,"stem":52},"Dates and times","\u002Fschemas\u002Fdates","2.schemas\u002F4.dates",{"title":54,"path":55,"stem":56},"Collections","\u002Fschemas\u002Fcollections","2.schemas\u002F5.collections",{"title":58,"path":59,"stem":60},"Dynamic objects","\u002Fschemas\u002Fobjects","2.schemas\u002F6.objects",{"title":62,"path":63,"stem":64},"Modifiers","\u002Fschemas\u002Fmodifiers","2.schemas\u002F7.modifiers",{"title":66,"path":67,"stem":68},"Combinators","\u002Fschemas\u002Fcombinators","2.schemas\u002F8.combinators",{"title":70,"path":71,"stem":72},"Other types","\u002Fschemas\u002Fspecial-types","2.schemas\u002F9.special-types",{"title":74,"icon":75,"path":76,"stem":77,"children":78,"page":26},"Structs","i-lucide-braces","\u002Fstructs","3.structs",[79,83,87,91],{"title":80,"path":81,"stem":82},"schema! macro","\u002Fstructs\u002Fschema-macro","3.structs\u002F1.schema-macro",{"title":84,"path":85,"stem":86},"#[derive(Validate)]","\u002Fstructs\u002Fderive","3.structs\u002F2.derive",{"title":88,"path":89,"stem":90},"Parse vs validate","\u002Fstructs\u002Fparse-vs-validate","3.structs\u002F3.parse-vs-validate",{"title":92,"path":93,"stem":94},"Lenient parsing","\u002Fstructs\u002Flenient","3.structs\u002F4.lenient",{"title":96,"icon":97,"path":98,"stem":99,"children":100,"page":26},"Errors","i-lucide-triangle-alert","\u002Ferrors","4.errors",[101,105,109,113,117],{"title":102,"path":103,"stem":104},"Error model","\u002Ferrors\u002Foverview","4.errors\u002F1.overview",{"title":106,"path":107,"stem":108},"Issue codes","\u002Ferrors\u002Fissue-codes","4.errors\u002F2.issue-codes",{"title":110,"path":111,"stem":112},"Formatting","\u002Ferrors\u002Fformatting","4.errors\u002F3.formatting",{"title":114,"path":115,"stem":116},"Custom messages","\u002Ferrors\u002Fcustom-messages","4.errors\u002F4.custom-messages",{"title":118,"path":119,"stem":120},"Translations","\u002Ferrors\u002Fi18n","4.errors\u002F5.i18n",{"title":122,"icon":123,"path":124,"stem":125,"children":126,"page":26},"OpenAPI","i-lucide-file-json","\u002Fopenapi","5.openapi",[127,131],{"title":128,"path":129,"stem":130},"JSON Schema and OpenAPI","\u002Fopenapi\u002Fjson-schema","5.openapi\u002F1.json-schema",{"title":132,"path":133,"stem":134},"Schema diff","\u002Fopenapi\u002Fdiff","5.openapi\u002F2.diff",{"title":136,"icon":137,"path":138,"stem":139,"children":140,"page":26},"Integrations","i-lucide-plug","\u002Fintegrations","6.integrations",[141,191,209,223,245,259,273,291],{"title":142,"icon":143,"path":144,"stem":145,"children":146,"page":26},"Web frameworks","i-lucide-globe","\u002Fintegrations\u002Fweb","6.integrations\u002F1.web",[147,151,155,159,163,167,171,175,179,183,187],{"title":148,"path":149,"stem":150},"Web adapters overview","\u002Fintegrations\u002Fweb\u002Foverview","6.integrations\u002F1.web\u002F01.overview",{"title":152,"path":153,"stem":154},"vld-axum","\u002Fintegrations\u002Fweb\u002Faxum","6.integrations\u002F1.web\u002F02.axum",{"title":156,"path":157,"stem":158},"vld-actix","\u002Fintegrations\u002Fweb\u002Factix","6.integrations\u002F1.web\u002F03.actix",{"title":160,"path":161,"stem":162},"vld-ntex","\u002Fintegrations\u002Fweb\u002Fntex","6.integrations\u002F1.web\u002F04.ntex",{"title":164,"path":165,"stem":166},"vld-poem","\u002Fintegrations\u002Fweb\u002Fpoem","6.integrations\u002F1.web\u002F05.poem",{"title":168,"path":169,"stem":170},"vld-rama","\u002Fintegrations\u002Fweb\u002Frama","6.integrations\u002F1.web\u002F06.rama",{"title":172,"path":173,"stem":174},"vld-rocket","\u002Fintegrations\u002Fweb\u002Frocket","6.integrations\u002F1.web\u002F07.rocket",{"title":176,"path":177,"stem":178},"vld-salvo","\u002Fintegrations\u002Fweb\u002Fsalvo","6.integrations\u002F1.web\u002F08.salvo",{"title":180,"path":181,"stem":182},"vld-tower","\u002Fintegrations\u002Fweb\u002Ftower","6.integrations\u002F1.web\u002F09.tower",{"title":184,"path":185,"stem":186},"vld-warp","\u002Fintegrations\u002Fweb\u002Fwarp","6.integrations\u002F1.web\u002F10.warp",{"title":188,"path":189,"stem":190},"vld-tonic","\u002Fintegrations\u002Fweb\u002Ftonic","6.integrations\u002F1.web\u002F11.tonic",{"title":192,"icon":193,"path":194,"stem":195,"children":196,"page":26},"OpenAPI and JSON Schema","i-lucide-file-code","\u002Fintegrations\u002Fopenapi","6.integrations\u002F2.openapi",[197,201,205],{"title":198,"path":199,"stem":200},"vld-utoipa","\u002Fintegrations\u002Fopenapi\u002Futoipa","6.integrations\u002F2.openapi\u002F1.utoipa",{"title":202,"path":203,"stem":204},"vld-schemars","\u002Fintegrations\u002Fopenapi\u002Fschemars","6.integrations\u002F2.openapi\u002F2.schemars",{"title":206,"path":207,"stem":208},"vld-aide","\u002Fintegrations\u002Fopenapi\u002Faide","6.integrations\u002F2.openapi\u002F3.aide",{"title":210,"icon":211,"path":212,"stem":213,"children":214,"page":26},"Codegen and test data","i-lucide-wand","\u002Fintegrations\u002Fcodegen","6.integrations\u002F3.codegen",[215,219],{"title":216,"path":217,"stem":218},"vld-ts","\u002Fintegrations\u002Fcodegen\u002Fts","6.integrations\u002F3.codegen\u002F1.ts",{"title":220,"path":221,"stem":222},"vld-fake","\u002Fintegrations\u002Fcodegen\u002Ffake","6.integrations\u002F3.codegen\u002F2.fake",{"title":224,"icon":225,"path":226,"stem":227,"children":228,"page":26},"Databases","i-lucide-database","\u002Fintegrations\u002Fdatabase","6.integrations\u002F4.database",[229,233,237,241],{"title":230,"path":231,"stem":232},"vld-sqlx","\u002Fintegrations\u002Fdatabase\u002Fsqlx","6.integrations\u002F4.database\u002F1.sqlx",{"title":234,"path":235,"stem":236},"vld-diesel","\u002Fintegrations\u002Fdatabase\u002Fdiesel","6.integrations\u002F4.database\u002F2.diesel",{"title":238,"path":239,"stem":240},"vld-sea","\u002Fintegrations\u002Fdatabase\u002Fsea-orm","6.integrations\u002F4.database\u002F3.sea-orm",{"title":242,"path":243,"stem":244},"vld-surrealdb","\u002Fintegrations\u002Fdatabase\u002Fsurrealdb","6.integrations\u002F4.database\u002F4.surrealdb",{"title":246,"icon":247,"path":248,"stem":249,"children":250,"page":26},"Messaging","i-lucide-mail","\u002Fintegrations\u002Fmessaging","6.integrations\u002F5.messaging",[251,255],{"title":252,"path":253,"stem":254},"vld-redis","\u002Fintegrations\u002Fmessaging\u002Fredis","6.integrations\u002F5.messaging\u002F1.redis",{"title":256,"path":257,"stem":258},"vld-lapin","\u002Fintegrations\u002Fmessaging\u002Flapin","6.integrations\u002F5.messaging\u002F2.lapin",{"title":260,"icon":261,"path":262,"stem":263,"children":264,"page":26},"Config and CLI","i-lucide-terminal","\u002Fintegrations\u002Fconfig-cli","6.integrations\u002F6.config-cli",[265,269],{"title":266,"path":267,"stem":268},"vld-config","\u002Fintegrations\u002Fconfig-cli\u002Fconfig","6.integrations\u002F6.config-cli\u002F1.config",{"title":270,"path":271,"stem":272},"vld-clap","\u002Fintegrations\u002Fconfig-cli\u002Fclap","6.integrations\u002F6.config-cli\u002F2.clap",{"title":274,"icon":275,"path":276,"stem":277,"children":278,"page":26},"UI frameworks","i-lucide-monitor","\u002Fintegrations\u002Fui","6.integrations\u002F7.ui",[279,283,287],{"title":280,"path":281,"stem":282},"vld-dioxus","\u002Fintegrations\u002Fui\u002Fdioxus","6.integrations\u002F7.ui\u002F1.dioxus",{"title":284,"path":285,"stem":286},"vld-leptos","\u002Fintegrations\u002Fui\u002Fleptos","6.integrations\u002F7.ui\u002F2.leptos",{"title":288,"path":289,"stem":290},"vld-tauri","\u002Fintegrations\u002Fui\u002Ftauri","6.integrations\u002F7.ui\u002F3.tauri",{"title":292,"icon":293,"path":294,"stem":295,"children":296,"page":26},"Shared crates","i-lucide-package","\u002Fintegrations\u002Fshared","6.integrations\u002F8.shared",[297,301],{"title":298,"path":299,"stem":300},"vld-http-common","\u002Fintegrations\u002Fshared\u002Fhttp-common","6.integrations\u002F8.shared\u002F1.http-common",{"title":302,"path":303,"stem":304},"vld-integration-common","\u002Fintegrations\u002Fshared\u002Fintegration-common","6.integrations\u002F8.shared\u002F2.integration-common",{"title":306,"icon":307,"path":308,"stem":309,"children":310,"page":26},"Guides","i-lucide-book-open","\u002Fguides","7.guides",[311,315,319,323,327],{"title":312,"path":313,"stem":314},"Migration","\u002Fguides\u002Fmigration","7.guides\u002F1.migration",{"title":316,"path":317,"stem":318},"Security notes","\u002Fguides\u002Fsecurity","7.guides\u002F2.security",{"title":320,"path":321,"stem":322},"Performance","\u002Fguides\u002Fperformance","7.guides\u002F3.performance",{"title":324,"path":325,"stem":326},"Contributing","\u002Fguides\u002Fcontributing","7.guides\u002F4.contributing",{"title":328,"path":329,"stem":330},"FAQ","\u002Fguides\u002Ffaq","7.guides\u002F5.faq",{"title":332,"path":333,"stem":334},"Changelog","\u002Fchangelog","9.changelog",{"id":336,"title":148,"body":337,"description":1927,"extension":1928,"links":1929,"meta":1930,"navigation":1931,"path":149,"seo":1932,"stem":150,"__hash__":1933},"docs\u002F6.integrations\u002F1.web\u002F01.overview.md",{"type":338,"value":339,"toc":1914},"minimark",[340,355,385,390,798,812,816,896,910,913,961,965,972,1163,1206,1209,1245,1283,1287,1290,1390,1397,1435,1467,1472,1531,1535,1538,1541,1590,1593,1635,1639,1657,1856,1873,1876,1910],[341,342,343,344,350,351,354],"p",{},"All HTTP adapters are thin wrappers around ",[345,346,347],"a",{"href":299},[348,349,298],"code",{},": they read the request, turn it into a ",[348,352,353],{},"serde_json::Value",", validate it with your schema and convert failures into the same JSON error body. Behaviour is checked by one shared conformance suite, so switching frameworks does not change what clients see.",[341,356,357,358,361,362,365,366,371,372,376,377,380,381,384],{},"Any type that implements ",[348,359,360],{},"VldParse"," works as the extractor's ",[348,363,364],{},"T",": a ",[345,367,368],{"href":81},[348,369,370],{},"vld::schema!"," struct, a ",[345,373,374],{"href":85},[348,375,84],{}," struct, or one built with ",[348,378,379],{},"impl_rules!",". No ",[348,382,383],{},"serde::Deserialize"," is needed.",[386,387,389],"h2",{"id":388},"extractors","Extractors",[391,392,393,424],"table",{},[394,395,396],"thead",{},[397,398,399,403,406,409,412,415,418,421],"tr",{},[400,401,402],"th",{},"Crate",[400,404,405],{},"JSON body",[400,407,408],{},"Query",[400,410,411],{},"Path",[400,413,414],{},"Form",[400,416,417],{},"Headers",[400,419,420],{},"Cookies",[400,422,423],{},"Extra",[425,426,427,469,506,542,578,618,655,689,735,762],"tbody",{},[397,428,429,436,441,446,451,456,461,466],{},[430,431,432],"td",{},[345,433,434],{"href":153},[348,435,152],{},[430,437,438],{},[348,439,440],{},"VldJson",[430,442,443],{},[348,444,445],{},"VldQuery",[430,447,448],{},[348,449,450],{},"VldPath",[430,452,453],{},[348,454,455],{},"VldForm",[430,457,458],{},[348,459,460],{},"VldHeaders",[430,462,463],{},[348,464,465],{},"VldCookie",[430,467,468],{},"—",[397,470,471,477,481,485,489,493,497,501],{},[430,472,473],{},[345,474,475],{"href":157},[348,476,156],{},[430,478,479],{},[348,480,440],{},[430,482,483],{},[348,484,445],{},[430,486,487],{},[348,488,450],{},[430,490,491],{},[348,492,455],{},[430,494,495],{},[348,496,460],{},[430,498,499],{},[348,500,465],{},[430,502,503],{},[348,504,505],{},"VldBodyLimit",[397,507,508,514,518,522,526,530,534,538],{},[430,509,510],{},[345,511,512],{"href":161},[348,513,160],{},[430,515,516],{},[348,517,440],{},[430,519,520],{},[348,521,445],{},[430,523,524],{},[348,525,450],{},[430,527,528],{},[348,529,455],{},[430,531,532],{},[348,533,460],{},[430,535,536],{},[348,537,465],{},[430,539,540],{},[348,541,505],{},[397,543,544,550,554,558,562,566,570,574],{},[430,545,546],{},[345,547,548],{"href":165},[348,549,164],{},[430,551,552],{},[348,553,440],{},[430,555,556],{},[348,557,445],{},[430,559,560],{},[348,561,450],{},[430,563,564],{},[348,565,455],{},[430,567,568],{},[348,569,460],{},[430,571,572],{},[348,573,465],{},[430,575,576],{},[348,577,505],{},[397,579,580,586,590,594,598,602,606,610],{},[430,581,582],{},[345,583,584],{"href":169},[348,585,168],{},[430,587,588],{},[348,589,440],{},[430,591,592],{},[348,593,445],{},[430,595,596],{},[348,597,450],{},[430,599,600],{},[348,601,455],{},[430,603,604],{},[348,605,460],{},[430,607,608],{},[348,609,465],{},[430,611,612,615,616],{},[348,613,614],{},"ValidateJsonLayer",", ",[348,617,505],{},[397,619,620,626,630,634,638,642,646,650],{},[430,621,622],{},[345,623,624],{"href":173},[348,625,172],{},[430,627,628],{},[348,629,440],{},[430,631,632],{},[348,633,445],{},[430,635,636],{},[348,637,450],{},[430,639,640],{},[348,641,455],{},[430,643,644],{},[348,645,460],{},[430,647,648],{},[348,649,465],{},[430,651,652],{},[348,653,654],{},"vld_catchers()",[397,656,657,663,667,671,675,679,683,687],{},[430,658,659],{},[345,660,661],{"href":177},[348,662,176],{},[430,664,665],{},[348,666,440],{},[430,668,669],{},[348,670,445],{},[430,672,673],{},[348,674,450],{},[430,676,677],{},[348,678,455],{},[430,680,681],{},[348,682,460],{},[430,684,685],{},[348,686,465],{},[430,688,468],{},[397,690,691,697,702,707,715,720,725,730],{},[430,692,693],{},[345,694,695],{"href":185},[348,696,184],{},[430,698,699],{},[348,700,701],{},"vld_json",[430,703,704],{},[348,705,706],{},"vld_query",[430,708,709,615,712],{},[348,710,711],{},"vld_param",[348,713,714],{},"vld_path",[430,716,717],{},[348,718,719],{},"vld_form",[430,721,722],{},[348,723,724],{},"vld_headers",[430,726,727],{},[348,728,729],{},"vld_cookie",[430,731,732],{},[348,733,734],{},"handle_rejection",[397,736,737,743,747,749,751,753,755,757],{},[430,738,739],{},[345,740,741],{"href":181},[348,742,180],{},[430,744,745],{},[348,746,614],{},[430,748,468],{},[430,750,468],{},[430,752,468],{},[430,754,468],{},[430,756,468],{},[430,758,759],{},[348,760,761],{},"validated()",[397,763,764,770,779,781,783,785,791,793],{},[430,765,766],{},[345,767,768],{"href":189},[348,769,188],{},[430,771,772,773,615,776],{},"messages: ",[348,774,775],{},"validate",[348,777,778],{},"validate_with",[430,780,468],{},[430,782,468],{},[430,784,468],{},[430,786,787,788],{},"metadata: ",[348,789,790],{},"validate_metadata",[430,792,468],{},[430,794,795],{},[348,796,797],{},"metadata_interceptor",[341,799,800,802,803,805,806,808,809,811],{},[348,801,180],{}," and ",[348,804,614],{}," in ",[348,807,168],{}," are middleware: they validate the JSON body before your handler runs and store the result in the request extensions. ",[348,810,188],{}," works with gRPC messages and metadata instead of HTTP requests.",[386,813,815],{"id":814},"status-codes","Status codes",[391,817,818,828],{},[394,819,820],{},[397,821,822,825],{},[400,823,824],{},"Status",[400,826,827],{},"When",[425,829,830,842,858,885],{},[397,831,832,839],{},[430,833,834,838],{},[835,836,837],"strong",{},"200"," (your handler)",[430,840,841],{},"The value passed the schema.",[397,843,844,850],{},[430,845,846,849],{},[835,847,848],{},"413"," Payload Too Large",[430,851,852,853,857],{},"A JSON or form body is larger than the ",[345,854,856],{"href":855},"#body-limits","body limit",".",[397,859,860,866],{},[430,861,862,865],{},[835,863,864],{},"415"," Unsupported Media Type",[430,867,868,869,872,873,876,877,880,881,884],{},"A JSON extractor got a ",[348,870,871],{},"Content-Type"," other than ",[348,874,875],{},"application\u002Fjson"," or ",[348,878,879],{},"application\u002F*+json",", or a form extractor got something other than ",[348,882,883],{},"application\u002Fx-www-form-urlencoded"," (a missing header counts as wrong).",[397,886,887,893],{},[430,888,889,892],{},[835,890,891],{},"422"," Unprocessable Entity",[430,894,895],{},"Validation failed, or the input could not be parsed at all: malformed JSON, a form body that is not UTF-8, more than 1000 form fields.",[341,897,898,899,902,903,905,906,909],{},"Media-type checks ignore case and parameters (",[348,900,901],{},"Application\u002FJSON; charset=utf-8"," is JSON). Malformed JSON is ",[835,904,891],{},", not 400: the body has the same shape as a validation error, with one ",[348,907,908],{},"parse_error"," issue at the root.",[341,911,912],{},"Framework-specific additions:",[914,915,916,935,943,950],"ul",{},[917,918,919,921,922,924,925,928,929,931,932,857],"li",{},[348,920,180],{}," and the ",[348,923,168],{}," layer ",[835,926,927],{},"pass non-JSON requests through"," untouched instead of answering 415; ",[348,930,761],{}," returns ",[348,933,934],{},"Option\u003CT>",[917,936,937,939,940,942],{},[348,938,184],{},"'s ",[348,941,734],{}," also maps warp's own rejections (404, 405, 400, 411, 415) and answers 500 for anything unknown.",[917,944,945,939,947,949],{},[348,946,172],{},[348,948,654],{}," adds JSON catchers for 400, 413, 415 and 422 (without them Rocket answers with its HTML error pages).",[917,951,952,931,954,957,958,857],{},[348,953,188],{},[348,955,956],{},"tonic::Status"," with code ",[348,959,960],{},"INVALID_ARGUMENT",[386,962,964],{"id":963},"error-body","Error body",[341,966,967,968,971],{},"Every 422 response has this shape (",[348,969,970],{},"Content-Type: application\u002Fjson","):",[973,974,979],"pre",{"className":975,"code":976,"language":977,"meta":978,"style":978},"language-json shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","{\n  \"error\": \"Validation failed\",\n  \"issues\": [\n    { \"path\": \".name\", \"message\": \"String must be at least 2 characters\", \"code\": \"too_small\" },\n    { \"path\": \".items[0].qty\", \"message\": \"Number must be at least 1\", \"code\": \"too_small\" }\n  ]\n}\n","json","",[348,980,981,990,1018,1033,1095,1151,1157],{"__ignoreMap":978},[982,983,986],"span",{"class":984,"line":985},"line",1,[982,987,989],{"class":988},"sMK4o","{\n",[982,991,993,996,1000,1003,1006,1009,1013,1015],{"class":984,"line":992},2,[982,994,995],{"class":988},"  \"",[982,997,999],{"class":998},"spNyl","error",[982,1001,1002],{"class":988},"\"",[982,1004,1005],{"class":988},":",[982,1007,1008],{"class":988}," \"",[982,1010,1012],{"class":1011},"sfazB","Validation failed",[982,1014,1002],{"class":988},[982,1016,1017],{"class":988},",\n",[982,1019,1021,1023,1026,1028,1030],{"class":984,"line":1020},3,[982,1022,995],{"class":988},[982,1024,1025],{"class":998},"issues",[982,1027,1002],{"class":988},[982,1029,1005],{"class":988},[982,1031,1032],{"class":988}," [\n",[982,1034,1036,1039,1041,1045,1047,1049,1051,1054,1056,1059,1061,1064,1066,1068,1070,1073,1075,1077,1079,1081,1083,1085,1087,1090,1092],{"class":984,"line":1035},4,[982,1037,1038],{"class":988},"    {",[982,1040,1008],{"class":988},[982,1042,1044],{"class":1043},"sBMFI","path",[982,1046,1002],{"class":988},[982,1048,1005],{"class":988},[982,1050,1008],{"class":988},[982,1052,1053],{"class":1011},".name",[982,1055,1002],{"class":988},[982,1057,1058],{"class":988},",",[982,1060,1008],{"class":988},[982,1062,1063],{"class":1043},"message",[982,1065,1002],{"class":988},[982,1067,1005],{"class":988},[982,1069,1008],{"class":988},[982,1071,1072],{"class":1011},"String must be at least 2 characters",[982,1074,1002],{"class":988},[982,1076,1058],{"class":988},[982,1078,1008],{"class":988},[982,1080,348],{"class":1043},[982,1082,1002],{"class":988},[982,1084,1005],{"class":988},[982,1086,1008],{"class":988},[982,1088,1089],{"class":1011},"too_small",[982,1091,1002],{"class":988},[982,1093,1094],{"class":988}," },\n",[982,1096,1098,1100,1102,1104,1106,1108,1110,1113,1115,1117,1119,1121,1123,1125,1127,1130,1132,1134,1136,1138,1140,1142,1144,1146,1148],{"class":984,"line":1097},5,[982,1099,1038],{"class":988},[982,1101,1008],{"class":988},[982,1103,1044],{"class":1043},[982,1105,1002],{"class":988},[982,1107,1005],{"class":988},[982,1109,1008],{"class":988},[982,1111,1112],{"class":1011},".items[0].qty",[982,1114,1002],{"class":988},[982,1116,1058],{"class":988},[982,1118,1008],{"class":988},[982,1120,1063],{"class":1043},[982,1122,1002],{"class":988},[982,1124,1005],{"class":988},[982,1126,1008],{"class":988},[982,1128,1129],{"class":1011},"Number must be at least 1",[982,1131,1002],{"class":988},[982,1133,1058],{"class":988},[982,1135,1008],{"class":988},[982,1137,348],{"class":1043},[982,1139,1002],{"class":988},[982,1141,1005],{"class":988},[982,1143,1008],{"class":988},[982,1145,1089],{"class":1011},[982,1147,1002],{"class":988},[982,1149,1150],{"class":988}," }\n",[982,1152,1154],{"class":984,"line":1153},6,[982,1155,1156],{"class":988},"  ]\n",[982,1158,1160],{"class":984,"line":1159},7,[982,1161,1162],{"class":988},"}\n",[914,1164,1165,1182,1195],{},[917,1166,1167,1169,1170,1173,1174,1177,1178,1181],{},[348,1168,1044],{}," is ",[348,1171,1172],{},"\"\""," for the root (for example malformed JSON), ",[348,1175,1176],{},".field"," for object fields and ",[348,1179,1180],{},"[i]"," for array items.",[917,1183,1184,1186,1187,1190,1191,1194],{},[348,1185,1063],{}," is the issue message (default English, your ",[345,1188,1189],{"href":115},"custom message",", or a ",[345,1192,1193],{"href":119},"translation"," if you translate the error before responding).",[917,1196,1197,1199,1200,1205],{},[348,1198,348],{}," is the stable ",[345,1201,1202],{"href":107},[348,1203,1204],{},"IssueCode::key()"," — match on it in clients instead of on messages.",[341,1207,1208],{},"The other bodies:",[391,1210,1211,1220],{},[394,1212,1213],{},[397,1214,1215,1217],{},[400,1216,824],{},[400,1218,1219],{},"Body",[425,1221,1222,1231],{},[397,1223,1224,1226],{},[430,1225,848],{},[430,1227,1228],{},[348,1229,1230],{},"{\"error\": \"Payload too large\"}",[397,1232,1233,1235],{},[430,1234,864],{},[430,1236,1237,1240,1241,1244],{},[348,1238,1239],{},"{\"error\": \"Unsupported Media Type\", \"message\": \"Expected Content-Type: application\u002Fjson (or application\u002F*+json)\"}"," (forms: ",[348,1242,1243],{},"\"Expected Content-Type: application\u002Fx-www-form-urlencoded\"",")",[341,1246,1247,1248,615,1251,615,1254,615,1257,615,1260,615,1263,1266,1267,615,1270,802,1273,1276,1277,1282],{},"Each adapter's error type (",[348,1249,1250],{},"VldJsonRejection",[348,1252,1253],{},"VldActixError",[348,1255,1256],{},"VldNtexError",[348,1258,1259],{},"VldPoemError",[348,1261,1262],{},"VldSalvoError",[348,1264,1265],{},"VldRejection",") exposes ",[348,1268,1269],{},"status()",[348,1271,1272],{},"body()",[348,1274,1275],{},"error()"," (the underlying ",[345,1278,1279],{"href":103},[348,1280,1281],{},"VldError",") if you want to build your own response.",[386,1284,1286],{"id":1285},"text-values-and-coercion","Text values and coercion",[341,1288,1289],{},"Query strings, path segments, form fields, headers and cookies are text. The adapters convert each value with a lossless rule:",[391,1291,1292,1302],{},[394,1293,1294],{},[397,1295,1296,1299],{},[400,1297,1298],{},"Raw value",[400,1300,1301],{},"JSON value",[425,1303,1304,1318,1343,1359],{},[397,1305,1306,1315],{},[430,1307,1308,615,1311,1314],{},[348,1309,1310],{},"true",[348,1312,1313],{},"false"," (lowercase)",[430,1316,1317],{},"boolean",[397,1319,1320,1340],{},[430,1321,1322,1323,1326,1327,1330,1331,615,1334,615,1337,1244],{},"canonical integers that fit ",[348,1324,1325],{},"i64"," \u002F ",[348,1328,1329],{},"u64"," (",[348,1332,1333],{},"0",[348,1335,1336],{},"42",[348,1338,1339],{},"-7",[430,1341,1342],{},"number",[397,1344,1345,1357],{},[430,1346,1347,1348,1330,1351,615,1354,1244],{},"canonical decimals that round-trip through ",[348,1349,1350],{},"f64",[348,1352,1353],{},"3.14",[348,1355,1356],{},"-0.5",[430,1358,1342],{},[397,1360,1361,1387],{},[430,1362,1363,1364,615,1366,615,1369,615,1372,615,1375,615,1378,615,1381,1384,1385],{},"everything else: ",[348,1365,1172],{},[348,1367,1368],{},"null",[348,1370,1371],{},"01234",[348,1373,1374],{},"+1555",[348,1376,1377],{},"1e3",[348,1379,1380],{},"TRUE",[348,1382,1383],{},"1.50",", ids beyond ",[348,1386,1329],{},[430,1388,1389],{},"string",[341,1391,1392,1393,1396],{},"Then the value is validated with ",[348,1394,1395],{},"vld::schema::parse_coerced",", which repairs two common mismatches and retries:",[914,1398,1399,1419],{},[917,1400,1401,1402,1404,1405,1408,1409,1169,1412,615,1415,1418],{},"a field whose schema expects a ",[835,1403,1389],{}," but got a coerced number or boolean gets its original text back — ",[348,1406,1407],{},"?q=123"," into ",[348,1410,1411],{},"vld::string()",[348,1413,1414],{},"\"123\"",[348,1416,1417],{},"?zip=01234"," was never converted in the first place;",[917,1420,1421,1422,1425,1426,1408,1429,1169,1432,857],{},"a field whose schema expects an ",[835,1423,1424],{},"array"," but got a single value is wrapped — ",[348,1427,1428],{},"?tags=a",[348,1430,1431],{},"vld::array(vld::string())",[348,1433,1434],{},"[\"a\"]",[341,1436,1437,1438,1441,1442,615,1445,1441,1448,1451,1452,1455,1456,1459,1460,1463,1464,857],{},"So a schema describes the real types (",[348,1439,1440],{},"vld::number().int()"," for ",[348,1443,1444],{},"?page=2",[348,1446,1447],{},"vld::boolean()",[348,1449,1450],{},"?active=true",") and string fields keep working when the text happens to look numeric. JSON bodies are ",[835,1453,1454],{},"not"," coerced: ",[348,1457,1458],{},"{\"page\": \"2\"}"," fails ",[348,1461,1462],{},"vld::number()"," unless the schema calls ",[348,1465,1466],{},".coerce()",[1468,1469,1471],"h3",{"id":1470},"query-strings-and-forms","Query strings and forms",[914,1473,1474,1489,1499,1512,1528],{},[917,1475,1476,1477,1480,1481,1484,1485,1488],{},"Keys and values are form-decoded (",[348,1478,1479],{},"+"," is a space, ",[348,1482,1483],{},"%XX"," is decoded as UTF-8; invalid sequences become ",[348,1486,1487],{},"U+FFFD",").",[917,1490,1491,1492,1495,1496,857],{},"A repeated key becomes an array: ",[348,1493,1494],{},"?tag=a&tag=b"," → ",[348,1497,1498],{},"{\"tag\": [\"a\", \"b\"]}",[917,1500,1501,1502,1505,1506,1495,1509,857],{},"A key ending in ",[348,1503,1504],{},"[]"," is always an array: ",[348,1507,1508],{},"?tag[]=a",[348,1510,1511],{},"{\"tag\": [\"a\"]}",[917,1513,1514,1515,1330,1518,1521,1522,1525,1526,857],{},"A key without ",[348,1516,1517],{},"=",[348,1519,1520],{},"?flag",") and an empty value (",[348,1523,1524],{},"?x=",") are ",[348,1527,1172],{},[917,1529,1530],{},"Form bodies are parsed the same way and may have at most 1000 fields (more is a 422).",[1468,1532,1534],{"id":1533},"path-parameters","Path parameters",[341,1536,1537],{},"Path parameters are percent-decoded exactly once and coerced like query values. A route without parameters produces an empty object, so a schema whose fields are all optional still validates.",[1468,1539,417],{"id":1540},"headers",[914,1542,1543,1561,1581],{},[917,1544,1545,1546,1549,1550,1553,1554,1557,1558,857],{},"Names are lowercased and ",[348,1547,1548],{},"-"," becomes ",[348,1551,1552],{},"_",": ",[348,1555,1556],{},"X-Request-Id"," is the field ",[348,1559,1560],{},"x_request_id",[917,1562,1563,1569,1570,1573,1574,1577,1578,857],{},[835,1564,1565,1566,1568],{},"Header names that already contain ",[348,1567,1552],{}," are ignored."," Otherwise a client could send ",[348,1571,1572],{},"x_user: admin"," and fill the ",[348,1575,1576],{},"x_user"," field even behind a proxy that strips only ",[348,1579,1580],{},"X-User",[917,1582,1583,1584,1587,1588,857],{},"Repeated headers are joined with ",[348,1585,1586],{},"\", \""," before coercion. Non-UTF-8 bytes become ",[348,1589,1487],{},[1468,1591,420],{"id":1592},"cookies",[914,1594,1595,1602,1613],{},[917,1596,1597,1598,1601],{},"Every ",[348,1599,1600],{},"Cookie"," header is read (HTTP\u002F2 clients may send one header per cookie); they are joined before parsing.",[917,1603,1604,1330,1607,1495,1610,1612],{},[835,1605,1606],{},"The first occurrence of a name wins",[348,1608,1609],{},"sid=a; sid=b",[348,1611,345],{},"). Browsers send the most specific cookie first; letting a later one win would allow cookie tossing from a sibling subdomain.",[917,1614,1615,1616,1619,1620,1622,1623,805,1626,1631,1632,1634],{},"Names are used as-is (a cookie ",[348,1617,1618],{},"session-id"," needs a field named ",[348,1621,1618],{},", map it with ",[348,1624,1625],{},"as \"session-id\"",[345,1627,1628],{"href":81},[348,1629,1630],{},"schema!","). Values are unquoted, percent-decoded (",[348,1633,1479],{}," is kept) and coerced.",[386,1636,1638],{"id":1637},"body-limits","Body limits",[341,1640,1641,802,1643,1645,1646,1330,1649,1652,1653,1656],{},[348,1642,440],{},[348,1644,455],{}," never buffer more than the limit. The default everywhere is ",[835,1647,1648],{},"2 MiB",[348,1650,1651],{},"vld_http_common::DEFAULT_BODY_LIMIT",", the same as axum's ",[348,1654,1655],{},"DefaultBodyLimit","), regardless of the framework's own JSON default.",[391,1658,1659,1671],{},[394,1660,1661],{},[397,1662,1663,1665,1668],{},[400,1664,402],{},[400,1666,1667],{},"Default",[400,1669,1670],{},"How to change",[425,1672,1673,1690,1711,1729,1743,1765,1789,1814,1826,1842],{},[397,1674,1675,1679,1685],{},[430,1676,1677],{},[348,1678,152],{},[430,1680,1681,1682,1684],{},"axum ",[348,1683,1655],{}," (2 MiB)",[430,1686,1687],{},[348,1688,1689],{},".layer(axum::extract::DefaultBodyLimit::max(n))",[397,1691,1692,1696,1698],{},[430,1693,1694],{},[348,1695,156],{},[430,1697,1648],{},[430,1699,1700,1703,1704,1326,1707,1710],{},[348,1701,1702],{},"App::new().app_data(vld_actix::VldBodyLimit(n))"," — actix ",[348,1705,1706],{},"JsonConfig",[348,1708,1709],{},"PayloadConfig"," do not apply",[397,1712,1713,1717,1719],{},[430,1714,1715],{},[348,1716,160],{},[430,1718,1648],{},[430,1720,1721,1722,1725,1726],{},"ntex 4: ",[348,1723,1724],{},"App::new().with_config(WebAppConfig::new().set_state(VldBodyLimit(n)))","; ntex 3: ",[348,1727,1728],{},"App::new().state(VldBodyLimit(n))",[397,1730,1731,1735,1737],{},[430,1732,1733],{},[348,1734,164],{},[430,1736,1648],{},[430,1738,1739,1742],{},[348,1740,1741],{},".data(vld_poem::VldBodyLimit(n))"," on a route or endpoint",[397,1744,1745,1749,1751],{},[430,1746,1747],{},[348,1748,168],{},[430,1750,1648],{},[430,1752,1753,1754,1757,1758,1761,1762],{},"extractors: the ",[348,1755,1756],{},"vld_rama::VldBodyLimit(n)"," request extension (e.g. ",[348,1759,1760],{},"AddInputExtensionLayer","); layer: ",[348,1763,1764],{},"ValidateJsonLayer::with_limit(n)",[397,1766,1767,1771,1773],{},[430,1768,1769],{},[348,1770,172],{},[430,1772,1648],{},[430,1774,1775,1776,1326,1779,1330,1782,615,1785,1788],{},"Rocket ",[348,1777,1778],{},"limits.json",[348,1780,1781],{},"limits.form",[348,1783,1784],{},"Rocket.toml",[348,1786,1787],{},"ROCKET_LIMITS","); a limit left at Rocket's built-in value (1 MiB \u002F 32 KiB) counts as unset",[397,1790,1791,1795,1797],{},[430,1792,1793],{},[348,1794,176],{},[430,1796,1648],{},[430,1798,1799,1800,1330,1803,1806,1807,615,1810,1813],{},"Salvo's ",[348,1801,1802],{},"secure_max_size",[348,1804,1805],{},"SecureMaxSize"," middleware, ",[348,1808,1809],{},"Request::set_secure_max_size",[348,1811,1812],{},"set_global_secure_max_size","); Salvo's built-in 64 KiB counts as unset",[397,1815,1816,1820,1822],{},[430,1817,1818],{},[348,1819,180],{},[430,1821,1648],{},[430,1823,1824],{},[348,1825,1764],{},[397,1827,1828,1832,1834],{},[430,1829,1830],{},[348,1831,184],{},[430,1833,1648],{},[430,1835,1836,1326,1839],{},[348,1837,1838],{},"vld_json_limit::\u003CT>(n)",[348,1840,1841],{},"vld_form_limit::\u003CT>(n)",[397,1843,1844,1848,1850],{},[430,1845,1846],{},[348,1847,188],{},[430,1849,468],{},[430,1851,1852,1853],{},"tonic's own ",[348,1854,1855],{},"max_decoding_message_size",[341,1857,1858,1859,1861,1862,1865,1866,1868,1869,1872],{},"Compressed request bodies: ",[348,1860,156],{}," decodes ",[348,1863,1864],{},"Content-Encoding"," itself (the limit applies to the decoded size), ",[348,1867,160],{}," does with its ",[348,1870,1871],{},"compress"," feature, the other adapters see the body as the framework delivers it.",[386,1874,122],{"id":1875},"openapi",[341,1877,1878,1879,1883,1884,1888,1889,1893,1894,615,1897,615,1900,1903,1904,1906,1907,1909],{},"The adapters only validate. To document the same schemas, use ",[345,1880,1881],{"href":199},[348,1882,198],{}," (framework-agnostic), ",[345,1885,1886],{"href":207},[348,1887,206],{}," (aide, usually with axum) or ",[345,1890,1891],{"href":203},[348,1892,202],{},". The error body structs (",[348,1895,1896],{},"ValidationErrorBody",[348,1898,1899],{},"ErrorBody",[348,1901,1902],{},"ErrorWithMessage",") live in ",[348,1905,298],{}," and are ",[348,1908,370],{}," types, so they can be registered as response schemas too.",[1911,1912,1913],"style",{},"html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":978,"searchDepth":992,"depth":1020,"links":1915},[1916,1917,1918,1919,1925,1926],{"id":388,"depth":992,"text":389},{"id":814,"depth":992,"text":815},{"id":963,"depth":992,"text":964},{"id":1285,"depth":992,"text":1286,"children":1920},[1921,1922,1923,1924],{"id":1470,"depth":1020,"text":1471},{"id":1533,"depth":1020,"text":1534},{"id":1540,"depth":1020,"text":417},{"id":1592,"depth":1020,"text":420},{"id":1637,"depth":992,"text":1638},{"id":1875,"depth":992,"text":122},"What every vld web integration has in common — extractors, status codes, the error body, coercion, header and cookie rules, and body limits.","md",null,{},true,{"title":148,"description":1927},"VzTDYKbue8-B3aSu6f23_PvzMxnxEzttFi8-NMYaMEQ",[1935,1937],{"title":132,"path":133,"stem":134,"description":1936,"children":-1},"Detect breaking changes between two JSON Schemas with vld::diff.",{"title":152,"path":153,"stem":154,"description":1938,"children":-1},"Axum extractors that validate JSON bodies, query strings, path parameters, forms, headers and cookies with vld schemas.",1794036356983]