text: (window.webpackJsonp=window.webpackJsonp||[]).push([[94],{167:function(e,n,t){"use strict";t.r(n),t.d(n,"frontMatter",(function(){return o})),t.d(n,"metadata",(function(){return p})),t.d(n,"toc",(function(){return s})),t.d(n,"default",(function(){return m}));var a=t(3),i=t(7),r=(t(0),t(185)),c=t(186),l=t(193),b=t(194),o={id:"specification-document",title:"6. \u89c4\u8303\u5316\u63a5\u53e3\u6587\u6863",sidebar_label:"6. \u89c4\u8303\u5316\u63a5\u53e3\u6587\u6863"},p={unversionedId:"specification-document",id:"specification-document",isDocsHomePage:!1,title:"6. \u89c4\u8303\u5316\u63a5\u53e3\u6587\u6863",description:"6.1 \u4ec0\u4e48\u662f\u63a5\u53e3\u6587\u6863",source:"@site/docs\\specification-document.mdx",slug:"/specification-document",permalink:"/furion/docs/specification-document",editUrl:"https://gitee.com/monksoul/Furion/tree/master/handbook/docs/specification-document.mdx",version:"current",sidebar_label:"6. \u89c4\u8303\u5316\u63a5\u53e3\u6587\u6863",sidebar:"docs",previous:{title:"5. \u52a8\u6001 WebAPI",permalink:"/furion/docs/dynamic-api-controller"},next:{title:"7. \u53cb\u597d\u5f02\u5e38\u5904\u7406",permalink:"/furion/docs/friendly-exception"}},s=[{value:"6.1 \u4ec0\u4e48\u662f\u63a5\u53e3\u6587\u6863",id:"61-\u4ec0\u4e48\u662f\u63a5\u53e3\u6587\u6863",children:[]},{value:"6.2 \u4e3a\u4ec0\u4e48\u8981\u5199\u63a5\u53e3\u6587\u6863",id:"62-\u4e3a\u4ec0\u4e48\u8981\u5199\u63a5\u53e3\u6587\u6863",children:[]},{value:"6.3 \u4e3a\u4ec0\u4e48\u9700\u8981\u89c4\u8303\u5316\u6587\u6863",id:"63-\u4e3a\u4ec0\u4e48\u9700\u8981\u89c4\u8303\u5316\u6587\u6863",children:[{value:"6.3.1 \u534f\u8bae\u89c4\u8303",id:"631-\u534f\u8bae\u89c4\u8303",children:[]},{value:"6.3.2 \u63a5\u53e3\u8def\u5f84\u89c4\u8303",id:"632-\u63a5\u53e3\u8def\u5f84\u89c4\u8303",children:[]},{value:"6.3.3 \u7248\u672c\u63a7\u5236\u89c4\u8303",id:"633-\u7248\u672c\u63a7\u5236\u89c4\u8303",children:[]},{value:"6.3.4 \u63a5\u53e3\u547d\u540d\u89c4\u8303",id:"634-\u63a5\u53e3\u547d\u540d\u89c4\u8303",children:[]},{value:"6.3.5 \u8bf7\u6c42\u53c2\u6570\u89c4\u8303",id:"635-\u8bf7\u6c42\u53c2\u6570\u89c4\u8303",children:[]},{value:"6.3.6 \u8fd4\u56de\u6570\u636e\u89c4\u8303",id:"636-\u8fd4\u56de\u6570\u636e\u89c4\u8303",children:[]}]},{value:"6.4 \u4ec0\u4e48\u662f Swagger",id:"64-\u4ec0\u4e48\u662f-swagger",children:[]},{value:"6.5 Swagger \u4f7f\u7528",id:"65-swagger-\u4f7f\u7528",children:[{value:"6.5.1 \u6ce8\u518c\u670d\u52a1",id:"651-\u6ce8\u518c\u670d\u52a1",children:[]},{value:"6.5.2 \u9ed8\u8ba4\u5730\u5740",id:"652-\u9ed8\u8ba4\u5730\u5740",children:[]},{value:"6.5.3 \u9ed8\u8ba4\u5206\u7ec4",id:"653-\u9ed8\u8ba4\u5206\u7ec4",children:[]},{value:"6.5.4 \u6587\u6863\u6ce8\u91ca",id:"654-\u6587\u6863\u6ce8\u91ca",children:[]},{value:"6.5.5 \u591a\u5206\u7ec4\u652f\u6301",id:"655-\u591a\u5206\u7ec4\u652f\u6301",children:[]},{value:"6.5.6 \u591a\u5206\u7ec4\u6392\u5e8f",id:"656-\u591a\u5206\u7ec4\u6392\u5e8f",children:[]},{value:"6.5.7 \u591a\u5206\u7ec4\u4fe1\u606f\u914d\u7f6e",id:"657-\u591a\u5206\u7ec4\u4fe1\u606f\u914d\u7f6e",children:[]},{value:"6.5.8 \u7ec4\u4e2d\u7ec4\uff08\u6807\u7b7e\uff09",id:"658-\u7ec4\u4e2d\u7ec4\uff08\u6807\u7b7e\uff09",children:[]},{value:"6.5.9 \u9ed8\u8ba4\u5c55\u5f00\u6240\u6709\u6587\u6863",id:"659-\u9ed8\u8ba4\u5c55\u5f00\u6240\u6709\u6587\u6863",children:[]},{value:"6.5.10 \u914d\u7f6e\u6587\u6863\u6807\u9898",id:"6510-\u914d\u7f6e\u6587\u6863\u6807\u9898",children:[]},{value:"6.5.11 \u6388\u6743\u63a7\u5236",id:"6511-\u6388\u6743\u63a7\u5236",children:[]},{value:"6.5.12 \u5728\u7ebf\u6d4b\u8bd5",id:"6512-\u5728\u7ebf\u6d4b\u8bd5",children:[]},{value:"6.5.13 \u6027\u80fd\u76d1\u89c6 <code>MiniProfiler</code>",id:"6513-\u6027\u80fd\u76d1\u89c6-miniprofiler",children:[]},{value:"6.5.14 \u5b9a\u4e49\u63a5\u53e3\u8f93\u51fa\u7c7b\u578b",id:"6514-\u5b9a\u4e49\u63a5\u53e3\u8f93\u51fa\u7c7b\u578b",children:[]},{value:"6.5.15 \u9690\u85cf\u7279\u5b9a\u5206\u7ec4",id:"6515-\u9690\u85cf\u7279\u5b9a\u5206\u7ec4",children:[]}]},{value:"6.6 <code>SpecificationDocumentSettings</code> \u914d\u7f6e",id:"66-specificationdocumentsettings-\u914d\u7f6e",children:[]},{value:"6.7 \u7edf\u4e00\u8fd4\u56de\u503c\u6a21\u578b",id:"67-\u7edf\u4e00\u8fd4\u56de\u503c\u6a21\u578b",children:[{value:"6.7.1 \u6392\u9664\u89c4\u8303\u5316\u5904\u7406",id:"671-\u6392\u9664\u89c4\u8303\u5316\u5904\u7406",children:[]},{value:"6.7.2 \u89c4\u8303\u5316\u7ed3\u679c\u6dfb\u52a0\u989d\u5916\u6570\u636e",id:"672-\u89c4\u8303\u5316\u7ed3\u679c\u6dfb\u52a0\u989d\u5916\u6570\u636e",children:[]}]},{value:"6.8 \u53cd\u9988\u4e0e\u5efa\u8bae",id:"68-\u53cd\u9988\u4e0e\u5efa\u8bae",children:[]}],u={toc:s};function m(e){var n=e.components,t=Object(i.a)(e,["components"]);return Object(r.b)("wrapper",Object(a.a)({},u,t,{components:n,mdxType:"MDXLayout"}),Object(r.b)("h2",{id:"61-\u4ec0\u4e48\u662f\u63a5\u53e3\u6587\u6863"},"6.1 \u4ec0\u4e48\u662f\u63a5\u53e3\u6587\u6863"),Object(r.b)("p",null,"\u5728\u73b0\u5728\u79fb\u52a8\u4e3a\u738b\u3001\u591a\u7aef\u4e92\u8f85\u3001\u524d\u7aef\u767e\u82b1\u9f50\u653e\u7684\u5f00\u653e\u65f6\u4ee3\uff0c\u4e0d\u518d\u662f\u4e00\u4eba\u5305\u63fd\u5f0f\u5f00\u53d1\uff0c\u5927\u5bb6\u5404\u53f8\u5176\u804c\uff0c\u540e\u7aef\u5de5\u7a0b\u5e08\u8d1f\u8d23\u63a5\u53e3\u5f00\u53d1\uff0c\u524d\u7aef\u8d1f\u8d23\u63a5\u53e3\u8054\u8c03\uff0c\u4e5f\u5c31\u662f\u4e92\u8054\u7f51\u73b0\u5728\u6d41\u884c\u7684\u524d\u540e\u7aef\u5206\u79bb\u67b6\u6784\u3002"),Object(r.b)("p",null,"\u6240\u4ee5\u5c31\u9700\u8981\u7531\u524d\u540e\u7aef\u5de5\u7a0b\u5e08\u5171\u540c\u5b9a\u4e49\u63a5\u53e3\uff0c\u7f16\u5199\u63a5\u53e3\u6587\u6863\uff0c\u4e4b\u540e\u5927\u5bb6\u6309\u7167\u8fd9\u4e2a\u63a5\u53e3\u6587\u6863\u8fdb\u884c\u5f00\u53d1\u3001\u7ef4\u62a4\u53ca\u5f00\u653e\u7ed9\u7b2c\u4e09\u65b9\u3002"),Object(r.b)("h2",{id:"62-\u4e3a\u4ec0\u4e48\u8981\u5199\u63a5\u53e3\u6587\u6863"},"6.2 \u4e3a\u4ec0\u4e48\u8981\u5199\u63a5\u53e3\u6587\u6863"),Object(r.b)("ul",null,Object(r.b)("li",{parentName:"ul"},"\u80fd\u591f\u8ba9\u524d\u7aef\u5f00\u53d1\u4e0e\u540e\u53f0\u5f00\u53d1\u4eba\u5458\u66f4\u597d\u7684\u914d\u5408\uff0c\u63d0\u9ad8\u5de5\u4f5c\u6548\u7387"),Object(r.b)("li",{parentName:"ul"},"\u9879\u76ee\u8fed\u4ee3\u6216\u8005\u9879\u76ee\u4eba\u5458\u66f4\u8fed\u65f6\uff0c\u65b9\u4fbf\u540e\u671f\u4eba\u5458\u67e5\u770b\u548c\u7ef4\u62a4"),Object(r.b)("li",{parentName:"ul"},"\u65b9\u4fbf\u6d4b\u8bd5\u4eba\u5458\u8fdb\u884c\u63a5\u53e3\u6d4b\u8bd5")),Object(r.b)("h2",{id:"63-\u4e3a\u4ec0\u4e48\u9700\u8981\u89c4\u8303\u5316\u6587\u6863"},"6.3 \u4e3a\u4ec0\u4e48\u9700\u8981\u89c4\u8303\u5316\u6587\u6863"),Object(r.b)("p",null,"\u7531\u4e8e\u6bcf\u4e2a\u516c\u53f8\u540e\u7aef\u4eba\u5458\u6280\u672f\u53c2\u5dee\u4e0d\u9f50\uff0c\u6280\u672f\u6587\u6863\u80fd\u529b\u4e5f\u4e0d\u4f8b\u5916\uff0c\u5bfc\u81f4\u63a5\u53e3\u5b9a\u4e49\u53ca\u6587\u6863\u4e94\u82b1\u516b\u95e8\uff0c\u4e0d\u540c\u9879\u76ee\u6216\u4e0d\u540c\u516c\u53f8\u5bf9\u63a5\u6781\u5176\u56f0\u96be\uff0c\u800c\u4e14\u4f53\u9a8c\u7cdf\u7cd5\u3002\u6240\u4ee5\uff0c\u65e0\u89c4\u77e9\u4e0d\u6210\u65b9\u5706\uff0c\u4e3a\u4e86\u5f00\u53d1\u4eba\u5458\u95f4\u66f4\u597d\u7684\u914d\u5408\uff0c\u8feb\u5207\u9700\u8981\u6574\u7406\u51fa\u4e00\u5957\u89c4\u8303\u3002"),Object(r.b)("p",null,"\u901a\u5e38\u63a5\u53e3\u89c4\u8303\u5206\u4e3a\u516d\u4e2a\u90e8\u5206\uff1a"),Object(r.b)("h3",{id:"631-\u534f\u8bae\u89c4\u8303"},"6.3.1 \u534f\u8bae\u89c4\u8303"),Object(r.b)("p",null,"\u4e3a\u4e86\u786e\u4fdd\u4e0d\u540c\u7cfb\u7edf/\u6a21\u5757\u95f4\u7684\u6570\u636e\u4ea4\u4e92\uff0c\u9700\u8981\u4e8b\u5148\u7ea6\u5b9a\u597d\u901a\u8baf\u534f\u8bae\uff0c\u5982\uff1aTCP\u3001HTTP\u3001HTTPS \u534f\u8bae\u3002\u4e3a\u4e86\u786e\u4fdd\u6570\u636e\u4ea4\u4e92\u5b89\u5168\uff0c\u5efa\u8bae\u4f7f\u7528 HTTPS \u534f\u8bae"),Object(r.b)("h3",{id:"632-\u63a5\u53e3\u8def\u5f84\u89c4\u8303"},"6.3.2 \u63a5\u53e3\u8def\u5f84\u89c4\u8303"),Object(r.b)("p",null,"\u4f5c\u4e3a\u63a5\u53e3\u8def\u5f84\uff0c\u4e3a\u4e86\u65b9\u4fbf\u6e05\u6670\u7684\u533a\u5206\u6765\u81ea\u4e0d\u540c\u7684\u7cfb\u7edf\uff0c\u53ef\u4ee5\u91c7\u7528\u4e0d\u540c\u7cfb\u7edf/\u6a21\u5757\u540d\u4f5c\u4e3a\u63a5\u53e3\u8def\u5f84\u524d\u7f00\uff0c\u5982\uff1a\u652f\u4ed8\u6a21\u5757\uff1a",Object(r.b)("inlineCode",{parentName:"p"},"/pay/xxx"),"\uff0c\u8ba2\u5355\u6a21\u5757\uff1a",Object(r.b)("inlineCode",{parentName:"p"},"/order/xxx")),Object(r.b)("h3",{id:"633-\u7248\u672c\u63a7\u5236\u89c4\u8303"},"6.3.3 \u7248\u672c\u63a7\u5236\u89c4\u8303"),Object(r.b)("p",null,'\u4e3a\u4e86\u4fbf\u4e8e\u540e\u671f\u63a5\u53e3\u7684\u5347\u7ea7\u548c\u7ef4\u62a4\uff0c\u5efa\u8bae\u5728\u63a5\u53e3\u8def\u5f84\u4e2d\u52a0\u5165\u7248\u672c\u53f7\uff0c\u4fbf\u4e8e\u7ba1\u7406\uff0c\u5b9e\u73b0\u63a5\u53e3\u591a\u7248\u672c\u7684\u53ef\u7ef4\u62a4\u6027\u3002\u5982\uff1a\u63a5\u53e3\u8def\u5f84\u4e2d\u6dfb\u52a0\u7c7b\u4f3c"',Object(r.b)("inlineCode",{parentName:"p"},"v1"),'"\u3001"',Object(r.b)("inlineCode",{parentName:"p"},"v2"),'"\u7b49\u7248\u672c\u53f7'),Object(r.b)("h3",{id:"634-\u63a5\u53e3\u547d\u540d\u89c4\u8303"},"6.3.4 \u63a5\u53e3\u547d\u540d\u89c4\u8303"),Object(r.b)("p",null,'\u548c C# \u547d\u540d\u89c4\u8303\u4e00\u6837\uff0c\u597d\u7684\u3001\u7edf\u4e00\u7684\u63a5\u53e3\u547d\u540d\u89c4\u8303\uff0c\u4e0d\u4ec5\u53ef\u4ee5\u589e\u5f3a\u5176\u53ef\u8bfb\u6027\uff0c\u800c\u4e14\u8fd8\u4f1a\u51cf\u5c11\u5f88\u591a\u4e0d\u5fc5\u8981\u7684\u53e3\u5934/\u4e66\u9762\u4e0a\u7684\u89e3\u91ca\u3002\uff0c\u53ef\u4f7f\u7528"\u9a7c\u5cf0\u547d\u540d\u6cd5"\u6309\u7167\u5b9e\u73b0\u63a5\u53e3\u7684',Object(r.b)("strong",{parentName:"p"},"\u4e1a\u52a1\u7c7b\u578b\u3001\u4e1a\u52a1\u573a\u666f"),"\u7b49\u547d\u540d\uff0c\u6709\u5fc5\u8981\u65f6\u53ef\u91c7\u53d6\u591a\u7ea7\u76ee\u5f55\u547d\u540d\uff0c\u4f46\u76ee\u5f55\u4e0d\u5b9c\u8fc7\u957f\uff0c\u4e24\u7ea7\u76ee\u5f55\u8f83\u4e3a\u9002\u5b9c"),Object(r.b)("ul",null,Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"\u5e38\u89c1\u547d\u540d\u65b9\u5f0f"),":",Object(r.b)("ul",{parentName:"li"},Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"\u63a5\u53e3\u540d\u79f0\u52a8\u8bcd\u524d/\u540e\u7f00\u5316"),"\uff1a \u63a5\u53e3\u540d\u79f0\u4ee5\u63a5\u53e3\u6570\u636e\u64cd\u4f5c\u7684\u52a8\u8bcd\u4e3a\u524d/\u540e\u7f00\uff0c\u5e38\u89c1\u52a8\u8bcd\u6709\uff1a",Object(r.b)("inlineCode",{parentName:"li"},"Add\u3001Delete\u3001Update\u3001Query\u3001Get\u3001Send\u3001Save\u3001Detail\u3001List"),"\u7b49\uff0c\u5982\uff1a\u65b0\u5efa\u7528\u6237 ",Object(r.b)("inlineCode",{parentName:"li"},"AddUser"),"\u3001\u67e5\u8be2\u8ba2\u5355\u8be6\u60c5 ",Object(r.b)("inlineCode",{parentName:"li"},"QueryOrderDetail"),"\u3002"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"\u63a5\u53e3\u540d\u79f0\u52a8\u8bcd + \u8bf7\u6c42\u65b9\u5f0f"),"\uff1a\u63a5\u53e3\u8def\u5f84\u4e2d\u5305\u542b\u5177\u4f53\u63a5\u53e3\u540d\u79f0\u7684\u540d\u8bcd\uff0c\u63a5\u53e3\u6570\u636e\u64cd\u4f5c\u52a8\u4f5c\u4ee5 HTTP \u8bf7\u6c42\u65b9\u5f0f\u6765\u533a\u5206\u3002\u5e38\u7528\u7684 HTTP \u8bf7\u6c42\u65b9\u5f0f\u6709\uff1a",Object(r.b)("ul",{parentName:"li"},Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"GET"),"\uff1a\u4ece\u670d\u52a1\u5668\u53d6\u51fa\u8d44\u6e90\uff08\u4e00\u9879\u6216\u591a\u9879\uff09"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"POST"),"\uff1a\u5728\u670d\u52a1\u5668\u65b0\u5efa\u4e00\u4e2a\u8d44\u6e90"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"PUT"),"\uff1a\u5728\u670d\u52a1\u5668\u66f4\u65b0\u8d44\u6e90\uff08\u5ba2\u6237\u7aef\u63d0\u4f9b\u6539\u53d8\u540e\u7684\u5b8c\u6574\u8d44\u6e90\uff09"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"PATCH"),"\uff1a\u5728\u670d\u52a1\u5668\u66f4\u65b0\u8d44\u6e90\uff08\u5ba2\u6237\u7aef\u63d0\u4f9b\u6539\u53d8\u7684\u5c5e\u6027\uff09"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"DELETE"),"\uff1a\u4ece\u670d\u52a1\u5668\u5220\u9664\u8d44\u6e90")))))),Object(r.b)("h3",{id:"635-\u8bf7\u6c42\u53c2\u6570\u89c4\u8303"},"6.3.5 \u8bf7\u6c42\u53c2\u6570\u89c4\u8303"),Object(r.b)("ul",null,Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"\u8bf7\u6c42\u65b9\u5f0f"),"\uff1a\u6309\u7167 ",Object(r.b)("inlineCode",{parentName:"li"},"GET\u3001POST\u3001PUT")," \u7b49\u542b\u4e49\u5b9a\u4e49\uff0c\u907f\u514d\u51fa\u73b0\u4e0d\u4e00\u81f4\u73b0\u8c61\uff0c\u5bf9\u4eba\u9020\u6210\u8bef\u89e3\u3001\u6b67\u4e49",Object(r.b)("ul",{parentName:"li"},Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"\u8bf7\u6c42\u5934"),"\uff1a\u8bf7\u6c42\u5934\u6839\u636e\u9879\u76ee\u9700\u6c42\u6dfb\u52a0\u914d\u7f6e\u53c2\u6570\u3002\u5982\uff1a\u8bf7\u6c42\u6570\u636e\u683c\u5f0f\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"accept=application/json")," \u7b49\u3002\u5982\u6709\u9700\u8981\uff0c\u8bf7\u6c42\u5934\u53ef\u6839\u636e\u9879\u76ee\u9700\u6c42\u8981\u6c42\u4f20\u5165\u7528\u6237 token\u3001\u552f\u4e00\u9a8c\u7b7e\u7801\u7b49\u52a0\u5bc6\u6570\u636e"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"\u8bf7\u6c42\u53c2\u6570/\u8bf7\u6c42\u4f53"),"\uff1a \u8bf7\u6c42\u53c2\u6570\u5b57\u6bb5\uff0c\u5c3d\u53ef\u80fd\u4e0e\u6570\u636e\u5e93\u8868\u5b57\u6bb5\u3001\u5bf9\u8c61\u5c5e\u6027\u540d\u7b49\u4fdd\u6301\u4e00\u81f4\uff0c\u56e0\u4e3a\u4fdd\u6301\u4e00\u81f4\u662f\u6700\u7701\u4e8b\uff0c\u6700\u8212\u670d\u7684\u4e00\u4ef6\u4e8b")))),Object(r.b)("h3",{id:"636-\u8fd4\u56de\u6570\u636e\u89c4\u8303"},"6.3.6 \u8fd4\u56de\u6570\u636e\u89c4\u8303"),Object(r.b)("p",null,"\u7edf\u4e00\u89c4\u8303\u8fd4\u56de\u6570\u636e\u7684\u683c\u5f0f\uff0c\u5bf9\u5df1\u5bf9\u5f7c\u90fd\u6709\u597d\u5904\uff0c\u6b64\u5904\u4ee5 json \u683c\u5f0f\u4e3a\u4f8b\u3002\u8fd4\u56de\u6570\u636e\u5e94\u5305\u542b\uff1a",Object(r.b)("strong",{parentName:"p"},"\u8fd4\u56de\u72b6\u6001\u7801\u3001\u8fd4\u56de\u72b6\u6001\u4fe1\u606f\u3001\u5177\u4f53\u6570\u636e"),"\u3002",Object(r.b)("strong",{parentName:"p"},"\u8fd4\u56de\u6570\u636e\u4e2d\u7684\u72b6\u6001\u7801\u3001\u72b6\u6001\u4fe1\u606f\uff0c\u5e38\u6307\u5177\u4f53\u7684\u4e1a\u52a1\u72b6\u6001\uff0c\u4e0d\u5efa\u8bae\u548c HTTP \u72b6\u6001\u7801\u6df7\u5728\u4e00\u8d77"),"\u3002HTTP \u72b6\u6001\uff0c\u662f\u7528\u6765\u4f53\u73b0 HTTP \u94fe\u8def\u72b6\u6001\u60c5\u51b5\uff0c\u5982\uff1a404-Not Found\u3002HTTP \u72b6\u6001\u7801\u548c json \u7ed3\u679c\u4e2d\u7684\u72b6\u6001\u7801\uff0c\u5e76\u5b58\u5c1a\u53ef\uff0c\u7528\u4e8e\u4f53\u73b0\u4e0d\u540c\u7ef4\u5ea6\u7684\u72b6\u6001\u3002"),Object(r.b)("h2",{id:"64-\u4ec0\u4e48\u662f-swagger"},"6.4 \u4ec0\u4e48\u662f Swagger"),Object(r.b)("p",null,"\u76f8\u4fe1\u65e0\u8bba\u662f\u524d\u7aef\u8fd8\u662f\u540e\u7aef\u5f00\u53d1\uff0c\u90fd\u6216\u591a\u6216\u5c11\u5730\u88ab\u63a5\u53e3\u6587\u6863\u6298\u78e8\u8fc7\u3002\u524d\u7aef\u7ecf\u5e38\u62b1\u6028\u540e\u7aef\u7ed9\u7684\u63a5\u53e3\u6587\u6863\u4e0e\u5b9e\u9645\u60c5\u51b5\u4e0d\u4e00\u81f4\u3002\u540e\u7aef\u53c8\u89c9\u5f97\u7f16\u5199\u53ca\u7ef4\u62a4\u63a5\u53e3\u6587\u6863\u4f1a\u8017\u8d39\u4e0d\u5c11\u7cbe\u529b\uff0c\u7ecf\u5e38\u6765\u4e0d\u53ca\u66f4\u65b0\u3002"),Object(r.b)("p",null,"\u5176\u5b9e\u65e0\u8bba\u662f\u524d\u7aef\u8c03\u7528\u540e\u7aef\uff0c\u8fd8\u662f\u540e\u7aef\u8c03\u7528\u540e\u7aef\uff0c\u90fd\u671f\u671b\u6709\u4e00\u4e2a\u597d\u7684\u63a5\u53e3\u6587\u6863\u3002\u4f46\u662f\u8fd9\u4e2a\u63a5\u53e3\u6587\u6863\u5bf9\u4e8e\u7a0b\u5e8f\u5458\u6765\u8bf4\uff0c\u5c31\u8ddf\u6ce8\u91ca\u4e00\u6837\uff0c\u7ecf\u5e38\u4f1a\u62b1\u6028\u522b\u4eba\u5199\u7684\u4ee3\u7801\u6ca1\u6709\u5199\u6ce8\u91ca\uff0c\u7136\u800c\u81ea\u5df1\u5199\u8d77\u4ee3\u7801\u8d77\u6765\uff0c\u6700\u8ba8\u538c\u7684\uff0c\u4e5f\u662f\u5199\u6ce8\u91ca\u3002\u6240\u4ee5\u4ec5\u4ec5\u53ea\u901a\u8fc7\u5f3a\u5236\u6765\u89c4\u8303\u5927\u5bb6\u662f\u4e0d\u591f\u7684\uff0c\u968f\u7740\u65f6\u95f4\u63a8\u79fb\uff0c\u7248\u672c\u8fed\u4ee3\uff0c\u63a5\u53e3\u6587\u6863\u5f80\u5f80\u5f88\u5bb9\u6613\u5c31\u8ddf\u4e0d\u4e0a\u4ee3\u7801\u4e86\u3002"),Object(r.b)("p",null,Object(r.b)("strong",{parentName:"p"},"\u53d1\u73b0\u4e86\u75db\u70b9\u5c31\u8981\u53bb\u627e\u89e3\u51b3\u65b9\u6848\u3002\u89e3\u51b3\u65b9\u6848\u7528\u7684\u4eba\u591a\u4e86\uff0c\u5c31\u6210\u4e86\u6807\u51c6\u7684\u89c4\u8303\uff0c\u8fd9\u5c31\u662f ",Object(r.b)("inlineCode",{parentName:"strong"},"Swagger")," \u7684\u7531\u6765"),"\u3002"),Object(r.b)("p",null,"\u901a\u8fc7\u8fd9\u5957\u89c4\u8303\uff0c\u4f60\u53ea\u9700\u8981\u6309\u7167\u5b83\u7684\u89c4\u8303\u53bb\u5b9a\u4e49\u63a5\u53e3\u53ca\u63a5\u53e3\u76f8\u5173\u7684\u4fe1\u606f\u3002\u518d\u901a\u8fc7 ",Object(r.b)("inlineCode",{parentName:"p"},"Swagger")," \u884d\u751f\u51fa\u6765\u7684\u4e00\u7cfb\u5217\u9879\u76ee\u548c\u5de5\u5177\uff0c\u5c31\u53ef\u4ee5\u505a\u5230\u751f\u6210\u5404\u79cd\u683c\u5f0f\u7684\u63a5\u53e3\u6587\u6863\uff0c\u751f\u6210\u591a\u79cd\u8bed\u8a00\u7684\u5ba2\u6237\u7aef\u548c\u670d\u52a1\u7aef\u7684\u4ee3\u7801\uff0c\u4ee5\u53ca\u5728\u7ebf\u63a5\u53e3\u8c03\u8bd5\u9875\u9762\u7b49\u7b49\u3002"),Object(r.b)("p",null,"\u8fd9\u6837\uff0c\u5982\u679c\u6309\u7167\u65b0\u7684\u5f00\u53d1\u6a21\u5f0f\uff0c\u5728\u5f00\u53d1\u65b0\u7248\u672c\u6216\u8005\u8fed\u4ee3\u7248\u672c\u7684\u65f6\u5019\uff0c\u53ea\u9700\u8981\u66f4\u65b0 ",Object(r.b)("inlineCode",{parentName:"p"},"Swagger")," \u63cf\u8ff0\u6587\u4ef6\uff0c\u5c31\u53ef\u4ee5\u81ea\u52a8\u751f\u6210\u63a5\u53e3\u6587\u6863\u548c\u5ba2\u6237\u7aef\u670d\u52a1\u7aef\u4ee3\u7801\uff0c\u505a\u5230\u8c03\u7528\u7aef\u4ee3\u7801\u3001\u670d\u52a1\u7aef\u4ee3\u7801\u4ee5\u53ca\u63a5\u53e3\u6587\u6863\u7684\u4e00\u81f4\u6027\u3002"),Object(r.b)("p",null,"\u6240\u4ee5\uff0cSwagger \u662f\u4e00\u4e2a\u89c4\u8303\u548c\u5b8c\u6574\u7684\u6846\u67b6\uff0c\u7528\u4e8e\u751f\u6210\u3001\u63cf\u8ff0\u3001\u8c03\u7528\u548c\u53ef\u89c6\u5316",Object(r.b)("inlineCode",{parentName:"p"},"RESTful")," \u98ce\u683c\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"Web")," \u670d\u52a1\u3002"),Object(r.b)("p",null,"\u603b\u4f53\u76ee\u6807\u662f\u4f7f\u5ba2\u6237\u7aef\u548c\u6587\u4ef6\u7cfb\u7edf\u4f5c\u4e3a\u670d\u52a1\u5668\u4ee5\u540c\u6837\u7684\u901f\u5ea6\u6765\u66f4\u65b0\u3002\u6587\u4ef6\u7684\u65b9\u6cd5\u3001\u53c2\u6570\u548c\u6a21\u578b\u7d27\u5bc6\u96c6\u6210\u5230\u670d\u52a1\u5668\u7aef\u7684\u4ee3\u7801\uff0c\u5141\u8bb8 API \u6765\u59cb\u7ec8\u4fdd\u6301\u540c\u6b65\u3002",Object(r.b)("inlineCode",{parentName:"p"},"Swagger")," \u8ba9\u90e8\u7f72\u7ba1\u7406\u548c\u4f7f\u7528\u529f\u80fd\u5f3a\u5927\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"API")," \u4ece\u672a\u5982\u6b64\u7b80\u5355\u3002"),Object(r.b)("h2",{id:"65-swagger-\u4f7f\u7528"},"6.5 Swagger \u4f7f\u7528"),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u6846\u67b6\u63d0\u4f9b\u4e86\u975e\u5e38\u65b9\u4fbf\u4e14\u7075\u6d3b\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"Swagger")," \u914d\u7f6e\uff0c\u65e0\u9700\u589e\u52a0\u989d\u5916\u5b66\u4e60\u6210\u672c\u3002"),Object(r.b)("h3",{id:"651-\u6ce8\u518c\u670d\u52a1"},"6.5.1 \u6ce8\u518c\u670d\u52a1"),Object(r.b)("div",{className:"admonition admonition-important alert alert--info"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"16",viewBox:"0 0 14 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"})))),"\u5907\u6ce8")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},Object(r.b)("inlineCode",{parentName:"p"},".AddSpecificationDocuments()")," \u9ed8\u8ba4\u5df2\u7ecf\u7ee7\u627f\u5728 ",Object(r.b)("inlineCode",{parentName:"p"},"AddInject()")," \u4e2d\u4e86\uff0c\u65e0\u9700\u518d\u6b21\u6ce8\u518c\u3002"),Object(r.b)("p",{parentName:"div"},"\u53e6\u5916 ",Object(r.b)("inlineCode",{parentName:"p"},".UseInject()")," \u4e5f\u5df2\u7ecf\u5305\u542b\u4e86 ",Object(r.b)("inlineCode",{parentName:"p"},".UseSpecificationDocuments()")," \u6ce8\u518c\uff0c\u65e0\u9700\u518d\u6b21\u6ce8\u518c\u3002"))),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:'{11,21} title="Furion.Web.Core\\FurWebCoreStartup.cs"',"{11,21}":!0,title:'"Furion.Web.Core\\FurWebCoreStartup.cs"'}),"using Microsoft.AspNetCore.Builder;\nusing Microsoft.AspNetCore.Hosting;\nusing Microsoft.Extensions.DependencyInjection;\nusing Microsoft.Extensions.Hosting;\n\nnamespace Furion.Web.Core\n{\n    [AppStartup(800)]\n    public sealed class FurWebCoreStartup : AppStartup\n    {\n        public void ConfigureServices(IServiceCollection services)\n        {\n            services.AddSpecificationDocuments();\n            services.AddControllers();\n        }\n\n        public void Configure(IApplicationBuilder app, IWebHostEnvironment env)\n        {\n            // Other Codes\n\n            app.UseSpecificationDocuments();\n\n            app.UseEndpoints(endpoints =>\n            {\n                endpoints.MapControllers();\n            });\n        }\n    }\n}\n")),Object(r.b)("div",{className:"admonition admonition-tip alert alert--success"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"})))),"\u5c0f\u77e5\u8bc6")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},Object(r.b)("inlineCode",{parentName:"p"},"services.AddSpecificationDocuments()")," \u901a\u5e38\u548c ",Object(r.b)("inlineCode",{parentName:"p"},".AddDynamicApiControllers()")," \u6210\u5bf9\u51fa\u73b0\u3002"))),Object(r.b)("h3",{id:"652-\u9ed8\u8ba4\u5730\u5740"},"6.5.2 \u9ed8\u8ba4\u5730\u5740"),Object(r.b)("p",null,"\u5728 ",Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u6846\u67b6\u4e2d\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"p"},"\u89c4\u8303\u5316\u6587\u6863")," \u5730\u5740\u4e3a\u4e3b\u673a\u6839\u76ee\u5f55\uff0c",Object(r.b)("strong",{parentName:"p"},"\u652f\u6301\u81ea\u5b9a\u4e49\u914d\u7f6e"),"\u3002"),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger1.png")}),Object(r.b)("h3",{id:"653-\u9ed8\u8ba4\u5206\u7ec4"},"6.5.3 \u9ed8\u8ba4\u5206\u7ec4"),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u6846\u67b6\u4e2d\u9ed8\u8ba4\u5206\u7ec4\u540d\u4e3a ",Object(r.b)("inlineCode",{parentName:"p"},"Default"),"\uff0c",Object(r.b)("strong",{parentName:"p"},"\u652f\u6301\u81ea\u5b9a\u4e49\u914d\u7f6e"),"\u3002"),Object(r.b)("h3",{id:"654-\u6587\u6863\u6ce8\u91ca"},"6.5.4 \u6587\u6863\u6ce8\u91ca"),Object(r.b)("p",null,"\u89c4\u8303\u5316\u6587\u6863\u9ed8\u8ba4\u626b\u63cf ",Object(r.b)("inlineCode",{parentName:"p"},"Furion.Application"),"\uff0c",Object(r.b)("inlineCode",{parentName:"p"},"Furion.Web.Core"),"\uff0c",Object(r.b)("inlineCode",{parentName:"p"},"Furion.Web.Entry")," \u4e09\u4e2a\u7a0b\u5e8f\u96c6",Object(r.b)("inlineCode",{parentName:"p"},".xml")," \u6ce8\u91ca\u6587\u4ef6\uff0c",Object(r.b)("strong",{parentName:"p"},"\u652f\u6301\u81ea\u5b9a\u4e49\u914d\u7f6e"),"\u3002"),Object(r.b)("p",null,"\u53ea\u652f\u6301 ",Object(r.b)("inlineCode",{parentName:"p"},"///")," \u6807\u8bc6\u7684\u6ce8\u91ca\u8bed\u6cd5\uff0c\u5982\uff1a",Object(r.b)("strong",{parentName:"p"},"\u7c7b\u3001\u65b9\u6cd5\u3001\u5c5e\u6027\u3001\u53c2\u6570\u3001\u8fd4\u56de\u503c\u3001\u9a8c\u8bc1\u7279\u6027"),"\u3002"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{5-7,10-13,19-23}","{5-7,10-13,19-23}":!0}),'using Furion.DynamicApiController;\n\nnamespace Furion.Application\n{\n    /// <summary>\n    /// \u7c7b\u6ce8\u91ca\n    /// </summary>\n    public class FurAppService : IDynamicApiController\n    {\n        /// <summary>\n        /// \u65b9\u6cd5\u6ce8\u91ca\n        /// </summary>\n        /// <returns></returns>\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        /// <summary>\n        /// \u5e26 ID \u53c2\u6570\u7684\u65b9\u6cd5\u6ce8\u91ca\n        /// </summary>\n        /// <param name="id"></param>\n        /// <returns></returns>\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger2.png")}),Object(r.b)("div",{className:"admonition admonition-note alert alert--secondary"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"16",viewBox:"0 0 14 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"})))),"\u5c0f\u63d0\u793a")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},"\u5982\u679c\u6587\u6863\u6ce8\u91ca\u6ca1\u6709\u663e\u793a\uff0c\u8bf7\u68c0\u67e5\u9879\u76ee ",Object(r.b)("inlineCode",{parentName:"p"},"\u5c5e\u6027->\u751f\u6210->\u8f93\u51fa")," \u4e2d XML \u6587\u6863\u662f\u5426\u914d\u7f6e\u8f93\u51fa\u8def\u5f84\u3002"))),Object(r.b)("h3",{id:"655-\u591a\u5206\u7ec4\u652f\u6301"},"6.5.5 \u591a\u5206\u7ec4\u652f\u6301"),Object(r.b)("p",null,"\u591a\u5206\u7ec4\u662f\u4e00\u4e2a\u7cfb\u7edf\u4e2d\u5fc5\u5907\u529f\u80fd\uff0c\u6211\u4eec\u53ef\u4ee5\u5c06\u7cfb\u7edf\u5212\u5206\u4e3a\u591a\u4e2a\u6a21\u5757\uff0c\u6bcf\u4e2a\u6a21\u5757\u90fd\u72ec\u7acb\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"api")," \u914d\u7f6e\u3002\u5728 ",Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u6846\u67b6\u4e2d\uff0c\u5b9e\u73b0\u591a\u5206\u7ec4\u975e\u5e38\u7b80\u5355\u3002\u5982\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{5,21,32}","{5,21,32}":!0}),'using Furion.DynamicApiController;\n\nnamespace Furion.Application\n{\n    [ApiDescriptionSettings("Group1")]\n    public class FurAppService : IDynamicApiController\n    {\n        /// <summary>\n        /// \u968f\u7236\u7c7b Group1 \u5206\u7ec4\n        /// </summary>\n        /// <returns></returns>\n        public string Post()\n        {\n            return nameof(Furion);\n        }\n\n        /// <summary>\n        /// \u5728 Group1\u3001Group3 \u90fd\u6709\u6211\n        /// </summary>\n        /// <returns></returns>\n        [ApiDescriptionSettings("Group1", "Group3")]\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        /// <summary>\n        /// \u6211\u53ea\u5728 Group2 \u51fa\u73b0\n        /// </summary>\n        /// <param name="id"></param>\n        /// <returns></returns>\n        [ApiDescriptionSettings("Group2")]\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger3.gif")}),Object(r.b)("h3",{id:"656-\u591a\u5206\u7ec4\u6392\u5e8f"},"6.5.6 \u591a\u5206\u7ec4\u6392\u5e8f"),Object(r.b)(l.a,{defaultValue:"fz1",values:[{label:"\u65b9\u5f0f\u4e00",value:"fz1"},{label:"\u65b9\u5f0f\u4e8c",value:"fz2"}],mdxType:"Tabs"},Object(r.b)(b.a,{value:"fz1",mdxType:"TabItem"},Object(r.b)("p",null,Object(r.b)("strong",{parentName:"p"},"\u901a\u8fc7\u5206\u7ec4\u540d\u79f0\u6dfb\u52a0 ",Object(r.b)("inlineCode",{parentName:"strong"},"@\u6574\u6570")," \u8fdb\u884c\u6392\u5e8f")),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{5,19}","{5,19}":!0}),'using Furion.DynamicApiController;\n\nnamespace Furion.Application\n{\n    [ApiDescriptionSettings("Group1@1")]\n    public class FurAppService : IDynamicApiController\n    {\n        public string Post()\n        {\n            return nameof(Furion);\n        }\n\n        [ApiDescriptionSettings("Group1", "Group3")]\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        [ApiDescriptionSettings("Group@2")]\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n}\n')),Object(r.b)("p",null,"\u53ef\u4ee5\u901a\u8fc7\u5728\u5206\u7ec4\u540d\u540e\u9762\u6dfb\u52a0 ",Object(r.b)("inlineCode",{parentName:"p"},"@\u6574\u6570")," \u8fdb\u884c\u6392\u5e8f\uff0c",Object(r.b)("inlineCode",{parentName:"p"},"\u6574\u6570")," \u8d8a\u5927\u6392\u524d\u9762\u3002\u5982\u679c\u5206\u7ec4\u540d\u79f0\u591a\u6b21\u6307\u5b9a\u4e14\u591a\u6b21\u6307\u5b9a\u4e86 ",Object(r.b)("inlineCode",{parentName:"p"},"@\u6574\u6570")," \uff0c\u5219\u81ea\u52a8",Object(r.b)("strong",{parentName:"p"},"\u53d6\u8be5\u5206\u7ec4\u6700\u5927\u7684\u6574\u6570"),"\u8fdb\u884c\u6392\u5e8f\u3002")),Object(r.b)(b.a,{value:"fz2",mdxType:"TabItem"},Object(r.b)("p",null,Object(r.b)("strong",{parentName:"p"},"\u901a\u8fc7\u914d\u7f6e\u6587\u4ef6\u914d\u7f6e\u6392\u5e8f")),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-json",metastring:'{2-17} title="Furion.Web.Entry/appsettings.json"',"{2-17}":!0,title:'"Furion.Web.Entry/appsettings.json"'}),'{\n  "SpecificationDocumentSettings": {\n    "GroupOpenApiInfos": [\n      {\n        "Group": "Group1",\n        "Order": 1\n      },\n      {\n        "Group": "Group2",\n        "Order": 2\n      },\n      {\n        "Group": "Group3",\n        "Order": 0\n      }\n    ]\n  }\n}\n')))),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger5.png")}),Object(r.b)("div",{className:"admonition admonition-tip alert alert--success"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"})))),"\u6392\u5e8f\u8bf4\u660e")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},"\u5206\u7ec4\u9ed8\u8ba4\u6392\u5e8f ",Object(r.b)("inlineCode",{parentName:"p"},"Order")," \u4e3a ",Object(r.b)("inlineCode",{parentName:"p"},"0"),"\u3002\u5982\u679c\u540c\u65f6\u914d\u7f6e\u4e86 ",Object(r.b)("inlineCode",{parentName:"p"},"@\u6574\u6570")," \u548c ",Object(r.b)("inlineCode",{parentName:"p"},"appsettings.json")," \u914d\u7f6e\u6587\u4ef6\uff0c\u90a3\u4e48\u4f18\u5148\u91c7\u7528 ",Object(r.b)("inlineCode",{parentName:"p"},"appsettings.json")," \u4e2d\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"Order")))),Object(r.b)("h3",{id:"657-\u591a\u5206\u7ec4\u4fe1\u606f\u914d\u7f6e"},"6.5.7 \u591a\u5206\u7ec4\u4fe1\u606f\u914d\u7f6e"),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u6846\u67b6\u63d0\u4f9b\u4e86\u53ef\u901a\u8fc7 ",Object(r.b)("inlineCode",{parentName:"p"},"appsetting.json")," \u914d\u7f6e\u5206\u7ec4\u4fe1\u606f\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-json",metastring:'{3-20} title="Furion.Web.Entry/appsettings.json"',"{3-20}":!0,title:'"Furion.Web.Entry/appsettings.json"'}),'{\n  "SpecificationDocumentSettings": {\n    "GroupOpenApiInfos": [\n      {\n        "Group": "Group1",\n        "Title": "\u5206\u7ec4\u6807\u9898",\n        "Description": "\u8fd9\u91cc\u662f\u5206\u7ec4\u63cf\u8ff0",\n        "Version": "\u7248\u672c\u53f7",\n        "TermsOfService": "https://furion.pro",\n        "Contact": {\n          "Name": "\u767e\u5c0f\u50e7",\n          "Url": "https://gitee.com/monksoul",\n          "Email": "monksoul@outlook.com"\n        },\n        "License": {\n          "Name": "Apache-2.0",\n          "Url": "https://gitee.com/monksoul/Furion/blob/alpha/LICENSE"\n        }\n      }\n    ]\n  }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger5.png")}),Object(r.b)("h3",{id:"658-\u7ec4\u4e2d\u7ec4\uff08\u6807\u7b7e\uff09"},"6.5.8 \u7ec4\u4e2d\u7ec4\uff08\u6807\u7b7e\uff09"),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"Tag")," \u914d\u7f6e\u4e3b\u8981\u7528\u4e8e\u914d\u7f6e ",Object(r.b)("inlineCode",{parentName:"p"},"Swagger")," \u6807\u7b7e\u5206\u7ec4\u4fe1\u606f\u53ca\u5408\u5e76\u6807\u7b7e\u3002\u4e5f\u5c31\u662f ",Object(r.b)("inlineCode",{parentName:"p"},"\u7ec4\u4e2d\u7ec4"),":"),Object(r.b)(l.a,{defaultValue:"tag1",values:[{label:"\u6807\u7b7e\u547d\u540d",value:"tag1"},{label:"\u5408\u5e76\u6807\u7b7e",value:"tag2"}],mdxType:"Tabs"},Object(r.b)(b.a,{value:"tag1",mdxType:"TabItem"},Object(r.b)("h4",{id:"\u672a\u8d34\u6807\u7b7e\u4e4b\u524d"},"\u672a\u8d34\u6807\u7b7e\u4e4b\u524d"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs"}),"using Furion.DynamicApiController;\n\nnamespace Furion.Application\n{\n    public class FurAppService : IDynamicApiController\n    {\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n\n    public class TestAppService : IDynamicApiController\n    {\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n}\n")),Object(r.b)("h4",{id:"\u8d34\u6807\u7b7e\u4e4b\u540e"},"\u8d34\u6807\u7b7e\u4e4b\u540e"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{5,19}","{5,19}":!0}),'using Furion.DynamicApiController;\n\nnamespace Furion.Application\n{\n    [ApiDescriptionSettings(Tag = "\u5206\u7ec4\u4e00")]\n    public class FurAppService : IDynamicApiController\n    {\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n\n    [ApiDescriptionSettings(Tag = "\u5206\u7ec4\u4e8c")]\n    public class TestAppService : IDynamicApiController\n    {\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/tag1.png")})),Object(r.b)(b.a,{value:"tag2",mdxType:"TabItem"},Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{5,19}","{5,19}":!0}),'using Furion.DynamicApiController;\n\nnamespace Furion.Application\n{\n    [ApiDescriptionSettings(Tag = "\u5408\u5e76\u6240\u6709\u6807\u7b7e")]\n    public class FurAppService : IDynamicApiController\n    {\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n\n    [ApiDescriptionSettings(Tag = "\u5408\u5e76\u6240\u6709\u6807\u7b7e")]\n    public class TestAppService : IDynamicApiController\n    {\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n\n        public int Get(int id)\n        {\n            return id;\n        }\n    }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/tag2.png")}))),Object(r.b)("div",{className:"admonition admonition-tip alert alert--success"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"})))),"\u5c0f\u77e5\u8bc6")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},"\u5982\u679c ",Object(r.b)("inlineCode",{parentName:"p"},"Tag")," \u540d\u5b57\u4e00\u6837\uff0c\u5219\u4f1a\u81ea\u52a8\u5408\u5e76\uff0c\u5426\u5219\u53ea\u662f\u547d\u540d\u3002"))),Object(r.b)("h3",{id:"659-\u9ed8\u8ba4\u5c55\u5f00\u6240\u6709\u6587\u6863"},"6.5.9 \u9ed8\u8ba4\u5c55\u5f00\u6240\u6709\u6587\u6863"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-json",metastring:'{2-4} title="Furion.Web.Entry/appsettings.json"',"{2-4}":!0,title:'"Furion.Web.Entry/appsettings.json"'}),'{\n  "SpecificationDocumentSettings": {\n    "DocExpansionState": "Full"\n  }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger6.gif")}),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"DocExpansionState")," \u914d\u7f6e\u8bf4\u660e\uff1a"),Object(r.b)("ul",null,Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"List"),"\uff1a\u5217\u8868\u5f0f\uff08\u5c55\u5f00\u5b50\u7c7b\uff09\uff0c",Object(r.b)("strong",{parentName:"li"},"\u9ed8\u8ba4\u503c")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"Full"),"\uff1a\u5b8c\u5168\u5c55\u5f00"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"None"),"\uff1a\u5217\u8868\u5f0f\uff08\u4e0d\u5c55\u5f00\u5b50\u7c7b\uff09")),Object(r.b)("h3",{id:"6510-\u914d\u7f6e\u6587\u6863\u6807\u9898"},"6.5.10 \u914d\u7f6e\u6587\u6863\u6807\u9898"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-json",metastring:'{2-4} title="Furion.Web.Entry/appsettings.json"',"{2-4}":!0,title:'"Furion.Web.Entry/appsettings.json"'}),'{\n  "SpecificationDocumentSettings": {\n    "DocumentTitle": "\u6211\u662f\u81ea\u5b9a\u4e49\u6807\u9898"\n  }\n}\n')),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger7.png")}),Object(r.b)("h3",{id:"6511-\u6388\u6743\u63a7\u5236"},"6.5.11 \u6388\u6743\u63a7\u5236"),Object(r.b)("p",null,Object(r.b)("strong",{parentName:"p"},"\u65b0\u7248\u672c ",Object(r.b)("inlineCode",{parentName:"strong"},"Furion")," \u5df2\u7ecf\u542f\u7528\u4e86\u9ed8\u8ba4\u6388\u6743\u4e86\uff0c\u65e0\u9700\u624b\u52a8\u6388\u6743"),"\uff0c\u5982\u9700\u624b\u52a8\u914d\u7f6e\uff0c\u53ef\u624b\u52a8\u6dfb\u52a0\u4ee5\u4e0b\u7c7b\u4f3c\u914d\u7f6e\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-json",metastring:'title="Furion.Web.Entry/appsettings.json"',title:'"Furion.Web.Entry/appsettings.json"'}),'{\n  "SpecificationDocumentSettings": {\n    "EnableAuthorized": true,\n\n    "SecurityDefinitions": [\n      {\n        "Id": "Bearer",\n        "Type": "Http",\n        "Name": "Authorization",\n        "Description": "JWT Authorization header using the Bearer scheme.",\n        "BearerFormat": "JWT",\n        "Scheme": "bearer",\n        "In": "Header",\n\n        "Requirement": {\n          "Scheme": {\n            "Reference": {\n              "Id": "Bearer",\n              "Type": "SecurityScheme"\n            },\n            "Accesses": []\n          }\n        }\n      }\n    ]\n  }\n}\n')),Object(r.b)("h3",{id:"6512-\u5728\u7ebf\u6d4b\u8bd5"},"6.5.12 \u5728\u7ebf\u6d4b\u8bd5"),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/swagger8.gif")}),Object(r.b)("h3",{id:"6513-\u6027\u80fd\u76d1\u89c6-miniprofiler"},"6.5.13 \u6027\u80fd\u76d1\u89c6 ",Object(r.b)("inlineCode",{parentName:"h3"},"MiniProfiler")),Object(r.b)("p",null,"\u89c4\u8303\u5316\u6587\u6863\u9ed8\u8ba4\u96c6\u6210\u4e86 ",Object(r.b)("inlineCode",{parentName:"p"},"MiniProfiler")," \u7b2c\u4e09\u65b9\u6027\u80fd\u7ec4\u4ef6\uff0c\u901a\u8fc7\u8be5\u7ec4\u4ef6\u53ef\u4ee5\u65b9\u4fbf\u67e5\u770b\u8bf7\u6c42\u6027\u80fd\u3001\u5f02\u5e38\u5806\u6808\u3001\u6570\u636e\u5e93\u64cd\u4f5c\u7b49\u4fe1\u606f\u3002\u9ed8\u8ba4\u5728 ",Object(r.b)("inlineCode",{parentName:"p"},"Swagger")," \u9996\u9875\u5de6\u4e0a\u89d2\u663e\u793a\u3002"),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/mipr.png")}),Object(r.b)("div",{className:"admonition admonition-note alert alert--secondary"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"16",viewBox:"0 0 14 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"})))),"\u5c0f\u63d0\u793a")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},"\u4e5f\u53ef\u4ee5\u901a\u8fc7 ",Object(r.b)("strong",{parentName:"p"},Object(r.b)("inlineCode",{parentName:"strong"},"appsetting.json"))," \u4e2d ",Object(r.b)("strong",{parentName:"p"},Object(r.b)("inlineCode",{parentName:"strong"},"AppSettings:InjectMiniProfiler"))," \u8bbe\u4e3a ",Object(r.b)("strong",{parentName:"p"},Object(r.b)("inlineCode",{parentName:"strong"},"false"))," \u5173\u95ed\u3002"))),Object(r.b)("h3",{id:"6514-\u5b9a\u4e49\u63a5\u53e3\u8f93\u51fa\u7c7b\u578b"},"6.5.14 \u5b9a\u4e49\u63a5\u53e3\u8f93\u51fa\u7c7b\u578b"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{2,8-9}","{2,8-9}":!0}),"using Furion.DynamicApiController;\nusing Microsoft.AspNetCore.Mvc;\n\nnamespace Furion.Application\n{\n    public class FurAppService : IDynamicApiController\n    {\n        [ProducesResponseType(201, Type = typeof(TestDto))]\n        [ProducesResponseType(400)]\n        public string Get()\n        {\n            return nameof(Furion);\n        }\n    }\n}\n")),Object(r.b)("p",null,"\u5982\u4e0b\u56fe\u6240\u793a\uff1a"),Object(r.b)("img",{src:Object(c.a)("img/fhzlx.png")}),Object(r.b)("h3",{id:"6515-\u9690\u85cf\u7279\u5b9a\u5206\u7ec4"},"6.5.15 \u9690\u85cf\u7279\u5b9a\u5206\u7ec4"),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u65b0\u7248\u672c\u63d0\u4f9b\u4e86\u9690\u85cf\u5206\u7ec4\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"Visible")," \u914d\u7f6e\uff0c\u8bbe\u7f6e\u4e3a ",Object(r.b)("inlineCode",{parentName:"p"},"false")," \u4e4b\u540e\u8be5\u5206\u7ec4\u5c06\u4e0d\u663e\u793a\u5728\u89c4\u8303\u5316\u6587\u6863\u4e2d\uff0c\u5982\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-json",metastring:'title="appsetting.json"',title:'"appsetting.json"'}),'{\n  "SpecificationDocumentSettings": {\n    "GroupOpenApiInfos": [\n      {\n        "Group": "Group1",\n        "Visible": false\n      }\n    ]\n  }\n}\n')),Object(r.b)("h2",{id:"66-specificationdocumentsettings-\u914d\u7f6e"},"6.6 ",Object(r.b)("inlineCode",{parentName:"h2"},"SpecificationDocumentSettings")," \u914d\u7f6e"),Object(r.b)("p",null,"\u9664\u4e86\u4e0a\u8ff0\u4f8b\u5b50\u5916\uff0c",Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u63d0\u4f9b\u4e86\u4e00\u4e9b\u914d\u7f6e\u9009\u9879\uff0c\u5982\uff1a"),Object(r.b)("ul",null,Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"DocumentTitle"),"\uff1a\u6587\u6863\u6807\u9898\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"string"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"Specification Api Document")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"DefaultGroupName"),"\uff1a\u9ed8\u8ba4\u5206\u7ec4\u540d\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"string"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"Default")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"EnableAuthorized"),"\uff1a\u662f\u5426\u542f\u7528\u6743\u9650\u63a7\u5236\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"bool"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"true")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"FormatAsV2"),"\uff1a\u91c7\u7528 ",Object(r.b)("inlineCode",{parentName:"li"},"Swagger 2.0")," \u7248\u672c\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"bool"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"false")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"RoutePrefix"),"\uff1a\u89c4\u8303\u5316\u6587\u6863\u5730\u5740\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"string"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"api"),"\uff0c",Object(r.b)("strong",{parentName:"li"},"\u5982\u679c\u5e0c\u671b\u5728\u9996\u9875\uff0c\u6539\u4e3a\u7a7a\u5b57\u7b26\u4e32\u5373\u53ef"),"\u3002"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"DocExpansionState"),"\uff1a\u6587\u6863\u663e\u793a\u65b9\u5f0f\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"DocExpansion"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"List"),"\uff0c\u53d6\u503c\uff1a",Object(r.b)("ul",{parentName:"li"},Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"List"),"\uff1a\u5217\u8868\u5f0f\uff08\u5c55\u5f00\u5b50\u7c7b\uff09\uff0c",Object(r.b)("strong",{parentName:"li"},"\u9ed8\u8ba4\u503c")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"Full"),"\uff1a\u5b8c\u5168\u5c55\u5f00"),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"None"),"\uff1a\u5217\u8868\u5f0f\uff08\u4e0d\u5c55\u5f00\u5b50\u7c7b\uff09"))),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"XmlComments"),"\uff1a\u7a0b\u5e8f\u96c6\u6ce8\u91ca\u63cf\u8ff0\u6587\u4ef6\u540d\uff08\u53ef\u5e26 ",Object(r.b)("inlineCode",{parentName:"li"},".xml"),"\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"string"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"Furion.Application, Furion.Web.Entry, Furion.Web.Core")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"GroupOpenApiInfos"),"\uff1a\u5206\u7ec4\u4fe1\u606f\u914d\u7f6e\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"SpecificationOpenApiInfo[]"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"{ 'Group': 'Default'}")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"SecurityDefinitions"),"\uff1a\u5b89\u5168\u7b56\u7565\u5b9a\u4e49\u914d\u7f6e\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"SpecificationOpenApiSecurityScheme[]"),"\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"[]")),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"Servers"),"\uff1a\u914d\u7f6e Server \u4e0b\u62c9\u5217\u8868\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"OpenApiServer[]")," \u7c7b\u578b\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"[]"),"\uff0c\u5982\uff1a",Object(r.b)("inlineCode",{parentName:"li"},'{Servers:[ { Url:"\u5730\u5740", Description:"\u63cf\u8ff0"} ]}')),Object(r.b)("li",{parentName:"ul"},Object(r.b)("inlineCode",{parentName:"li"},"HideServers"),"\uff1a\u662f\u5426\u9690\u85cf Server \u4e0b\u62c9\u5217\u8868\uff0c",Object(r.b)("inlineCode",{parentName:"li"},"bool")," \u7c7b\u578b\uff0c\u9ed8\u8ba4 ",Object(r.b)("inlineCode",{parentName:"li"},"false"))),Object(r.b)("h2",{id:"67-\u7edf\u4e00\u8fd4\u56de\u503c\u6a21\u578b"},"6.7 \u7edf\u4e00\u8fd4\u56de\u503c\u6a21\u578b"),Object(r.b)("p",null,Object(r.b)("inlineCode",{parentName:"p"},"Furion")," \u6846\u67b6\u63d0\u4f9b ",Object(r.b)("inlineCode",{parentName:"p"},"\u89c4\u8303\u5316\u7ed3\u679c")," \u529f\u80fd\uff0c\u53ef\u4ee5\u901a\u8fc7\u5b9e\u73b0 ",Object(r.b)("inlineCode",{parentName:"p"},"IUnifyResultProvider")," \u63d0\u4f9b\u5668\u5b9e\u73b0\u7edf\u4e00\u89c4\u8303\u5316\u8fd4\u56de\u503c\u5b9a\u5236\uff0c\u5982\uff1a",Object(r.b)("inlineCode",{parentName:"p"},"RESTfulResultProvider"),"\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs",metastring:"{16,17}","{16,17}":!0}),'using Furion.DependencyInjection;\nusing Furion.Utilities;\nusing Microsoft.AspNetCore.Http;\nusing Microsoft.AspNetCore.Mvc;\nusing Microsoft.AspNetCore.Mvc.Filters;\nusing Microsoft.AspNetCore.Mvc.ModelBinding;\nusing System;\nusing System.Collections.Generic;\nusing System.Threading.Tasks;\n\nnamespace Furion.UnifyResult\n{\n    /// <summary>\n    /// RESTful \u98ce\u683c\u8fd4\u56de\u503c\n    /// </summary>\n    [SkipScan, UnifyModel(typeof(RESTfulResult<>))]\n    public class RESTfulResultProvider : IUnifyResultProvider\n    {\n        /// <summary>\n        /// \u5f02\u5e38\u8fd4\u56de\u503c\n        /// </summary>\n        /// <param name="context"></param>\n        /// <returns></returns>\n        public IActionResult OnException(ExceptionContext context)\n        {\n            // \u89e3\u6790\u5f02\u5e38\u4fe1\u606f\n            var (ErrorCode, ErrorContent) = UnifyContext.GetExceptionMetadata(context);\n\n            return new JsonResult(new RESTfulResult<object>\n            {\n                StatusCode = ErrorCode,\n                Succeeded = false,\n                Data = null,\n                Errors = ErrorContent,\n                Extras = UnifyContext.Take(),\n                Timestamp = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()\n            });\n        }\n\n        /// <summary>\n        /// \u6210\u529f\u8fd4\u56de\u503c\n        /// </summary>\n        /// <param name="context"></param>\n        /// <returns></returns>\n        public IActionResult OnSucceeded(ActionExecutedContext context)\n        {\n            object data;\n            // \u5904\u7406\u5185\u5bb9\u7ed3\u679c\n            if (context.Result is ContentResult contentResult) data = contentResult.Content;\n            // \u5904\u7406\u5bf9\u8c61\u7ed3\u679c\n            else if (context.Result is ObjectResult objectResult) data = objectResult.Value;\n            else if (context.Result is EmptyResult) data = null;\n            else return null;\n\n            return new JsonResult(new RESTfulResult<object>\n            {\n                StatusCode = context.Result is EmptyResult ? StatusCodes.Status204NoContent : StatusCodes.Status200OK,  // \u5904\u7406\u6ca1\u6709\u8fd4\u56de\u503c\u60c5\u51b5 204\n                Succeeded = true,\n                Data = data,\n                Errors = null,\n                Extras = UnifyContext.Take(),\n                Timestamp = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()\n            });\n        }\n\n        /// <summary>\n        /// \u9a8c\u8bc1\u5931\u8d25\u8fd4\u56de\u503c\n        /// </summary>\n        /// <param name="context"></param>\n        /// <param name="modelStates"></param>\n        /// <param name="validationResults"></param>\n        /// <param name="validateFailedMessage"></param>\n        /// <returns></returns>\n        public IActionResult OnValidateFailed(ActionExecutingContext context, ModelStateDictionary modelStates, Dictionary<string, IEnumerable<string>> validationResults, string validateFailedMessage)\n        {\n            return new JsonResult(new RESTfulResult<object>\n            {\n                StatusCode = StatusCodes.Status400BadRequest,\n                Succeeded = false,\n                Data = null,\n                Errors = validationResults,\n                Extras = UnifyContext.Take(),\n                Timestamp = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()\n            });\n        }\n\n        /// <summary>\n        /// \u5904\u7406\u8f93\u51fa\u72b6\u6001\u7801\n        /// </summary>\n        /// <param name="context"></param>\n        /// <param name="statusCode"></param>\n        /// <returns></returns>\n        public async Task OnResponseStatusCodes(HttpContext context, int statusCode)\n        {\n            switch (statusCode)\n            {\n                // \u5904\u7406 401 \u72b6\u6001\u7801\n                case StatusCodes.Status401Unauthorized:\n                    await context.Response.WriteAsJsonAsync(new RESTfulResult<object>\n                    {\n                        StatusCode = StatusCodes.Status401Unauthorized,\n                        Succeeded = false,\n                        Data = null,\n                        Errors = "401 Unauthorized",\n                        Extras = UnifyContext.Take(),\n                        Timestamp = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()\n                    }, JsonSerializerUtility.GetDefaultJsonSerializerOptions());\n                    break;\n                // \u5904\u7406 403 \u72b6\u6001\u7801\n                case StatusCodes.Status403Forbidden:\n                    await context.Response.WriteAsJsonAsync(new RESTfulResult<object>\n                    {\n                        StatusCode = StatusCodes.Status403Forbidden,\n                        Succeeded = false,\n                        Data = null,\n                        Errors = "403 Forbidden",\n                        Extras = UnifyContext.Take(),\n                        Timestamp = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()\n                    }, JsonSerializerUtility.GetDefaultJsonSerializerOptions());\n                    break;\n\n                default:\n                    break;\n            }\n        }\n    }\n}\n')),Object(r.b)("p",null,"\u4e4b\u540e\u5728 ",Object(r.b)("inlineCode",{parentName:"p"},"Startup.cs")," \u4e2d\u6ce8\u518c\u5373\u53ef\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs"}),"services.AddControllers()\n        .AddInjectWithUnifyResult<RESTfulResultProvider>();\n")),Object(r.b)("div",{className:"admonition admonition-important alert alert--info"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"16",viewBox:"0 0 14 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"})))),"\u7279\u522b\u6ce8\u610f")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},"\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u89c4\u8303\u5316\u7ed3\u679c\u4e0d\u4f1a\u5bf9 ",Object(r.b)("inlineCode",{parentName:"p"},"401")," \u548c ",Object(r.b)("inlineCode",{parentName:"p"},"403")," \u72b6\u6001\u7801\u8fdb\u884c\u89c4\u8303\u5316\u5904\u7406\uff0c\u5982\u9700\u542f\u52a8\u8be5\u72b6\u6001\u7801\u5904\u7406\uff0c\u53ea\u9700\u5728 ",Object(r.b)("inlineCode",{parentName:"p"},"Startup.cs")," \u4e2d\u7684 ",Object(r.b)("inlineCode",{parentName:"p"},"Configure")," \u4e2d\u542f\u7528\u63a5\u53e3\uff1a"),Object(r.b)("pre",{parentName:"div"},Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs"}),"public void Configure(IApplicationBuilder app, IWebHostEnvironment env)\n{\n    if (env.IsDevelopment())\n    {\n        app.UseDeveloperExceptionPage();\n    }\n    // \u6dfb\u52a0\u89c4\u8303\u5316\u7ed3\u679c\u72b6\u6001\u7801\uff0c\u9700\u8981\u5728\u8fd9\u91cc\u6ce8\u518c\n    app.UseUnifyResultStatusCodes();\n    // \u5176\u4ed6\u6ce8\u518c...\n}\n")))),Object(r.b)("h3",{id:"671-\u6392\u9664\u89c4\u8303\u5316\u5904\u7406"},"6.7.1 \u6392\u9664\u89c4\u8303\u5316\u5904\u7406"),Object(r.b)("p",null,"\u6709\u4e9b\u65f6\u5019\uff0c\u6211\u4eec\u67d0\u4e9b\u63a5\u53e3\u4e0d\u9700\u8981\u8fdb\u884c\u89c4\u8303\u5316\u5904\u7406\uff0c\u8fd9\u65f6\uff0c\u6211\u4eec\u53ea\u9700\u8981\u5e16 ",Object(r.b)("inlineCode",{parentName:"p"},"[NonUnify]")," \u7279\u6027\u5373\u53ef\u3002"),Object(r.b)("h3",{id:"672-\u89c4\u8303\u5316\u7ed3\u679c\u6dfb\u52a0\u989d\u5916\u6570\u636e"},"6.7.2 \u89c4\u8303\u5316\u7ed3\u679c\u6dfb\u52a0\u989d\u5916\u6570\u636e"),Object(r.b)("p",null,"\u9ed8\u8ba4\u7684\u89c4\u8303\u5316\u7ed3\u679c\u4e2d\u5305\u542b ",Object(r.b)("inlineCode",{parentName:"p"},"extras")," \u5c5e\u6027\uff0c\u53ef\u4ee5\u914d\u7f6e\u989d\u5916\u6570\u636e\u8fd4\u56de\u5230\u5ba2\u6237\u7aef\uff1a"),Object(r.b)("pre",null,Object(r.b)("code",Object(a.a)({parentName:"pre"},{className:"language-cs"}),'UnifyContext.Fill(new { Message = "\u64cd\u4f5c\u6210\u529f" });\n')),Object(r.b)("h2",{id:"68-\u53cd\u9988\u4e0e\u5efa\u8bae"},"6.8 \u53cd\u9988\u4e0e\u5efa\u8bae"),Object(r.b)("div",{className:"admonition admonition-note alert alert--secondary"},Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-heading"}),Object(r.b)("h5",{parentName:"div"},Object(r.b)("span",Object(a.a)({parentName:"h5"},{className:"admonition-icon"}),Object(r.b)("svg",Object(a.a)({parentName:"span"},{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"16",viewBox:"0 0 14 16"}),Object(r.b)("path",Object(a.a)({parentName:"svg"},{fillRule:"evenodd",d:"M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"})))),"\u4e0e\u6211\u4eec\u4ea4\u6d41")),Object(r.b)("div",Object(a.a)({parentName:"div"},{className:"admonition-content"}),Object(r.b)("p",{parentName:"div"},"\u7ed9 Furion \u63d0 ",Object(r.b)("a",Object(a.a)({parentName:"p"},{href:"https://gitee.com/monksoul/Furion/issues/new?issue"}),"Issue"),"\u3002"))))}m.isMDXComponent=!0},185:function(e,n,t){"use strict";t.d(n,"a",(function(){return s})),t.d(n,"b",(function(){return d}));var a=t(0),i=t.n(a);function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function c(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);n&&(a=a.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,a)}return t}function l(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?c(Object(t),!0).forEach((function(n){r(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):c(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function b(e,n){if(null==e)return{};var t,a,i=function(e,n){if(null==e)return{};var t,a,i={},r=Object.keys(e);for(a=0;a<r.length;a++)t=r[a],n.indexOf(t)>=0||(i[t]=e[t]);return i}(e,n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)t=r[a],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(i[t]=e[t])}return i}var o=i.a.createContext({}),p=function(e){var n=i.a.useContext(o),t=n;return e&&(t="function"==typeof e?e(n):l(l({},n),e)),t},s=function(e){var n=p(e.components);return i.a.createElement(o.Provider,{value:n},e.children)},u={inlineCode:"code",wrapper:function(e){var n=e.children;return i.a.createElement(i.a.Fragment,{},n)}},m=i.a.forwardRef((function(e,n){var t=e.components,a=e.mdxType,r=e.originalType,c=e.parentName,o=b(e,["components","mdxType","originalType","parentName"]),s=p(t),m=a,d=s["".concat(c,".").concat(m)]||s[m]||u[m]||r;return t?i.a.createElement(d,l(l({ref:n},o),{},{components:t})):i.a.createElement(d,l({ref:n},o))}));function d(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var r=t.length,c=new Array(r);c[0]=m;var l={};for(var b in n)hasOwnProperty.call(n,b)&&(l[b]=n[b]);l.originalType=e,l.mdxType="string"==typeof e?e:a,c[1]=l;for(var o=2;o<r;o++)c[o]=t[o];return i.a.createElement.apply(null,c)}return i.a.createElement.apply(null,t)}m.displayName="MDXCreateElement"},186:function(e,n,t){"use strict";t.d(n,"b",(function(){return r})),t.d(n,"a",(function(){return c}));var a=t(21),i=t(187);function r(){const{siteConfig:{baseUrl:e="/",url:n}={}}=Object(a.default)();return{withBaseUrl:(t,a)=>function(e,n,t,{forcePrependBaseUrl:a=!1,absolute:r=!1}={}){if(!t)return t;if(t.startsWith("#"))return t;if(Object(i.b)(t))return t;if(a)return n+t;const c=t.startsWith(n)?t:n+t.replace(/^\//,"");return r?e+c:c}(n,e,t,a)}}function c(e,n={}){const{withBaseUrl:t}=r();return t(e,n)}},187:function(e,n,t){"use strict";function a(e){return!0===/^(\w*:|\/\/)/.test(e)}function i(e){return void 0!==e&&!a(e)}t.d(n,"b",(function(){return a})),t.d(n,"a",(function(){return i}))},188:function(e,n,t){"use strict";function a(e){var n,t,i="";if("string"==typeof e||"number"==typeof e)i+=e;else if("object"==typeof e)if(Array.isArray(e))for(n=0;n<e.length;n++)e[n]&&(t=a(e[n]))&&(i&&(i+=" "),i+=t);else for(n in e)e[n]&&(i&&(i+=" "),i+=n);return i}n.a=function(){for(var e,n,t=0,i="";t<arguments.length;)(e=arguments[t++])&&(n=a(e))&&(i&&(i+=" "),i+=n);return i}},190:function(e,n,t){"use strict";var a=t(0),i=t(191);n.a=function(){const e=Object(a.useContext)(i.a);if(null==e)throw new Error("`useUserPreferencesContext` is used outside of `Layout` Component.");return e}},191:function(e,n,t){"use strict";var a=t(0);const i=Object(a.createContext)(void 0);n.a=i},193:function(e,n,t){"use strict";var a=t(0),i=t.n(a),r=t(190),c=t(188),l=t(55),b=t.n(l);const o=37,p=39;n.a=function(e){const{lazy:n,block:t,defaultValue:l,values:s,groupId:u,className:m}=e,{tabGroupChoices:d,setTabGroupChoices:O}=Object(r.a)(),[j,g]=Object(a.useState)(l),N=a.Children.toArray(e.children);if(null!=u){const e=d[u];null!=e&&e!==j&&s.some(n=>n.value===e)&&g(e)}const v=e=>{g(e),null!=u&&O(u,e)},f=[];return i.a.createElement("div",null,i.a.createElement("ul",{role:"tablist","aria-orientation":"horizontal",className:Object(c.a)("tabs",{"tabs--block":t},m)},s.map(({value:e,label:n})=>i.a.createElement("li",{role:"tab",tabIndex:0,"aria-selected":j===e,className:Object(c.a)("tabs__item",b.a.tabItem,{"tabs__item--active":j===e}),key:e,ref:e=>f.push(e),onKeyDown:e=>{((e,n,t)=>{switch(t.keyCode){case p:((e,n)=>{const t=e.indexOf(n)+1;e[t]?e[t].focus():e[0].focus()})(e,n);break;case o:((e,n)=>{const t=e.indexOf(n)-1;e[t]?e[t].focus():e[e.length-1].focus()})(e,n)}})(f,e.target,e)},onFocus:()=>v(e),onClick:()=>{v(e)}},n))),n?Object(a.cloneElement)(N.filter(e=>e.props.value===j)[0],{className:"margin-vert--md"}):i.a.createElement("div",{className:"margin-vert--md"},N.map((e,n)=>Object(a.cloneElement)(e,{key:n,hidden:e.props.value!==j}))))}},194:function(e,n,t){"use strict";var a=t(3),i=t(0),r=t.n(i);n.a=function({children:e,hidden:n,className:t}){return r.a.createElement("div",Object(a.a)({role:"tabpanel"},{hidden:n,className:t}),e)}}}]);