[{"data":1,"prerenderedAt":2762},["ShallowReactive",2],{"libs":3,"navigation-laravel-openapi-generator":115,"\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fresponses":296,"\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fresponses-surround":2757},[4,45,69,95],{"id":5,"color":6,"compatibility":7,"extension":20,"icon":21,"links":22,"meta":27,"name":28,"order":29,"package":30,"related":31,"stem":34,"tagline":35,"__hash__":36,"slug":37,"repository":38,"branch":39,"path":40,"collection":41,"entry":42,"home":43,"version":44},"laravel_json_api_meta\u002Fdocs\u002Fsite\u002Flib.yml","violet",[8,13,16],{"version":9,"php":10,"laravel":11,"status":12},"3.x","^8.3","^12.46 || ^13.0","active",{"version":14,"php":10,"laravel":11,"status":15},"2.x","eol",{"version":17,"php":18,"laravel":19,"status":15},"1.x","^8.1","^10.0 || ^11.0 || ^12.0 || ^13.0","yml","i-lucide-braces",[23],{"label":24,"to":25,"icon":26},"JSON:API 1.1","https:\u002F\u002Fjsonapi.org\u002Fformat\u002F","i-lucide-book-marked",{},"Laravel JSON:API",10,"ark4ne\u002Flaravel-json-api",[32,33],"laravel-api-revisions","laravel-openapi-generator","docs\u002Fsite\u002Flib","JSON:API 1.1 resources for Laravel, with typed values, validated includes and fieldsets, and API revisions.","ILGoVp9rzKYDQc18VV8kkXy3EQOQ8rv87JblFKXYDrU","laravel-json-api","Ark4ne\u002Flaravel-json-api","master","docs\u002Fsite","laravel_json_api","\u002Flaravel-json-api\u002Fgetting-started\u002Fintroduction","\u002Flaravel-json-api","v3.0.0",{"id":46,"color":47,"compatibility":48,"extension":20,"icon":50,"links":51,"meta":56,"name":57,"order":58,"package":59,"related":60,"stem":34,"tagline":61,"__hash__":62,"slug":32,"repository":63,"branch":64,"path":40,"collection":65,"entry":66,"home":67,"version":68},"laravel_api_revisions_meta\u002Fdocs\u002Fsite\u002Flib.yml","amber",[49],{"version":17,"php":10,"laravel":11,"status":12},"i-lucide-git-branch",[52],{"label":53,"to":54,"icon":55},"Agent skill","https:\u002F\u002Fgithub.com\u002FArk4ne\u002Flaravel-api-revisions\u002Ftree\u002Fmain\u002Fskills\u002Flaravel-api-revisions","i-lucide-bot",{},"Laravel API Revisions",20,"ark4ne\u002Flaravel-api-revisions",[37,33],"Typed schemas for Laravel resources and form requests, evolved through dated API revisions, Stripe-style.","w24MBVK4_XliIZ8nVcfnuT9OgR-m-Ytxz31Pxua_mLM","Ark4ne\u002Flaravel-api-revisions","main","laravel_api_revisions","\u002Flaravel-api-revisions\u002Fgetting-started\u002Fintroduction","\u002Flaravel-api-revisions","v1.0.0",{"id":70,"color":71,"compatibility":72,"extension":20,"icon":77,"links":78,"meta":82,"name":83,"order":84,"package":85,"related":86,"stem":34,"tagline":88,"__hash__":89,"slug":33,"repository":90,"branch":39,"path":40,"collection":91,"entry":92,"home":93,"version":94},"laravel_openapi_generator_meta\u002Fdocs\u002Fsite\u002Flib.yml","emerald",[73,75],{"version":17,"php":10,"laravel":74,"status":12},"^13.0",{"version":76,"php":18,"laravel":19,"status":15},"0.6","i-lucide-file-json",[79],{"label":80,"to":81,"icon":26},"OpenAPI Specification","https:\u002F\u002Fspec.openapis.org\u002Foas\u002Flatest.html",{},"Laravel OpenAPI Generator",30,"ark4ne\u002Flaravel-openapi-generator",[87,37,32],"openapi-writer","Generates OpenAPI 3.0, 3.1 and 3.2 documents from a Laravel application, its routes, form requests and resources.","DTt0SVqegMImLmWmwL8LCW5lxRCWFYcnBFOaquLpVwc","Ark4ne\u002Flaravel-openapi-generator","laravel_openapi_generator","\u002Flaravel-openapi-generator\u002Fgetting-started\u002Fintroduction","\u002Flaravel-openapi-generator","v1.2.0",{"id":96,"color":97,"compatibility":98,"extension":20,"icon":101,"links":102,"meta":104,"name":105,"order":106,"package":107,"related":108,"stem":34,"tagline":109,"__hash__":110,"slug":87,"repository":111,"branch":64,"path":40,"collection":112,"entry":113,"home":114,"version":68},"openapi_writer_meta\u002Fdocs\u002Fsite\u002Flib.yml","sky",[99],{"version":17,"php":100,"status":12},"^8.2","i-lucide-file-pen-line",[103],{"label":80,"to":81,"icon":26},{},"OpenAPI Writer",40,"ark4ne\u002Fopenapi-writer",[33],"Framework-agnostic, fluent and immutable PHP builder for OpenAPI 3.0, 3.1 and 3.2 documents, written as JSON or YAML and validated.","JFQcdQ9GEChOkfRKibLjoxZOfnt6HYNsayX2melOzMk","Ark4ne\u002Fopenapi-writer","openapi_writer","\u002Fopenapi-writer\u002Fgetting-started\u002Fintroduction","\u002Fopenapi-writer",[116,135,169,191,213,243,258,284],{"title":117,"since":118,"experimental":119,"icon":120,"path":121,"stem":122,"children":123,"page":119},"Getting started",null,false,"i-lucide-rocket","\u002Flaravel-openapi-generator\u002Fgetting-started","laravel-openapi-generator\u002F1.getting-started",[124,127,131],{"title":125,"path":92,"stem":126,"since":118,"experimental":119},"Introduction","laravel-openapi-generator\u002F1.getting-started\u002F1.introduction",{"title":128,"path":129,"stem":130,"since":118,"experimental":119},"Installation","\u002Flaravel-openapi-generator\u002Fgetting-started\u002Finstallation","laravel-openapi-generator\u002F1.getting-started\u002F2.installation",{"title":132,"path":133,"stem":134,"since":118,"experimental":119},"Quick start","\u002Flaravel-openapi-generator\u002Fgetting-started\u002Fquick-start","laravel-openapi-generator\u002F1.getting-started\u002F3.quick-start",{"title":136,"since":118,"experimental":119,"icon":137,"path":138,"stem":139,"children":140,"page":119},"Documenting endpoints","i-lucide-route","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints","laravel-openapi-generator\u002F2.documenting-endpoints",[141,145,149,153,157,161,165],{"title":142,"path":143,"stem":144,"since":118,"experimental":119},"How it works","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fhow-it-works","laravel-openapi-generator\u002F2.documenting-endpoints\u002F1.how-it-works",{"title":146,"path":147,"stem":148,"since":118,"experimental":119},"Routes & operations","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Froutes-and-operations","laravel-openapi-generator\u002F2.documenting-endpoints\u002F2.routes-and-operations",{"title":150,"path":151,"stem":152,"since":118,"experimental":119},"Requests","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Frequests","laravel-openapi-generator\u002F2.documenting-endpoints\u002F3.requests",{"title":154,"path":155,"stem":156,"since":118,"experimental":119},"Responses","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fresponses","laravel-openapi-generator\u002F2.documenting-endpoints\u002F4.responses",{"title":158,"path":159,"stem":160,"since":118,"experimental":119},"Sampling","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fsampling","laravel-openapi-generator\u002F2.documenting-endpoints\u002F5.sampling",{"title":162,"path":163,"stem":164,"since":118,"experimental":119},"Security & errors","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fsecurity-and-errors","laravel-openapi-generator\u002F2.documenting-endpoints\u002F6.security-and-errors",{"title":166,"path":167,"stem":168,"since":118,"experimental":119},"Webhooks & callbacks","\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fwebhooks-and-callbacks","laravel-openapi-generator\u002F2.documenting-endpoints\u002F7.webhooks-and-callbacks",{"title":170,"since":118,"experimental":119,"icon":171,"path":172,"stem":173,"children":174,"page":119},"Documents","i-lucide-files","\u002Flaravel-openapi-generator\u002Fdocuments","laravel-openapi-generator\u002F3.documents",[175,179,183,187],{"title":176,"path":177,"stem":178,"since":118,"experimental":119},"Configuring a document","\u002Flaravel-openapi-generator\u002Fdocuments\u002Fconfiguring-a-document","laravel-openapi-generator\u002F3.documents\u002F1.configuring-a-document",{"title":180,"path":181,"stem":182,"since":118,"experimental":119},"Several documents","\u002Flaravel-openapi-generator\u002Fdocuments\u002Fseveral-documents","laravel-openapi-generator\u002F3.documents\u002F2.several-documents",{"title":184,"path":185,"stem":186,"since":118,"experimental":119},"Output","\u002Flaravel-openapi-generator\u002Fdocuments\u002Foutput","laravel-openapi-generator\u002F3.documents\u002F3.output",{"title":188,"path":189,"stem":190,"since":118,"experimental":119},"Translations","\u002Flaravel-openapi-generator\u002Fdocuments\u002Ftranslations","laravel-openapi-generator\u002F3.documents\u002F4.translations",{"title":192,"since":118,"experimental":119,"icon":193,"path":194,"stem":195,"children":196,"page":119},"Workflow","i-lucide-terminal","\u002Flaravel-openapi-generator\u002Fworkflow","laravel-openapi-generator\u002F4.workflow",[197,201,205,209],{"title":198,"path":199,"stem":200,"since":118,"experimental":119},"Diagnostics","\u002Flaravel-openapi-generator\u002Fworkflow\u002Fdiagnostics","laravel-openapi-generator\u002F4.workflow\u002F1.diagnostics",{"title":202,"path":203,"stem":204,"since":118,"experimental":119},"Continuous integration","\u002Flaravel-openapi-generator\u002Fworkflow\u002Fcontinuous-integration","laravel-openapi-generator\u002F4.workflow\u002F2.continuous-integration",{"title":206,"path":207,"stem":208,"since":118,"experimental":119},"Troubleshooting","\u002Flaravel-openapi-generator\u002Fworkflow\u002Ftroubleshooting","laravel-openapi-generator\u002F4.workflow\u002F3.troubleshooting",{"title":210,"path":211,"stem":212,"since":118,"experimental":119},"Agent skills","\u002Flaravel-openapi-generator\u002Fworkflow\u002Fagent-skills","laravel-openapi-generator\u002F4.workflow\u002F4.agent-skills",{"title":214,"since":118,"experimental":119,"icon":215,"path":216,"stem":217,"children":218,"page":119},"Extending","i-lucide-puzzle","\u002Flaravel-openapi-generator\u002Fextending","laravel-openapi-generator\u002F5.extending",[219,223,227,231,235,239],{"title":220,"path":221,"stem":222,"since":118,"experimental":119},"Overview","\u002Flaravel-openapi-generator\u002Fextending\u002Foverview","laravel-openapi-generator\u002F5.extending\u002F1.overview",{"title":224,"path":225,"stem":226,"since":118,"experimental":119},"Rule mappers","\u002Flaravel-openapi-generator\u002Fextending\u002Frule-mappers","laravel-openapi-generator\u002F5.extending\u002F2.rule-mappers",{"title":228,"path":229,"stem":230,"since":118,"experimental":119},"Request & response extractors","\u002Flaravel-openapi-generator\u002Fextending\u002Frequest-and-response-extractors","laravel-openapi-generator\u002F5.extending\u002F3.request-and-response-extractors",{"title":232,"path":233,"stem":234,"since":118,"experimental":119},"Operations & strategies","\u002Flaravel-openapi-generator\u002Fextending\u002Foperations-and-strategies","laravel-openapi-generator\u002F5.extending\u002F4.operations-and-strategies",{"title":236,"path":237,"stem":238,"since":118,"experimental":119},"Samplers","\u002Flaravel-openapi-generator\u002Fextending\u002Fsamplers","laravel-openapi-generator\u002F5.extending\u002F5.samplers",{"title":240,"path":241,"stem":242,"since":118,"experimental":119},"Passes & middlewares","\u002Flaravel-openapi-generator\u002Fextending\u002Fpasses-and-middlewares","laravel-openapi-generator\u002F5.extending\u002F6.passes-and-middlewares",{"title":244,"since":118,"experimental":119,"icon":245,"path":246,"stem":247,"children":248,"page":119},"Integrations","i-lucide-plug","\u002Flaravel-openapi-generator\u002Fintegrations","laravel-openapi-generator\u002F6.integrations",[249,253],{"title":250,"path":251,"stem":252,"since":118,"experimental":119},"JSON:API","\u002Flaravel-openapi-generator\u002Fintegrations\u002Fjson-api","laravel-openapi-generator\u002F6.integrations\u002F1.json-api",{"title":254,"path":255,"stem":256,"since":257,"experimental":119},"API revisions","\u002Flaravel-openapi-generator\u002Fintegrations\u002Fapi-revisions","laravel-openapi-generator\u002F6.integrations\u002F2.api-revisions","1.2",{"title":259,"since":118,"experimental":119,"icon":260,"path":261,"stem":262,"children":263,"page":119},"Reference","i-lucide-library","\u002Flaravel-openapi-generator\u002Freference","laravel-openapi-generator\u002F7.reference",[264,268,272,276,280],{"title":265,"path":266,"stem":267,"since":118,"experimental":119},"Configuration","\u002Flaravel-openapi-generator\u002Freference\u002Fconfiguration","laravel-openapi-generator\u002F7.reference\u002F1.configuration",{"title":269,"path":270,"stem":271,"since":118,"experimental":119},"Attributes","\u002Flaravel-openapi-generator\u002Freference\u002Fattributes","laravel-openapi-generator\u002F7.reference\u002F2.attributes",{"title":273,"path":274,"stem":275,"since":118,"experimental":119},"Commands","\u002Flaravel-openapi-generator\u002Freference\u002Fcommands","laravel-openapi-generator\u002F7.reference\u002F3.commands",{"title":277,"path":278,"stem":279,"since":118,"experimental":119},"Validation rules","\u002Flaravel-openapi-generator\u002Freference\u002Fvalidation-rules","laravel-openapi-generator\u002F7.reference\u002F4.validation-rules",{"title":281,"path":282,"stem":283,"since":118,"experimental":119},"PHPDoc types","\u002Flaravel-openapi-generator\u002Freference\u002Fphpdoc-types","laravel-openapi-generator\u002F7.reference\u002F5.phpdoc-types",{"title":285,"path":286,"children":287},"Releases","\u002Flaravel-openapi-generator\u002Freleases",[288,292],{"title":289,"path":290,"stem":291,"since":118,"experimental":119},"Upgrade guide","\u002Flaravel-openapi-generator\u002Fupgrade","laravel-openapi-generator\u002FUPGRADE",{"title":293,"path":294,"stem":295,"since":118,"experimental":119},"Changelog","\u002Flaravel-openapi-generator\u002Fchangelog","laravel-openapi-generator\u002FCHANGELOG",{"id":297,"title":154,"body":298,"description":2751,"experimental":119,"extension":2752,"links":118,"meta":2753,"navigation":633,"path":155,"rawbody":2754,"seo":2755,"since":118,"stem":156,"__hash__":2756},"laravel_openapi_generator\u002Flaravel-openapi-generator\u002F2.documenting-endpoints\u002F4.responses.md",{"type":299,"value":300,"toc":2743},"minimark",[301,319,324,538,545,1011,1015,1020,1481,1490,1617,1630,1634,1641,2437,2473,2477,2483,2630,2633,2637,2654,2725,2729,2739],[302,303,304,305,309,310,314,315,318],"p",{},"The responses of an operation come from the ",[306,307,308],"strong",{},"return type"," of its action, completed by its PHPDoc ",[311,312,313],"code",{},"@return",". Type\nthe return of every action: without it, the operation gets no response, and a diagnostic.\n",[311,316,317],{},"#[Response]"," declares what a return type cannot say: a status, a paginator, headers.",[320,321,323],"h2",{"id":322},"from-the-return-type","From the return type",[325,326,327,340],"table",{},[328,329,330],"thead",{},[331,332,333,337],"tr",{},[334,335,336],"th",{},"The action returns",[334,338,339],{},"The response",[341,342,343,366,387,400,412,425,442,454,471,481,495,515,530],"tbody",{},[331,344,345,351],{},[346,347,348],"td",{},[311,349,350],{},"UserResource",[346,352,353,354,357,358,361,362,365],{},"200 (201 for ",[311,355,356],{},"POST",") with ",[311,359,360],{},"{\"data\": User}",", ",[311,363,364],{},"User"," being a component",[331,367,368,381],{},[346,369,370,373,374,377,378],{},[311,371,372],{},"AnonymousResourceCollection"," with ",[311,375,376],{},"@return AnonymousResourceCollection\u003CUserResource>",", or a ",[311,379,380],{},"ResourceCollection",[346,382,383,384],{},"200 with ",[311,385,386],{},"{\"data\": [User]}",[331,388,389,394],{},[346,390,391],{},[311,392,393],{},"UserResource|AdminResource",[346,395,396,399],{},[311,397,398],{},"oneOf"," the two components, with a discriminator when a property tells them apart",[331,401,402,405],{},[346,403,404],{},"A model, a collection of models",[346,406,407,408,411],{},"its attributes, from its casts, ",[311,409,410],{},"@property"," and columns",[331,413,414,422],{},[346,415,416,373,419],{},[311,417,418],{},"array",[311,420,421],{},"@return array{id: int, tags: list\u003Cstring>}",[346,423,424],{},"that shape",[331,426,427,439],{},[346,428,429,361,432,361,435,438],{},[311,430,431],{},"int",[311,433,434],{},"string",[311,436,437],{},"bool","…",[346,440,441],{},"that scalar",[331,443,444,449],{},[346,445,446],{},[311,447,448],{},"JsonResponse",[346,450,451,452],{},"an object without properties, and an info: declare the body with ",[311,453,317],{},[331,455,456,468],{},[346,457,458,461,462,361,465],{},[311,459,460],{},"Response"," returned by a ",[311,463,464],{},"DELETE",[311,466,467],{},"noContent()",[346,469,470],{},"204",[331,472,473,478],{},[346,474,475],{},[311,476,477],{},"void",[346,479,480],{},"an empty 200",[331,482,483,488],{},[346,484,485],{},[311,486,487],{},"RedirectResponse",[346,489,490,491,494],{},"302 with a ",[311,492,493],{},"Location"," header",[331,496,497,505],{},[346,498,499,361,502],{},[311,500,501],{},"BinaryFileResponse",[311,503,504],{},"StreamedResponse",[346,506,507,510,511,514],{},[311,508,509],{},"application\u002Foctet-stream",", binary; ",[311,512,513],{},"Content-Disposition"," for a file",[331,516,517,523],{},[346,518,519,520],{},"A ",[311,521,522],{},"Responsable",[346,524,525,526,529],{},"what its ",[311,527,528],{},"toResponse()"," returns, run on a sample",[331,531,532,535],{},[346,533,534],{},"A view",[346,536,537],{},"not documented",[302,539,540,541,544],{},"The resources are described by running them on sampled models; see\n",[542,543,158],"a",{"href":159}," for how, and for which keys are required.",[546,547,550,647],"example",{"input":548,"output":549},"app\u002FHttp\u002FControllers\u002FPetController.php","responses.200",[551,552,554],"template",{"v-slot:input":553},"",[555,556,560],"pre",{"className":557,"code":558,"language":559,"meta":553,"style":553},"language-php shiki shiki-themes material-theme-lighter github-light github-dark","public function show(int $id): CatResource|DogResource\n{\n    \u002F\u002F …\n}\n\n\u002F\u002F CatResource::toArray(): ['type' => 'cat', 'id' => …, 'name' => …]\n\u002F\u002F DogResource::toArray(): ['type' => 'dog', 'id' => …, 'name' => …]\n","php",[311,561,562,609,615,622,628,635,641],{"__ignoreMap":553},[563,564,567,571,574,578,582,585,588,592,595,599,603,606],"span",{"class":565,"line":566},"line",1,[563,568,570],{"class":569},"sbsja","public",[563,572,573],{"class":569}," function",[563,575,577],{"class":576},"sGLFI"," show",[563,579,581],{"class":580},"sP7_E","(",[563,583,431],{"class":584},"sw1J6",[563,586,587],{"class":580}," $",[563,589,591],{"class":590},"su5hD","id",[563,593,594],{"class":580},")",[563,596,598],{"class":597},"smGrS",":",[563,600,602],{"class":601},"sZMiF"," CatResource",[563,604,605],{"class":580},"|",[563,607,608],{"class":601},"DogResource\n",[563,610,612],{"class":565,"line":611},2,[563,613,614],{"class":580},"{\n",[563,616,618],{"class":565,"line":617},3,[563,619,621],{"class":620},"sutJx","    \u002F\u002F …\n",[563,623,625],{"class":565,"line":624},4,[563,626,627],{"class":580},"}\n",[563,629,631],{"class":565,"line":630},5,[563,632,634],{"emptyLinePlaceholder":633},true,"\n",[563,636,638],{"class":565,"line":637},6,[563,639,640],{"class":620},"\u002F\u002F CatResource::toArray(): ['type' => 'cat', 'id' => …, 'name' => …]\n",[563,642,644],{"class":565,"line":643},7,[563,645,646],{"class":620},"\u002F\u002F DogResource::toArray(): ['type' => 'dog', 'id' => …, 'name' => …]\n",[551,648,649],{"v-slot:output":553},[555,650,654],{"className":651,"code":652,"language":653,"meta":553,"style":553},"language-json shiki shiki-themes material-theme-lighter github-light github-dark","{\n  \"description\": \"OK\",\n  \"content\": {\n    \"application\u002Fjson\": {\n      \"schema\": {\n        \"type\": \"object\",\n        \"required\": [\"data\"],\n        \"properties\": {\n          \"data\": {\n            \"oneOf\": [\n              { \"$ref\": \"#\u002Fcomponents\u002Fschemas\u002FCat\" },\n              { \"$ref\": \"#\u002Fcomponents\u002Fschemas\u002FDog\" }\n            ],\n            \"discriminator\": {\n              \"propertyName\": \"type\",\n              \"mapping\": {\n                \"cat\": \"#\u002Fcomponents\u002Fschemas\u002FCat\",\n                \"dog\": \"#\u002Fcomponents\u002Fschemas\u002FDog\"\n              }\n            }\n          }\n        }\n      }\n    }\n  }\n}\n","json",[311,655,656,660,688,702,716,731,753,777,791,806,821,847,870,876,890,911,925,946,965,971,976,982,988,994,1000,1006],{"__ignoreMap":553},[563,657,658],{"class":565,"line":566},[563,659,614],{"class":580},[563,661,662,666,670,673,675,679,683,685],{"class":565,"line":611},[563,663,665],{"class":664},"s39Yj","  \"",[563,667,669],{"class":668},"sseR_","description",[563,671,672],{"class":664},"\"",[563,674,598],{"class":580},[563,676,678],{"class":677},"sjJ54"," \"",[563,680,682],{"class":681},"s_sjI","OK",[563,684,672],{"class":677},[563,686,687],{"class":580},",\n",[563,689,690,692,695,697,699],{"class":565,"line":617},[563,691,665],{"class":664},[563,693,694],{"class":668},"content",[563,696,672],{"class":664},[563,698,598],{"class":580},[563,700,701],{"class":580}," {\n",[563,703,704,707,710,712,714],{"class":565,"line":624},[563,705,706],{"class":664},"    \"",[563,708,709],{"class":601},"application\u002Fjson",[563,711,672],{"class":664},[563,713,598],{"class":580},[563,715,701],{"class":580},[563,717,718,721,725,727,729],{"class":565,"line":630},[563,719,720],{"class":664},"      \"",[563,722,724],{"class":723},"srdBf","schema",[563,726,672],{"class":664},[563,728,598],{"class":580},[563,730,701],{"class":580},[563,732,733,736,740,742,744,746,749,751],{"class":565,"line":637},[563,734,735],{"class":664},"        \"",[563,737,739],{"class":738},"swQdS","type",[563,741,672],{"class":664},[563,743,598],{"class":580},[563,745,678],{"class":677},[563,747,748],{"class":681},"object",[563,750,672],{"class":677},[563,752,687],{"class":580},[563,754,755,757,760,762,764,767,769,772,774],{"class":565,"line":643},[563,756,735],{"class":664},[563,758,759],{"class":738},"required",[563,761,672],{"class":664},[563,763,598],{"class":580},[563,765,766],{"class":580}," [",[563,768,672],{"class":677},[563,770,771],{"class":681},"data",[563,773,672],{"class":677},[563,775,776],{"class":580},"],\n",[563,778,780,782,785,787,789],{"class":565,"line":779},8,[563,781,735],{"class":664},[563,783,784],{"class":738},"properties",[563,786,672],{"class":664},[563,788,598],{"class":580},[563,790,701],{"class":580},[563,792,794,797,800,802,804],{"class":565,"line":793},9,[563,795,796],{"class":664},"          \"",[563,798,771],{"class":799},"sAQsV",[563,801,672],{"class":664},[563,803,598],{"class":580},[563,805,701],{"class":580},[563,807,808,811,814,816,818],{"class":565,"line":29},[563,809,810],{"class":664},"            \"",[563,812,398],{"class":813},"sptTA",[563,815,672],{"class":664},[563,817,598],{"class":580},[563,819,820],{"class":580}," [\n",[563,822,824,827,829,833,835,837,839,842,844],{"class":565,"line":823},11,[563,825,826],{"class":580},"              {",[563,828,678],{"class":664},[563,830,832],{"class":831},"syTEX","$ref",[563,834,672],{"class":664},[563,836,598],{"class":580},[563,838,678],{"class":677},[563,840,841],{"class":681},"#\u002Fcomponents\u002Fschemas\u002FCat",[563,843,672],{"class":677},[563,845,846],{"class":580}," },\n",[563,848,850,852,854,856,858,860,862,865,867],{"class":565,"line":849},12,[563,851,826],{"class":580},[563,853,678],{"class":664},[563,855,832],{"class":831},[563,857,672],{"class":664},[563,859,598],{"class":580},[563,861,678],{"class":677},[563,863,864],{"class":681},"#\u002Fcomponents\u002Fschemas\u002FDog",[563,866,672],{"class":677},[563,868,869],{"class":580}," }\n",[563,871,873],{"class":565,"line":872},13,[563,874,875],{"class":580},"            ],\n",[563,877,879,881,884,886,888],{"class":565,"line":878},14,[563,880,810],{"class":664},[563,882,883],{"class":813},"discriminator",[563,885,672],{"class":664},[563,887,598],{"class":580},[563,889,701],{"class":580},[563,891,893,896,899,901,903,905,907,909],{"class":565,"line":892},15,[563,894,895],{"class":664},"              \"",[563,897,898],{"class":831},"propertyName",[563,900,672],{"class":664},[563,902,598],{"class":580},[563,904,678],{"class":677},[563,906,739],{"class":681},[563,908,672],{"class":677},[563,910,687],{"class":580},[563,912,914,916,919,921,923],{"class":565,"line":913},16,[563,915,895],{"class":664},[563,917,918],{"class":831},"mapping",[563,920,672],{"class":664},[563,922,598],{"class":580},[563,924,701],{"class":580},[563,926,928,931,934,936,938,940,942,944],{"class":565,"line":927},17,[563,929,930],{"class":664},"                \"",[563,932,933],{"class":668},"cat",[563,935,672],{"class":664},[563,937,598],{"class":580},[563,939,678],{"class":677},[563,941,841],{"class":681},[563,943,672],{"class":677},[563,945,687],{"class":580},[563,947,949,951,954,956,958,960,962],{"class":565,"line":948},18,[563,950,930],{"class":664},[563,952,953],{"class":668},"dog",[563,955,672],{"class":664},[563,957,598],{"class":580},[563,959,678],{"class":677},[563,961,864],{"class":681},[563,963,964],{"class":677},"\"\n",[563,966,968],{"class":565,"line":967},19,[563,969,970],{"class":580},"              }\n",[563,972,973],{"class":565,"line":58},[563,974,975],{"class":580},"            }\n",[563,977,979],{"class":565,"line":978},21,[563,980,981],{"class":580},"          }\n",[563,983,985],{"class":565,"line":984},22,[563,986,987],{"class":580},"        }\n",[563,989,991],{"class":565,"line":990},23,[563,992,993],{"class":580},"      }\n",[563,995,997],{"class":565,"line":996},24,[563,998,999],{"class":580},"    }\n",[563,1001,1003],{"class":565,"line":1002},25,[563,1004,1005],{"class":580},"  }\n",[563,1007,1009],{"class":565,"line":1008},26,[563,1010,627],{"class":580},[320,1012,1014],{"id":1013},"declaring-a-response","Declaring a response",[302,1016,1017,1019],{},[311,1018,317],{}," is repeatable. On the action, it replaces the response inferred for its status:",[546,1021,1024,1215],{"input":1022,"output":1023},"app\u002FHttp\u002FControllers\u002FSearchIndexController.php","responses",[551,1025,1026],{"v-slot:input":553},[555,1027,1029],{"className":557,"code":1028,"language":559,"meta":553,"style":553},"use Ark4ne\\OpenApi\\Attributes\\Response;\n\n#[Response(\n    202,\n    description: 'Queued',\n    type: 'array{job: string}',\n    headers: ['Retry-After' => 'positive-int'],\n)]\npublic function rebuild(): JsonResponse\n{\n    return new JsonResponse(['job' => $job->id], 202);\n}\n",[311,1030,1031,1057,1061,1071,1078,1097,1113,1141,1148,1165,1169,1211],{"__ignoreMap":553},[563,1032,1033,1036,1040,1043,1046,1048,1050,1052,1054],{"class":565,"line":566},[563,1034,1035],{"class":584},"use",[563,1037,1039],{"class":1038},"s_hVV"," Ark4ne",[563,1041,1042],{"class":664},"\\",[563,1044,1045],{"class":1038},"OpenApi",[563,1047,1042],{"class":664},[563,1049,269],{"class":1038},[563,1051,1042],{"class":664},[563,1053,460],{"class":1038},[563,1055,1056],{"class":580},";\n",[563,1058,1059],{"class":565,"line":611},[563,1060,634],{"emptyLinePlaceholder":633},[563,1062,1063,1066,1068],{"class":565,"line":617},[563,1064,1065],{"class":590},"#[",[563,1067,460],{"class":1038},[563,1069,1070],{"class":580},"(\n",[563,1072,1073,1076],{"class":565,"line":624},[563,1074,1075],{"class":723},"    202",[563,1077,687],{"class":580},[563,1079,1080,1084,1086,1089,1092,1095],{"class":565,"line":630},[563,1081,1083],{"class":1082},"sbgvK","    description",[563,1085,598],{"class":580},[563,1087,1088],{"class":677}," '",[563,1090,1091],{"class":681},"Queued",[563,1093,1094],{"class":677},"'",[563,1096,687],{"class":580},[563,1098,1099,1102,1104,1106,1109,1111],{"class":565,"line":637},[563,1100,1101],{"class":1082},"    type",[563,1103,598],{"class":580},[563,1105,1088],{"class":677},[563,1107,1108],{"class":681},"array{job: string}",[563,1110,1094],{"class":677},[563,1112,687],{"class":580},[563,1114,1115,1118,1120,1122,1124,1127,1129,1132,1134,1137,1139],{"class":565,"line":643},[563,1116,1117],{"class":1082},"    headers",[563,1119,598],{"class":580},[563,1121,766],{"class":580},[563,1123,1094],{"class":677},[563,1125,1126],{"class":681},"Retry-After",[563,1128,1094],{"class":677},[563,1130,1131],{"class":597}," =>",[563,1133,1088],{"class":677},[563,1135,1136],{"class":681},"positive-int",[563,1138,1094],{"class":677},[563,1140,776],{"class":580},[563,1142,1143,1145],{"class":565,"line":779},[563,1144,594],{"class":580},[563,1146,1147],{"class":590},"]\n",[563,1149,1150,1152,1154,1157,1160,1162],{"class":565,"line":793},[563,1151,570],{"class":569},[563,1153,573],{"class":569},[563,1155,1156],{"class":576}," rebuild",[563,1158,1159],{"class":580},"()",[563,1161,598],{"class":597},[563,1163,1164],{"class":601}," JsonResponse\n",[563,1166,1167],{"class":565,"line":29},[563,1168,614],{"class":580},[563,1170,1171,1175,1178,1181,1184,1186,1189,1191,1193,1195,1197,1200,1202,1205,1208],{"class":565,"line":823},[563,1172,1174],{"class":1173},"sVHd0","    return",[563,1176,1177],{"class":584}," new",[563,1179,1180],{"class":601}," JsonResponse",[563,1182,1183],{"class":580},"([",[563,1185,1094],{"class":677},[563,1187,1188],{"class":681},"job",[563,1190,1094],{"class":677},[563,1192,1131],{"class":597},[563,1194,587],{"class":580},[563,1196,1188],{"class":590},[563,1198,1199],{"class":597},"->",[563,1201,591],{"class":590},[563,1203,1204],{"class":580},"],",[563,1206,1207],{"class":723}," 202",[563,1209,1210],{"class":580},");\n",[563,1212,1213],{"class":565,"line":849},[563,1214,627],{"class":580},[551,1216,1217],{"v-slot:output":553},[555,1218,1220],{"className":651,"code":1219,"language":653,"meta":553,"style":553},"{\n  \"202\": {\n    \"description\": \"Queued\",\n    \"headers\": {\n      \"Retry-After\": { \"schema\": { \"type\": \"integer\", \"minimum\": 1 } }\n    },\n    \"content\": {\n      \"application\u002Fjson\": {\n        \"schema\": {\n          \"type\": \"object\",\n          \"required\": [\"job\"],\n          \"properties\": { \"job\": { \"type\": \"string\" } },\n          \"additionalProperties\": false\n        }\n      }\n    }\n  }\n}\n",[311,1221,1222,1226,1239,1257,1270,1328,1333,1345,1357,1369,1387,1407,1447,1461,1465,1469,1473,1477],{"__ignoreMap":553},[563,1223,1224],{"class":565,"line":566},[563,1225,614],{"class":580},[563,1227,1228,1230,1233,1235,1237],{"class":565,"line":611},[563,1229,665],{"class":664},[563,1231,1232],{"class":668},"202",[563,1234,672],{"class":664},[563,1236,598],{"class":580},[563,1238,701],{"class":580},[563,1240,1241,1243,1245,1247,1249,1251,1253,1255],{"class":565,"line":617},[563,1242,706],{"class":664},[563,1244,669],{"class":601},[563,1246,672],{"class":664},[563,1248,598],{"class":580},[563,1250,678],{"class":677},[563,1252,1091],{"class":681},[563,1254,672],{"class":677},[563,1256,687],{"class":580},[563,1258,1259,1261,1264,1266,1268],{"class":565,"line":624},[563,1260,706],{"class":664},[563,1262,1263],{"class":601},"headers",[563,1265,672],{"class":664},[563,1267,598],{"class":580},[563,1269,701],{"class":580},[563,1271,1272,1274,1276,1278,1280,1283,1285,1287,1289,1291,1293,1295,1297,1299,1301,1303,1306,1308,1311,1313,1316,1318,1320,1323,1326],{"class":565,"line":630},[563,1273,720],{"class":664},[563,1275,1126],{"class":723},[563,1277,672],{"class":664},[563,1279,598],{"class":580},[563,1281,1282],{"class":580}," {",[563,1284,678],{"class":664},[563,1286,724],{"class":738},[563,1288,672],{"class":664},[563,1290,598],{"class":580},[563,1292,1282],{"class":580},[563,1294,678],{"class":664},[563,1296,739],{"class":799},[563,1298,672],{"class":664},[563,1300,598],{"class":580},[563,1302,678],{"class":677},[563,1304,1305],{"class":681},"integer",[563,1307,672],{"class":677},[563,1309,1310],{"class":580},",",[563,1312,678],{"class":664},[563,1314,1315],{"class":799},"minimum",[563,1317,672],{"class":664},[563,1319,598],{"class":580},[563,1321,1322],{"class":723}," 1",[563,1324,1325],{"class":580}," }",[563,1327,869],{"class":580},[563,1329,1330],{"class":565,"line":637},[563,1331,1332],{"class":580},"    },\n",[563,1334,1335,1337,1339,1341,1343],{"class":565,"line":643},[563,1336,706],{"class":664},[563,1338,694],{"class":601},[563,1340,672],{"class":664},[563,1342,598],{"class":580},[563,1344,701],{"class":580},[563,1346,1347,1349,1351,1353,1355],{"class":565,"line":779},[563,1348,720],{"class":664},[563,1350,709],{"class":723},[563,1352,672],{"class":664},[563,1354,598],{"class":580},[563,1356,701],{"class":580},[563,1358,1359,1361,1363,1365,1367],{"class":565,"line":793},[563,1360,735],{"class":664},[563,1362,724],{"class":738},[563,1364,672],{"class":664},[563,1366,598],{"class":580},[563,1368,701],{"class":580},[563,1370,1371,1373,1375,1377,1379,1381,1383,1385],{"class":565,"line":29},[563,1372,796],{"class":664},[563,1374,739],{"class":799},[563,1376,672],{"class":664},[563,1378,598],{"class":580},[563,1380,678],{"class":677},[563,1382,748],{"class":681},[563,1384,672],{"class":677},[563,1386,687],{"class":580},[563,1388,1389,1391,1393,1395,1397,1399,1401,1403,1405],{"class":565,"line":823},[563,1390,796],{"class":664},[563,1392,759],{"class":799},[563,1394,672],{"class":664},[563,1396,598],{"class":580},[563,1398,766],{"class":580},[563,1400,672],{"class":677},[563,1402,1188],{"class":681},[563,1404,672],{"class":677},[563,1406,776],{"class":580},[563,1408,1409,1411,1413,1415,1417,1419,1421,1423,1425,1427,1429,1431,1433,1435,1437,1439,1441,1443,1445],{"class":565,"line":849},[563,1410,796],{"class":664},[563,1412,784],{"class":799},[563,1414,672],{"class":664},[563,1416,598],{"class":580},[563,1418,1282],{"class":580},[563,1420,678],{"class":664},[563,1422,1188],{"class":813},[563,1424,672],{"class":664},[563,1426,598],{"class":580},[563,1428,1282],{"class":580},[563,1430,678],{"class":664},[563,1432,739],{"class":831},[563,1434,672],{"class":664},[563,1436,598],{"class":580},[563,1438,678],{"class":677},[563,1440,434],{"class":681},[563,1442,672],{"class":677},[563,1444,1325],{"class":580},[563,1446,846],{"class":580},[563,1448,1449,1451,1454,1456,1458],{"class":565,"line":872},[563,1450,796],{"class":664},[563,1452,1453],{"class":799},"additionalProperties",[563,1455,672],{"class":664},[563,1457,598],{"class":580},[563,1459,1460],{"class":664}," false\n",[563,1462,1463],{"class":565,"line":878},[563,1464,987],{"class":580},[563,1466,1467],{"class":565,"line":892},[563,1468,993],{"class":580},[563,1470,1471],{"class":565,"line":913},[563,1472,999],{"class":580},[563,1474,1475],{"class":565,"line":927},[563,1476,1005],{"class":580},[563,1478,1479],{"class":565,"line":948},[563,1480,627],{"class":580},[302,1482,519,1483,1485,1486,1489],{},[311,1484,448],{}," is inferred as a 200 whatever status it is built with. A declared ",[306,1487,1488],{},"success"," (2xx) leaves out the\nsuccesses inferred for other statuses: here the 202 replaces the 200.",[325,1491,1492,1502],{},[328,1493,1494],{},[331,1495,1496,1499],{},[334,1497,1498],{},"Parameter",[334,1500,1501],{},"Gives",[341,1503,1504,1521,1530,1540,1559,1577,1586,1598,1607],{},[331,1505,1506,1511],{},[346,1507,1508],{},[311,1509,1510],{},"status",[346,1512,1513,1514,1517,1518],{},"the status, ",[311,1515,1516],{},"200"," by default, or ",[311,1519,1520],{},"'default'",[331,1522,1523,1527],{},[346,1524,1525],{},[311,1526,669],{},[346,1528,1529],{},"the description, the HTTP phrase of the status by default",[331,1531,1532,1537],{},[346,1533,1534],{},[311,1535,1536],{},"resource",[346,1538,1539],{},"the body from a resource or a resource collection",[331,1541,1542,1546],{},[346,1543,1544],{},[311,1545,739],{},[346,1547,1548,1549,1552,1553,361,1556],{},"the body from a ",[542,1550,1551],{"href":282},"PHPDoc type",": ",[311,1554,1555],{},"array{id: int}",[311,1557,1558],{},"list\u003Cstring>",[331,1560,1561,1566],{},[346,1562,1563],{},[311,1564,1565],{},"mediaType",[346,1567,1568,1570,1571,361,1574,1576],{},[311,1569,709],{}," by default; with ",[311,1572,1573],{},"text\u002Fevent-stream",[311,1575,739],{}," is one event",[331,1578,1579,1583],{},[346,1580,1581],{},[311,1582,1263],{},[346,1584,1585],{},"header name → PHPDoc type of its value",[331,1587,1588,1593],{},[346,1589,1590],{},[311,1591,1592],{},"paginator",[346,1594,1595,1596],{},"the paginator of ",[311,1597,1536],{},[331,1599,1600,1604],{},[346,1601,1602],{},[311,1603,546],{},[346,1605,1606],{},"an example of the body",[331,1608,1609,1614],{},[346,1610,1611],{},[311,1612,1613],{},"summary",[346,1615,1616],{},"a short summary (3.2)",[302,1618,1619,1620,1622,1623,1625,1626,1629],{},"Without ",[311,1621,1536],{}," nor ",[311,1624,739],{},", the attribute keeps the body inferred for its status, or given by the exceptions of\nthat status: ",[311,1627,1628],{},"#[Response(404, description: 'No such book')]"," renames the 404 only.",[320,1631,1633],{"id":1632},"paginated-collections","Paginated collections",[302,1635,1636,1637,1640],{},"The return type of ",[311,1638,1639],{},"Book::paginate()"," wrapped in a collection does not tell the paginator. Declare it:",[546,1642,1645,1785],{"input":1643,"output":1644},"app\u002FHttp\u002FControllers\u002FBookController.php","responses.200.content.application\u002Fjson.schema",[551,1646,1647],{"v-slot:input":553},[555,1648,1650],{"className":557,"code":1649,"language":559,"meta":553,"style":553},"use Illuminate\\Pagination\\CursorPaginator;\n\n#[Response(\n    200,\n    resource: BookResource::class,\n    paginator: CursorPaginator::class,\n)]\npublic function index(): AnonymousResourceCollection\n{\n    return BookResource::collection(Book::query()->cursorPaginate());\n}\n",[311,1651,1652,1671,1675,1683,1690,1708,1724,1730,1746,1750,1781],{"__ignoreMap":553},[563,1653,1654,1656,1659,1661,1664,1666,1669],{"class":565,"line":566},[563,1655,1035],{"class":584},[563,1657,1658],{"class":1038}," Illuminate",[563,1660,1042],{"class":664},[563,1662,1663],{"class":1038},"Pagination",[563,1665,1042],{"class":664},[563,1667,1668],{"class":1038},"CursorPaginator",[563,1670,1056],{"class":580},[563,1672,1673],{"class":565,"line":611},[563,1674,634],{"emptyLinePlaceholder":633},[563,1676,1677,1679,1681],{"class":565,"line":617},[563,1678,1065],{"class":590},[563,1680,460],{"class":1038},[563,1682,1070],{"class":580},[563,1684,1685,1688],{"class":565,"line":624},[563,1686,1687],{"class":723},"    200",[563,1689,687],{"class":580},[563,1691,1692,1695,1697,1700,1703,1706],{"class":565,"line":630},[563,1693,1694],{"class":1082},"    resource",[563,1696,598],{"class":580},[563,1698,1699],{"class":601}," BookResource",[563,1701,1702],{"class":597},"::",[563,1704,1705],{"class":584},"class",[563,1707,687],{"class":580},[563,1709,1710,1713,1715,1718,1720,1722],{"class":565,"line":637},[563,1711,1712],{"class":1082},"    paginator",[563,1714,598],{"class":580},[563,1716,1717],{"class":601}," CursorPaginator",[563,1719,1702],{"class":597},[563,1721,1705],{"class":584},[563,1723,687],{"class":580},[563,1725,1726,1728],{"class":565,"line":643},[563,1727,594],{"class":580},[563,1729,1147],{"class":590},[563,1731,1732,1734,1736,1739,1741,1743],{"class":565,"line":779},[563,1733,570],{"class":569},[563,1735,573],{"class":569},[563,1737,1738],{"class":576}," index",[563,1740,1159],{"class":580},[563,1742,598],{"class":597},[563,1744,1745],{"class":601}," AnonymousResourceCollection\n",[563,1747,1748],{"class":565,"line":793},[563,1749,614],{"class":580},[563,1751,1752,1754,1756,1758,1761,1763,1766,1768,1771,1773,1775,1778],{"class":565,"line":29},[563,1753,1174],{"class":1173},[563,1755,1699],{"class":601},[563,1757,1702],{"class":597},[563,1759,1760],{"class":576},"collection",[563,1762,581],{"class":580},[563,1764,1765],{"class":601},"Book",[563,1767,1702],{"class":597},[563,1769,1770],{"class":576},"query",[563,1772,1159],{"class":580},[563,1774,1199],{"class":597},[563,1776,1777],{"class":576},"cursorPaginate",[563,1779,1780],{"class":580},"());\n",[563,1782,1783],{"class":565,"line":823},[563,1784,627],{"class":580},[551,1786,1787],{"v-slot:output":553},[555,1788,1790],{"className":651,"code":1789,"language":653,"meta":553,"style":553},"{\n  \"type\": \"object\",\n  \"required\": [\"data\", \"links\", \"meta\"],\n  \"properties\": {\n    \"data\": { \"type\": \"array\", \"items\": { \"$ref\": \"#\u002Fcomponents\u002Fschemas\u002FBook\" } },\n    \"links\": {\n      \"type\": \"object\",\n      \"required\": [\"first\", \"last\", \"prev\", \"next\"],\n      \"properties\": {\n        \"first\": { \"type\": [\"string\", \"null\"] },\n        \"last\": { \"type\": [\"string\", \"null\"] },\n        \"prev\": { \"type\": [\"string\", \"null\"] },\n        \"next\": { \"type\": [\"string\", \"null\"] }\n      }\n    },\n    \"meta\": {\n      \"type\": \"object\",\n      \"required\": [\"path\", \"per_page\", \"next_cursor\", \"prev_cursor\"],\n      \"properties\": {\n        \"path\": { \"type\": [\"string\", \"null\"] },\n        \"per_page\": { \"type\": \"integer\" },\n        \"next_cursor\": { \"type\": [\"string\", \"null\"] },\n        \"prev_cursor\": { \"type\": [\"string\", \"null\"] }\n      }\n    }\n  }\n}\n",[311,1791,1792,1796,1814,1852,1864,1922,1934,1952,2000,2012,2054,2094,2134,2174,2178,2182,2194,2212,2260,2272,2312,2340,2380,2420,2424,2428,2432],{"__ignoreMap":553},[563,1793,1794],{"class":565,"line":566},[563,1795,614],{"class":580},[563,1797,1798,1800,1802,1804,1806,1808,1810,1812],{"class":565,"line":611},[563,1799,665],{"class":664},[563,1801,739],{"class":668},[563,1803,672],{"class":664},[563,1805,598],{"class":580},[563,1807,678],{"class":677},[563,1809,748],{"class":681},[563,1811,672],{"class":677},[563,1813,687],{"class":580},[563,1815,1816,1818,1820,1822,1824,1826,1828,1830,1832,1834,1836,1839,1841,1843,1845,1848,1850],{"class":565,"line":617},[563,1817,665],{"class":664},[563,1819,759],{"class":668},[563,1821,672],{"class":664},[563,1823,598],{"class":580},[563,1825,766],{"class":580},[563,1827,672],{"class":677},[563,1829,771],{"class":681},[563,1831,672],{"class":677},[563,1833,1310],{"class":580},[563,1835,678],{"class":677},[563,1837,1838],{"class":681},"links",[563,1840,672],{"class":677},[563,1842,1310],{"class":580},[563,1844,678],{"class":677},[563,1846,1847],{"class":681},"meta",[563,1849,672],{"class":677},[563,1851,776],{"class":580},[563,1853,1854,1856,1858,1860,1862],{"class":565,"line":624},[563,1855,665],{"class":664},[563,1857,784],{"class":668},[563,1859,672],{"class":664},[563,1861,598],{"class":580},[563,1863,701],{"class":580},[563,1865,1866,1868,1870,1872,1874,1876,1878,1880,1882,1884,1886,1888,1890,1892,1894,1897,1899,1901,1903,1905,1907,1909,1911,1913,1916,1918,1920],{"class":565,"line":630},[563,1867,706],{"class":664},[563,1869,771],{"class":601},[563,1871,672],{"class":664},[563,1873,598],{"class":580},[563,1875,1282],{"class":580},[563,1877,678],{"class":664},[563,1879,739],{"class":723},[563,1881,672],{"class":664},[563,1883,598],{"class":580},[563,1885,678],{"class":677},[563,1887,418],{"class":681},[563,1889,672],{"class":677},[563,1891,1310],{"class":580},[563,1893,678],{"class":664},[563,1895,1896],{"class":723},"items",[563,1898,672],{"class":664},[563,1900,598],{"class":580},[563,1902,1282],{"class":580},[563,1904,678],{"class":664},[563,1906,832],{"class":738},[563,1908,672],{"class":664},[563,1910,598],{"class":580},[563,1912,678],{"class":677},[563,1914,1915],{"class":681},"#\u002Fcomponents\u002Fschemas\u002FBook",[563,1917,672],{"class":677},[563,1919,1325],{"class":580},[563,1921,846],{"class":580},[563,1923,1924,1926,1928,1930,1932],{"class":565,"line":637},[563,1925,706],{"class":664},[563,1927,1838],{"class":601},[563,1929,672],{"class":664},[563,1931,598],{"class":580},[563,1933,701],{"class":580},[563,1935,1936,1938,1940,1942,1944,1946,1948,1950],{"class":565,"line":643},[563,1937,720],{"class":664},[563,1939,739],{"class":723},[563,1941,672],{"class":664},[563,1943,598],{"class":580},[563,1945,678],{"class":677},[563,1947,748],{"class":681},[563,1949,672],{"class":677},[563,1951,687],{"class":580},[563,1953,1954,1956,1958,1960,1962,1964,1966,1969,1971,1973,1975,1978,1980,1982,1984,1987,1989,1991,1993,1996,1998],{"class":565,"line":779},[563,1955,720],{"class":664},[563,1957,759],{"class":723},[563,1959,672],{"class":664},[563,1961,598],{"class":580},[563,1963,766],{"class":580},[563,1965,672],{"class":677},[563,1967,1968],{"class":681},"first",[563,1970,672],{"class":677},[563,1972,1310],{"class":580},[563,1974,678],{"class":677},[563,1976,1977],{"class":681},"last",[563,1979,672],{"class":677},[563,1981,1310],{"class":580},[563,1983,678],{"class":677},[563,1985,1986],{"class":681},"prev",[563,1988,672],{"class":677},[563,1990,1310],{"class":580},[563,1992,678],{"class":677},[563,1994,1995],{"class":681},"next",[563,1997,672],{"class":677},[563,1999,776],{"class":580},[563,2001,2002,2004,2006,2008,2010],{"class":565,"line":793},[563,2003,720],{"class":664},[563,2005,784],{"class":723},[563,2007,672],{"class":664},[563,2009,598],{"class":580},[563,2011,701],{"class":580},[563,2013,2014,2016,2018,2020,2022,2024,2026,2028,2030,2032,2034,2036,2038,2040,2042,2044,2047,2049,2052],{"class":565,"line":29},[563,2015,735],{"class":664},[563,2017,1968],{"class":738},[563,2019,672],{"class":664},[563,2021,598],{"class":580},[563,2023,1282],{"class":580},[563,2025,678],{"class":664},[563,2027,739],{"class":799},[563,2029,672],{"class":664},[563,2031,598],{"class":580},[563,2033,766],{"class":580},[563,2035,672],{"class":677},[563,2037,434],{"class":681},[563,2039,672],{"class":677},[563,2041,1310],{"class":580},[563,2043,678],{"class":677},[563,2045,2046],{"class":681},"null",[563,2048,672],{"class":677},[563,2050,2051],{"class":580},"]",[563,2053,846],{"class":580},[563,2055,2056,2058,2060,2062,2064,2066,2068,2070,2072,2074,2076,2078,2080,2082,2084,2086,2088,2090,2092],{"class":565,"line":823},[563,2057,735],{"class":664},[563,2059,1977],{"class":738},[563,2061,672],{"class":664},[563,2063,598],{"class":580},[563,2065,1282],{"class":580},[563,2067,678],{"class":664},[563,2069,739],{"class":799},[563,2071,672],{"class":664},[563,2073,598],{"class":580},[563,2075,766],{"class":580},[563,2077,672],{"class":677},[563,2079,434],{"class":681},[563,2081,672],{"class":677},[563,2083,1310],{"class":580},[563,2085,678],{"class":677},[563,2087,2046],{"class":681},[563,2089,672],{"class":677},[563,2091,2051],{"class":580},[563,2093,846],{"class":580},[563,2095,2096,2098,2100,2102,2104,2106,2108,2110,2112,2114,2116,2118,2120,2122,2124,2126,2128,2130,2132],{"class":565,"line":849},[563,2097,735],{"class":664},[563,2099,1986],{"class":738},[563,2101,672],{"class":664},[563,2103,598],{"class":580},[563,2105,1282],{"class":580},[563,2107,678],{"class":664},[563,2109,739],{"class":799},[563,2111,672],{"class":664},[563,2113,598],{"class":580},[563,2115,766],{"class":580},[563,2117,672],{"class":677},[563,2119,434],{"class":681},[563,2121,672],{"class":677},[563,2123,1310],{"class":580},[563,2125,678],{"class":677},[563,2127,2046],{"class":681},[563,2129,672],{"class":677},[563,2131,2051],{"class":580},[563,2133,846],{"class":580},[563,2135,2136,2138,2140,2142,2144,2146,2148,2150,2152,2154,2156,2158,2160,2162,2164,2166,2168,2170,2172],{"class":565,"line":872},[563,2137,735],{"class":664},[563,2139,1995],{"class":738},[563,2141,672],{"class":664},[563,2143,598],{"class":580},[563,2145,1282],{"class":580},[563,2147,678],{"class":664},[563,2149,739],{"class":799},[563,2151,672],{"class":664},[563,2153,598],{"class":580},[563,2155,766],{"class":580},[563,2157,672],{"class":677},[563,2159,434],{"class":681},[563,2161,672],{"class":677},[563,2163,1310],{"class":580},[563,2165,678],{"class":677},[563,2167,2046],{"class":681},[563,2169,672],{"class":677},[563,2171,2051],{"class":580},[563,2173,869],{"class":580},[563,2175,2176],{"class":565,"line":878},[563,2177,993],{"class":580},[563,2179,2180],{"class":565,"line":892},[563,2181,1332],{"class":580},[563,2183,2184,2186,2188,2190,2192],{"class":565,"line":913},[563,2185,706],{"class":664},[563,2187,1847],{"class":601},[563,2189,672],{"class":664},[563,2191,598],{"class":580},[563,2193,701],{"class":580},[563,2195,2196,2198,2200,2202,2204,2206,2208,2210],{"class":565,"line":927},[563,2197,720],{"class":664},[563,2199,739],{"class":723},[563,2201,672],{"class":664},[563,2203,598],{"class":580},[563,2205,678],{"class":677},[563,2207,748],{"class":681},[563,2209,672],{"class":677},[563,2211,687],{"class":580},[563,2213,2214,2216,2218,2220,2222,2224,2226,2229,2231,2233,2235,2238,2240,2242,2244,2247,2249,2251,2253,2256,2258],{"class":565,"line":948},[563,2215,720],{"class":664},[563,2217,759],{"class":723},[563,2219,672],{"class":664},[563,2221,598],{"class":580},[563,2223,766],{"class":580},[563,2225,672],{"class":677},[563,2227,2228],{"class":681},"path",[563,2230,672],{"class":677},[563,2232,1310],{"class":580},[563,2234,678],{"class":677},[563,2236,2237],{"class":681},"per_page",[563,2239,672],{"class":677},[563,2241,1310],{"class":580},[563,2243,678],{"class":677},[563,2245,2246],{"class":681},"next_cursor",[563,2248,672],{"class":677},[563,2250,1310],{"class":580},[563,2252,678],{"class":677},[563,2254,2255],{"class":681},"prev_cursor",[563,2257,672],{"class":677},[563,2259,776],{"class":580},[563,2261,2262,2264,2266,2268,2270],{"class":565,"line":967},[563,2263,720],{"class":664},[563,2265,784],{"class":723},[563,2267,672],{"class":664},[563,2269,598],{"class":580},[563,2271,701],{"class":580},[563,2273,2274,2276,2278,2280,2282,2284,2286,2288,2290,2292,2294,2296,2298,2300,2302,2304,2306,2308,2310],{"class":565,"line":58},[563,2275,735],{"class":664},[563,2277,2228],{"class":738},[563,2279,672],{"class":664},[563,2281,598],{"class":580},[563,2283,1282],{"class":580},[563,2285,678],{"class":664},[563,2287,739],{"class":799},[563,2289,672],{"class":664},[563,2291,598],{"class":580},[563,2293,766],{"class":580},[563,2295,672],{"class":677},[563,2297,434],{"class":681},[563,2299,672],{"class":677},[563,2301,1310],{"class":580},[563,2303,678],{"class":677},[563,2305,2046],{"class":681},[563,2307,672],{"class":677},[563,2309,2051],{"class":580},[563,2311,846],{"class":580},[563,2313,2314,2316,2318,2320,2322,2324,2326,2328,2330,2332,2334,2336,2338],{"class":565,"line":978},[563,2315,735],{"class":664},[563,2317,2237],{"class":738},[563,2319,672],{"class":664},[563,2321,598],{"class":580},[563,2323,1282],{"class":580},[563,2325,678],{"class":664},[563,2327,739],{"class":799},[563,2329,672],{"class":664},[563,2331,598],{"class":580},[563,2333,678],{"class":677},[563,2335,1305],{"class":681},[563,2337,672],{"class":677},[563,2339,846],{"class":580},[563,2341,2342,2344,2346,2348,2350,2352,2354,2356,2358,2360,2362,2364,2366,2368,2370,2372,2374,2376,2378],{"class":565,"line":984},[563,2343,735],{"class":664},[563,2345,2246],{"class":738},[563,2347,672],{"class":664},[563,2349,598],{"class":580},[563,2351,1282],{"class":580},[563,2353,678],{"class":664},[563,2355,739],{"class":799},[563,2357,672],{"class":664},[563,2359,598],{"class":580},[563,2361,766],{"class":580},[563,2363,672],{"class":677},[563,2365,434],{"class":681},[563,2367,672],{"class":677},[563,2369,1310],{"class":580},[563,2371,678],{"class":677},[563,2373,2046],{"class":681},[563,2375,672],{"class":677},[563,2377,2051],{"class":580},[563,2379,846],{"class":580},[563,2381,2382,2384,2386,2388,2390,2392,2394,2396,2398,2400,2402,2404,2406,2408,2410,2412,2414,2416,2418],{"class":565,"line":990},[563,2383,735],{"class":664},[563,2385,2255],{"class":738},[563,2387,672],{"class":664},[563,2389,598],{"class":580},[563,2391,1282],{"class":580},[563,2393,678],{"class":664},[563,2395,739],{"class":799},[563,2397,672],{"class":664},[563,2399,598],{"class":580},[563,2401,766],{"class":580},[563,2403,672],{"class":677},[563,2405,434],{"class":681},[563,2407,672],{"class":677},[563,2409,1310],{"class":580},[563,2411,678],{"class":677},[563,2413,2046],{"class":681},[563,2415,672],{"class":677},[563,2417,2051],{"class":580},[563,2419,869],{"class":580},[563,2421,2422],{"class":565,"line":996},[563,2423,993],{"class":580},[563,2425,2426],{"class":565,"line":1002},[563,2427,999],{"class":580},[563,2429,2430],{"class":565,"line":1008},[563,2431,1005],{"class":580},[563,2433,2435],{"class":565,"line":2434},27,[563,2436,627],{"class":580},[302,2438,2439,2442,2443,361,2446,361,2449,361,2452,361,2454,2457,2458,2461,2462,2464,2465,2468,2469,2472],{},[311,2440,2441],{},"LengthAwarePaginator"," adds ",[311,2444,2445],{},"current_page",[311,2447,2448],{},"from",[311,2450,2451],{},"last_page",[311,2453,1838],{},[311,2455,2456],{},"to"," and ",[311,2459,2460],{},"total"," to ",[311,2463,1847],{},"; ",[311,2466,2467],{},"Paginator","\nthe meta of a simple pagination. A paginator returned as it is (",[311,2470,2471],{},"Book::query()->paginate()",", not wrapped in a\nresource) has the shape Laravel renders.",[320,2474,2476],{"id":2475},"responses-shared-by-a-controller","Responses shared by a controller",[302,2478,2479,2480,2482],{},"On the controller class, ",[311,2481,317],{}," is a response of each of its actions, listed after theirs:",[555,2484,2486],{"className":557,"code":2485,"language":559,"meta":553,"style":553},"#[Response(401, description: 'Unauthenticated')]\nfinal class SeatController\n{\n    #[Response(\n        201,\n        description: 'Seat booked',\n        type: 'array{seat: string, expires_at: string}',\n    )]\n    public function book(string $seat): JsonResponse\n    {\n        \u002F\u002F …\n    }\n}\n",[311,2487,2488,2517,2528,2532,2541,2548,2564,2580,2587,2612,2617,2622,2626],{"__ignoreMap":553},[563,2489,2490,2492,2494,2496,2499,2501,2504,2506,2508,2511,2513,2515],{"class":565,"line":566},[563,2491,1065],{"class":590},[563,2493,460],{"class":1038},[563,2495,581],{"class":580},[563,2497,2498],{"class":723},"401",[563,2500,1310],{"class":580},[563,2502,2503],{"class":1082}," description",[563,2505,598],{"class":580},[563,2507,1088],{"class":677},[563,2509,2510],{"class":681},"Unauthenticated",[563,2512,1094],{"class":677},[563,2514,594],{"class":580},[563,2516,1147],{"class":590},[563,2518,2519,2522,2525],{"class":565,"line":611},[563,2520,2521],{"class":569},"final",[563,2523,2524],{"class":569}," class",[563,2526,2527],{"class":1082}," SeatController\n",[563,2529,2530],{"class":565,"line":617},[563,2531,614],{"class":580},[563,2533,2534,2537,2539],{"class":565,"line":624},[563,2535,2536],{"class":590},"    #[",[563,2538,460],{"class":1038},[563,2540,1070],{"class":580},[563,2542,2543,2546],{"class":565,"line":630},[563,2544,2545],{"class":723},"        201",[563,2547,687],{"class":580},[563,2549,2550,2553,2555,2557,2560,2562],{"class":565,"line":637},[563,2551,2552],{"class":1082},"        description",[563,2554,598],{"class":580},[563,2556,1088],{"class":677},[563,2558,2559],{"class":681},"Seat booked",[563,2561,1094],{"class":677},[563,2563,687],{"class":580},[563,2565,2566,2569,2571,2573,2576,2578],{"class":565,"line":643},[563,2567,2568],{"class":1082},"        type",[563,2570,598],{"class":580},[563,2572,1088],{"class":677},[563,2574,2575],{"class":681},"array{seat: string, expires_at: string}",[563,2577,1094],{"class":677},[563,2579,687],{"class":580},[563,2581,2582,2585],{"class":565,"line":779},[563,2583,2584],{"class":580},"    )",[563,2586,1147],{"class":590},[563,2588,2589,2592,2594,2597,2599,2601,2603,2606,2608,2610],{"class":565,"line":793},[563,2590,2591],{"class":569},"    public",[563,2593,573],{"class":569},[563,2595,2596],{"class":576}," book",[563,2598,581],{"class":580},[563,2600,434],{"class":584},[563,2602,587],{"class":580},[563,2604,2605],{"class":590},"seat",[563,2607,594],{"class":580},[563,2609,598],{"class":597},[563,2611,1164],{"class":601},[563,2613,2614],{"class":565,"line":29},[563,2615,2616],{"class":580},"    {\n",[563,2618,2619],{"class":565,"line":823},[563,2620,2621],{"class":620},"        \u002F\u002F …\n",[563,2623,2624],{"class":565,"line":849},[563,2625,999],{"class":580},[563,2627,2628],{"class":565,"line":872},[563,2629,627],{"class":580},[302,2631,2632],{},"The action replaces a response of the controller for the same status, and a success of the action, declared or\ninferred, leaves out the successes of the controller for other statuses: the 401 of the controller stays, a 200 of\nthe controller would give way to the 201 of the action.",[320,2634,2636],{"id":2635},"server-sent-events","Server-sent events",[302,2638,2639,2640,361,2643,2645,2646,2649,2650,2653],{},"With ",[311,2641,2642],{},"mediaType: 'text\u002Fevent-stream'",[311,2644,739],{}," describes one event, written as ",[311,2647,2648],{},"itemSchema",". It needs OpenAPI 3.2: an\nearlier strict document fails on it, a lenient one (",[311,2651,2652],{},"strict: false",") drops it with a warning.",[555,2655,2657],{"className":557,"code":2656,"language":559,"meta":553,"style":553},"#[Response(\n    200,\n    mediaType: 'text\u002Fevent-stream',\n    type: 'array{event: string, data: string}',\n)]\npublic function stream(): StreamedResponse\n",[311,2658,2659,2667,2673,2688,2703,2709],{"__ignoreMap":553},[563,2660,2661,2663,2665],{"class":565,"line":566},[563,2662,1065],{"class":590},[563,2664,460],{"class":1038},[563,2666,1070],{"class":580},[563,2668,2669,2671],{"class":565,"line":611},[563,2670,1687],{"class":723},[563,2672,687],{"class":580},[563,2674,2675,2678,2680,2682,2684,2686],{"class":565,"line":617},[563,2676,2677],{"class":1082},"    mediaType",[563,2679,598],{"class":580},[563,2681,1088],{"class":677},[563,2683,1573],{"class":681},[563,2685,1094],{"class":677},[563,2687,687],{"class":580},[563,2689,2690,2692,2694,2696,2699,2701],{"class":565,"line":624},[563,2691,1101],{"class":1082},[563,2693,598],{"class":580},[563,2695,1088],{"class":677},[563,2697,2698],{"class":681},"array{event: string, data: string}",[563,2700,1094],{"class":677},[563,2702,687],{"class":580},[563,2704,2705,2707],{"class":565,"line":630},[563,2706,594],{"class":580},[563,2708,1147],{"class":590},[563,2710,2711,2713,2715,2718,2720,2722],{"class":565,"line":637},[563,2712,570],{"class":569},[563,2714,573],{"class":569},[563,2716,2717],{"class":576}," stream",[563,2719,1159],{"class":580},[563,2721,598],{"class":597},[563,2723,2724],{"class":601}," StreamedResponse\n",[320,2726,2728],{"id":2727},"error-responses","Error responses",[302,2730,2731,2732,2735,2736,2738],{},"The error responses (401, 403, 404, 422, 429 and those of the ",[311,2733,2734],{},"@throws",") are added by the generator. See\n",[542,2737,162],{"href":163},".",[2740,2741,2742],"style",{},"html pre.shiki code .sbsja, html code.shiki .sbsja{--shiki-light:#9C3EDA;--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sGLFI, html code.shiki .sGLFI{--shiki-light:#6182B8;--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sP7_E, html code.shiki .sP7_E{--shiki-light:#39ADB5;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sw1J6, html code.shiki .sw1J6{--shiki-light:#F76D47;--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .su5hD, html code.shiki .su5hD{--shiki-light:#90A4AE;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .smGrS, html code.shiki .smGrS{--shiki-light:#39ADB5;--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sZMiF, html code.shiki .sZMiF{--shiki-light:#E2931D;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sutJx, html code.shiki .sutJx{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#6A737D;--shiki-default-font-style:inherit;--shiki-dark:#6A737D;--shiki-dark-font-style:inherit}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);}html pre.shiki code .s39Yj, html code.shiki .s39Yj{--shiki-light:#39ADB5;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sseR_, html code.shiki .sseR_{--shiki-light:#9C3EDA;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sjJ54, html code.shiki .sjJ54{--shiki-light:#39ADB5;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .s_sjI, html code.shiki .s_sjI{--shiki-light:#91B859;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .srdBf, html code.shiki .srdBf{--shiki-light:#F76D47;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .swQdS, html code.shiki .swQdS{--shiki-light:#E53935;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sAQsV, html code.shiki .sAQsV{--shiki-light:#916B53;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sptTA, html code.shiki .sptTA{--shiki-light:#6182B8;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .syTEX, html code.shiki .syTEX{--shiki-light:#FF5370;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .s_hVV, html code.shiki .s_hVV{--shiki-light:#90A4AE;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sbgvK, html code.shiki .sbgvK{--shiki-light:#E2931D;--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sVHd0, html code.shiki .sVHd0{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#D73A49;--shiki-default-font-style:inherit;--shiki-dark:#F97583;--shiki-dark-font-style:inherit}",{"title":553,"searchDepth":617,"depth":617,"links":2744},[2745,2746,2747,2748,2749,2750],{"id":322,"depth":611,"text":323},{"id":1013,"depth":611,"text":1014},{"id":1632,"depth":611,"text":1633},{"id":2475,"depth":611,"text":2476},{"id":2635,"depth":611,"text":2636},{"id":2727,"depth":611,"text":2728},"Document the responses of an action from its return type, and declare what the return type cannot tell.","md",{},"---\ntitle: Responses\ndescription: Document the responses of an action from its return type, and declare what the return type cannot tell.\n---\n\nThe responses of an operation come from the **return type** of its action, completed by its PHPDoc `@return`. Type\nthe return of every action: without it, the operation gets no response, and a diagnostic.\n`#[Response]` declares what a return type cannot say: a status, a paginator, headers.\n\n## From the return type\n\n| The action returns | The response |\n| --- | --- |\n| `UserResource` | 200 (201 for `POST`) with `{\"data\": User}`, `User` being a component |\n| `AnonymousResourceCollection` with `@return AnonymousResourceCollection\u003CUserResource>`, or a `ResourceCollection` | 200 with `{\"data\": [User]}` |\n| `UserResource\\|AdminResource` | `oneOf` the two components, with a discriminator when a property tells them apart |\n| A model, a collection of models | its attributes, from its casts, `@property` and columns |\n| `array` with `@return array{id: int, tags: list\u003Cstring>}` | that shape |\n| `int`, `string`, `bool`… | that scalar |\n| `JsonResponse` | an object without properties, and an info: declare the body with `#[Response]` |\n| `Response` returned by a `DELETE`, `noContent()` | 204 |\n| `void` | an empty 200 |\n| `RedirectResponse` | 302 with a `Location` header |\n| `BinaryFileResponse`, `StreamedResponse` | `application\u002Foctet-stream`, binary; `Content-Disposition` for a file |\n| A `Responsable` | what its `toResponse()` returns, run on a sample |\n| A view | not documented |\n\nThe resources are described by running them on sampled models; see\n[Sampling](\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fsampling) for how, and for which keys are required.\n\n::example{input=\"app\u002FHttp\u002FControllers\u002FPetController.php\" output=\"responses.200\"}\n#input\n```php\npublic function show(int $id): CatResource|DogResource\n{\n    \u002F\u002F …\n}\n\n\u002F\u002F CatResource::toArray(): ['type' => 'cat', 'id' => …, 'name' => …]\n\u002F\u002F DogResource::toArray(): ['type' => 'dog', 'id' => …, 'name' => …]\n```\n#output\n```json\n{\n  \"description\": \"OK\",\n  \"content\": {\n    \"application\u002Fjson\": {\n      \"schema\": {\n        \"type\": \"object\",\n        \"required\": [\"data\"],\n        \"properties\": {\n          \"data\": {\n            \"oneOf\": [\n              { \"$ref\": \"#\u002Fcomponents\u002Fschemas\u002FCat\" },\n              { \"$ref\": \"#\u002Fcomponents\u002Fschemas\u002FDog\" }\n            ],\n            \"discriminator\": {\n              \"propertyName\": \"type\",\n              \"mapping\": {\n                \"cat\": \"#\u002Fcomponents\u002Fschemas\u002FCat\",\n                \"dog\": \"#\u002Fcomponents\u002Fschemas\u002FDog\"\n              }\n            }\n          }\n        }\n      }\n    }\n  }\n}\n```\n::\n\n## Declaring a response\n\n`#[Response]` is repeatable. On the action, it replaces the response inferred for its status:\n\n::example{input=\"app\u002FHttp\u002FControllers\u002FSearchIndexController.php\" output=\"responses\"}\n#input\n```php\nuse Ark4ne\\OpenApi\\Attributes\\Response;\n\n#[Response(\n    202,\n    description: 'Queued',\n    type: 'array{job: string}',\n    headers: ['Retry-After' => 'positive-int'],\n)]\npublic function rebuild(): JsonResponse\n{\n    return new JsonResponse(['job' => $job->id], 202);\n}\n```\n#output\n```json\n{\n  \"202\": {\n    \"description\": \"Queued\",\n    \"headers\": {\n      \"Retry-After\": { \"schema\": { \"type\": \"integer\", \"minimum\": 1 } }\n    },\n    \"content\": {\n      \"application\u002Fjson\": {\n        \"schema\": {\n          \"type\": \"object\",\n          \"required\": [\"job\"],\n          \"properties\": { \"job\": { \"type\": \"string\" } },\n          \"additionalProperties\": false\n        }\n      }\n    }\n  }\n}\n```\n::\n\nA `JsonResponse` is inferred as a 200 whatever status it is built with. A declared **success** (2xx) leaves out the\nsuccesses inferred for other statuses: here the 202 replaces the 200.\n\n| Parameter | Gives |\n| --- | --- |\n| `status` | the status, `200` by default, or `'default'` |\n| `description` | the description, the HTTP phrase of the status by default |\n| `resource` | the body from a resource or a resource collection |\n| `type` | the body from a [PHPDoc type](\u002Flaravel-openapi-generator\u002Freference\u002Fphpdoc-types): `array{id: int}`, `list\u003Cstring>` |\n| `mediaType` | `application\u002Fjson` by default; with `text\u002Fevent-stream`, `type` is one event |\n| `headers` | header name → PHPDoc type of its value |\n| `paginator` | the paginator of `resource` |\n| `example` | an example of the body |\n| `summary` | a short summary (3.2) |\n\nWithout `resource` nor `type`, the attribute keeps the body inferred for its status, or given by the exceptions of\nthat status: `#[Response(404, description: 'No such book')]` renames the 404 only.\n\n## Paginated collections\n\nThe return type of `Book::paginate()` wrapped in a collection does not tell the paginator. Declare it:\n\n::example{input=\"app\u002FHttp\u002FControllers\u002FBookController.php\" output=\"responses.200.content.application\u002Fjson.schema\"}\n#input\n```php\nuse Illuminate\\Pagination\\CursorPaginator;\n\n#[Response(\n    200,\n    resource: BookResource::class,\n    paginator: CursorPaginator::class,\n)]\npublic function index(): AnonymousResourceCollection\n{\n    return BookResource::collection(Book::query()->cursorPaginate());\n}\n```\n#output\n```json\n{\n  \"type\": \"object\",\n  \"required\": [\"data\", \"links\", \"meta\"],\n  \"properties\": {\n    \"data\": { \"type\": \"array\", \"items\": { \"$ref\": \"#\u002Fcomponents\u002Fschemas\u002FBook\" } },\n    \"links\": {\n      \"type\": \"object\",\n      \"required\": [\"first\", \"last\", \"prev\", \"next\"],\n      \"properties\": {\n        \"first\": { \"type\": [\"string\", \"null\"] },\n        \"last\": { \"type\": [\"string\", \"null\"] },\n        \"prev\": { \"type\": [\"string\", \"null\"] },\n        \"next\": { \"type\": [\"string\", \"null\"] }\n      }\n    },\n    \"meta\": {\n      \"type\": \"object\",\n      \"required\": [\"path\", \"per_page\", \"next_cursor\", \"prev_cursor\"],\n      \"properties\": {\n        \"path\": { \"type\": [\"string\", \"null\"] },\n        \"per_page\": { \"type\": \"integer\" },\n        \"next_cursor\": { \"type\": [\"string\", \"null\"] },\n        \"prev_cursor\": { \"type\": [\"string\", \"null\"] }\n      }\n    }\n  }\n}\n```\n::\n\n`LengthAwarePaginator` adds `current_page`, `from`, `last_page`, `links`, `to` and `total` to `meta`; `Paginator`\nthe meta of a simple pagination. A paginator returned as it is (`Book::query()->paginate()`, not wrapped in a\nresource) has the shape Laravel renders.\n\n## Responses shared by a controller\n\nOn the controller class, `#[Response]` is a response of each of its actions, listed after theirs:\n\n```php\n#[Response(401, description: 'Unauthenticated')]\nfinal class SeatController\n{\n    #[Response(\n        201,\n        description: 'Seat booked',\n        type: 'array{seat: string, expires_at: string}',\n    )]\n    public function book(string $seat): JsonResponse\n    {\n        \u002F\u002F …\n    }\n}\n```\n\nThe action replaces a response of the controller for the same status, and a success of the action, declared or\ninferred, leaves out the successes of the controller for other statuses: the 401 of the controller stays, a 200 of\nthe controller would give way to the 201 of the action.\n\n## Server-sent events\n\nWith `mediaType: 'text\u002Fevent-stream'`, `type` describes one event, written as `itemSchema`. It needs OpenAPI 3.2: an\nearlier strict document fails on it, a lenient one (`strict: false`) drops it with a warning.\n\n```php\n#[Response(\n    200,\n    mediaType: 'text\u002Fevent-stream',\n    type: 'array{event: string, data: string}',\n)]\npublic function stream(): StreamedResponse\n```\n\n## Error responses\n\nThe error responses (401, 403, 404, 422, 429 and those of the `@throws`) are added by the generator. See\n[Security & errors](\u002Flaravel-openapi-generator\u002Fdocumenting-endpoints\u002Fsecurity-and-errors).\n",{"title":154,"description":2751},"2ZjA7UfE_1L4CMvdV6YqS-foWTrC53DDelg95eSsVIQ",[2758,2760],{"title":150,"path":151,"stem":152,"description":2759,"children":-1},"Document query parameters, request bodies, headers and cookies from form requests and attributes.",{"title":158,"path":159,"stem":160,"description":2761,"children":-1},"How resources are described by running them on sampled models, and how to help when a resource fails.",1795438903274]