import{s as at,o as tt,n as L}from"../chunks/scheduler.6062bdaf.js";import{S as ot,i as nt,g as b,s as l,r as h,A as st,h as f,f as o,c as r,j as P,u as g,x as M,k as U,y,a as s,v as i,d as u,t as p,w as d}from"../chunks/index.4bca734e.js";import{T as Je}from"../chunks/Tip.b9ac1f03.js";import{D as C}from"../chunks/Docstring.81ba5e3c.js";import{C as Za}from"../chunks/CodeBlock.fa01571c.js";import{E as Ha}from"../chunks/ExampleCodeBlock.30e7542f.js";import{H as j,E as lt}from"../chunks/EditOnGithub.74ab2baa.js";function rt(_){let t,c='웹훅 서버를 설정하고 Space로 배포하는 방법은 이 단계별 <a href="../guides/webhooks_server">가이드</a>를 확인하세요.';return{c(){t=b("p"),t.innerHTML=c},l(n){t=f(n,"P",{"data-svelte-h":!0}),M(t)!=="svelte-1982vgu"&&(t.innerHTML=c)},m(n,m){s(n,t,m)},p:L,d(n){n&&o(t)}}}function ht(_){let t,c="이 기능은 실험적인 기능입니다. 본 API는 현재 개선 작업 중이며, 향후 사전 통지 없이 주요 변경 사항이 도입될 수 있음을 의미합니다. <code>requirements</code>에서 <code>huggingface_hub</code>의 버전을 고정하는 것을 권장합니다. 참고로 실험적 기능을 사용하면 경고가 트리거 됩니다. 이 경고 트리거를 비활성화 시키길 원한다면 환경변수 <code>HF_HUB_DISABLE_EXPERIMENTAL_WARNING=1</code>를 설정하세요.";return{c(){t=b("p"),t.innerHTML=c},l(n){t=f(n,"P",{"data-svelte-h":!0}),M(t)!=="svelte-17n5oq0"&&(t.innerHTML=c)},m(n,m){s(n,t,m)},p:L,d(n){n&&o(t)}}}function gt(_){let t,c="<code>WebhooksServer</code> is experimental. Its API is subject to change in the future.";return{c(){t=b("p"),t.innerHTML=c},l(n){t=f(n,"P",{"data-svelte-h":!0}),M(t)!=="svelte-172l28e"&&(t.innerHTML=c)},m(n,m){s(n,t,m)},p:L,d(n){n&&o(t)}}}function it(_){let t,c="You must have <code>gradio</code> installed to use <code>WebhooksServer</code> (<code>pip install --upgrade gradio</code>).";return{c(){t=b("p"),t.innerHTML=c},l(n){t=f(n,"P",{"data-svelte-h":!0}),M(t)!=="svelte-1hd0atb"&&(t.innerHTML=c)},m(n,m){s(n,t,m)},p:L,d(n){n&&o(t)}}}function ut(_){let t,c="Example:",n,m,T;return m=new Za({props:{code:"aW1wb3J0JTIwZ3JhZGlvJTIwYXMlMjBnciUwQWZyb20lMjBodWdnaW5nZmFjZV9odWIlMjBpbXBvcnQlMjBXZWJob29rc1NlcnZlciUyQyUyMFdlYmhvb2tQYXlsb2FkJTBBJTBBd2l0aCUyMGdyLkJsb2NrcygpJTIwYXMlMjB1aSUzQSUwQSUyMCUyMCUyMCUyMC4uLiUwQSUwQWFwcCUyMCUzRCUyMFdlYmhvb2tzU2VydmVyKHVpJTNEdWklMkMlMjB3ZWJob29rX3NlY3JldCUzRCUyMm15X3NlY3JldF9rZXklMjIpJTBBJTBBJTQwYXBwLmFkZF93ZWJob29rKCUyMiUyRnNheV9oZWxsbyUyMiklMEFhc3luYyUyMGRlZiUyMGhlbGxvKHBheWxvYWQlM0ElMjBXZWJob29rUGF5bG9hZCklM0ElMEElMjAlMjAlMjAlMjByZXR1cm4lMjAlN0IlMjJtZXNzYWdlJTIyJTNBJTIwJTIyaGVsbG8lMjIlN0QlMEElMEFhcHAubGF1bmNoKCk=",highlighted:`<span class="hljs-keyword">import</span> gradio <span class="hljs-keyword">as</span> gr
<span class="hljs-keyword">from</span> huggingface_hub <span class="hljs-keyword">import</span> WebhooksServer, WebhookPayload

<span class="hljs-keyword">with</span> gr.Blocks() <span class="hljs-keyword">as</span> ui:
    ...

app = WebhooksServer(ui=ui, webhook_secret=<span class="hljs-string">&quot;my_secret_key&quot;</span>)

<span class="hljs-meta">@app.add_webhook(<span class="hljs-params"><span class="hljs-string">&quot;/say_hello&quot;</span></span>)</span>
<span class="hljs-keyword">async</span> <span class="hljs-keyword">def</span> <span class="hljs-title function_">hello</span>(<span class="hljs-params">payload: WebhookPayload</span>):
    <span class="hljs-keyword">return</span> {<span class="hljs-string">&quot;message&quot;</span>: <span class="hljs-string">&quot;hello&quot;</span>}

app.launch()`,wrap:!1}}),{c(){t=b("p"),t.textContent=c,n=l(),h(m.$$.fragment)},l(v){t=f(v,"P",{"data-svelte-h":!0}),M(t)!=="svelte-11lpom8"&&(t.textContent=c),n=r(v),g(m.$$.fragment,v)},m(v,I){s(v,t,I),s(v,n,I),i(m,v,I),T=!0},p:L,i(v){T||(u(m.$$.fragment,v),T=!0)},o(v){p(m.$$.fragment,v),T=!1},d(v){v&&(o(t),o(n)),d(m,v)}}}function pt(_){let t,c="<code>webhook_endpoint</code> is experimental. Its API is subject to change in the future.";return{c(){t=b("p"),t.innerHTML=c},l(n){t=f(n,"P",{"data-svelte-h":!0}),M(t)!=="svelte-1p6oojg"&&(t.innerHTML=c)},m(n,m){s(n,t,m)},p:L,d(n){n&&o(t)}}}function dt(_){let t,c="You must have <code>gradio</code> installed to use <code>webhook_endpoint</code> (<code>pip install --upgrade gradio</code>).";return{c(){t=b("p"),t.innerHTML=c},l(n){t=f(n,"P",{"data-svelte-h":!0}),M(t)!=="svelte-siz6u1"&&(t.innerHTML=c)},m(n,m){s(n,t,m)},p:L,d(n){n&&o(t)}}}function ct(_){let t,c;return t=new Za({props:{code:"ZnJvbSUyMGh1Z2dpbmdmYWNlX2h1YiUyMGltcG9ydCUyMHdlYmhvb2tfZW5kcG9pbnQlMkMlMjBXZWJob29rUGF5bG9hZCUwQSUwQSU0MHdlYmhvb2tfZW5kcG9pbnQlMEFhc3luYyUyMGRlZiUyMHRyaWdnZXJfdHJhaW5pbmcocGF5bG9hZCUzQSUyMFdlYmhvb2tQYXlsb2FkKSUzQSUwQSUyMCUyMCUyMCUyMGlmJTIwcGF5bG9hZC5yZXBvLnR5cGUlMjAlM0QlM0QlMjAlMjJkYXRhc2V0JTIyJTIwYW5kJTIwcGF5bG9hZC5ldmVudC5hY3Rpb24lMjAlM0QlM0QlMjAlMjJ1cGRhdGUlMjIlM0ElMEElMjAlMjAlMjAlMjAlMjAlMjAlMjAlMjAlMjMlMjBUcmlnZ2VyJTIwYSUyMHRyYWluaW5nJTIwam9iJTIwaWYlMjBhJTIwZGF0YXNldCUyMGlzJTIwdXBkYXRlZCUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMC4uLiUwQSUwQSUyMyUyMFNlcnZlciUyMGlzJTIwYXV0b21hdGljYWxseSUyMHN0YXJ0ZWQlMjBhdCUyMHRoZSUyMGVuZCUyMG9mJTIwdGhlJTIwc2NyaXB0Lg==",highlighted:`<span class="hljs-keyword">from</span> huggingface_hub <span class="hljs-keyword">import</span> webhook_endpoint, WebhookPayload

<span class="hljs-meta">@webhook_endpoint</span>
<span class="hljs-keyword">async</span> <span class="hljs-keyword">def</span> <span class="hljs-title function_">trigger_training</span>(<span class="hljs-params">payload: WebhookPayload</span>):
    <span class="hljs-keyword">if</span> payload.repo.<span class="hljs-built_in">type</span> == <span class="hljs-string">&quot;dataset&quot;</span> <span class="hljs-keyword">and</span> payload.event.action == <span class="hljs-string">&quot;update&quot;</span>:
        <span class="hljs-comment"># Trigger a training job if a dataset is updated</span>
        ...

<span class="hljs-comment"># Server is automatically started at the end of the script.</span>`,wrap:!1}}),{c(){h(t.$$.fragment)},l(n){g(t.$$.fragment,n)},m(n,m){i(t,n,m),c=!0},p:L,i(n){c||(u(t.$$.fragment,n),c=!0)},o(n){p(t.$$.fragment,n),c=!1},d(n){d(t,n)}}}function bt(_){let t,c;return t=new Za({props:{code:"ZnJvbSUyMGh1Z2dpbmdmYWNlX2h1YiUyMGltcG9ydCUyMHdlYmhvb2tfZW5kcG9pbnQlMkMlMjBXZWJob29rUGF5bG9hZCUwQSUwQSU0MHdlYmhvb2tfZW5kcG9pbnQlMEFhc3luYyUyMGRlZiUyMHRyaWdnZXJfdHJhaW5pbmcocGF5bG9hZCUzQSUyMFdlYmhvb2tQYXlsb2FkKSUzQSUwQSUyMCUyMCUyMCUyMGlmJTIwcGF5bG9hZC5yZXBvLnR5cGUlMjAlM0QlM0QlMjAlMjJkYXRhc2V0JTIyJTIwYW5kJTIwcGF5bG9hZC5ldmVudC5hY3Rpb24lMjAlM0QlM0QlMjAlMjJ1cGRhdGUlMjIlM0ElMEElMjAlMjAlMjAlMjAlMjAlMjAlMjAlMjAlMjMlMjBUcmlnZ2VyJTIwYSUyMHRyYWluaW5nJTIwam9iJTIwaWYlMjBhJTIwZGF0YXNldCUyMGlzJTIwdXBkYXRlZCUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMC4uLiUwQSUwQSUyMyUyMFN0YXJ0JTIwdGhlJTIwc2VydmVyJTIwbWFudWFsbHklMEF0cmlnZ2VyX3RyYWluaW5nLmxhdW5jaCgp",highlighted:`<span class="hljs-keyword">from</span> huggingface_hub <span class="hljs-keyword">import</span> webhook_endpoint, WebhookPayload

<span class="hljs-meta">@webhook_endpoint</span>
<span class="hljs-keyword">async</span> <span class="hljs-keyword">def</span> <span class="hljs-title function_">trigger_training</span>(<span class="hljs-params">payload: WebhookPayload</span>):
    <span class="hljs-keyword">if</span> payload.repo.<span class="hljs-built_in">type</span> == <span class="hljs-string">&quot;dataset&quot;</span> <span class="hljs-keyword">and</span> payload.event.action == <span class="hljs-string">&quot;update&quot;</span>:
        <span class="hljs-comment"># Trigger a training job if a dataset is updated</span>
        ...

<span class="hljs-comment"># Start the server manually</span>
trigger_training.launch()`,wrap:!1}}),{c(){h(t.$$.fragment)},l(n){g(t.$$.fragment,n)},m(n,m){i(t,n,m),c=!0},p:L,i(n){c||(u(t.$$.fragment,n),c=!0)},o(n){p(t.$$.fragment,n),c=!1},d(n){d(t,n)}}}function ft(_){let t,c,n,m,T,v,I,Ya=`웹훅은 MLOps 관련 기능의 기반이 됩니다. 이를 통해 특정 저장소의 새로운 변경 사항을 수신하거나, 관심 있는 특정 사용자/조직에 속한 모든 저장소의 변경 사항을 받아볼 수 있습니다.
Huggingface Hub의 웹훅에 대해 더 자세히 알아보려면 이 <a href="https://huggingface.co/docs/hub/webhooks" rel="nofollow">가이드</a>를 읽어보세요.`,Ne,G,Be,S,De,R,Fe,Q,Aa='여기서 서버는 하나의 <a href="https://gradio.app/" rel="nofollow">Gradio</a> 앱을 의미합니다. Gradio에는 사용자 또는 사용자에게 지침을 표시하는 UI와 웹훅을 수신하기 위한 API가 있습니다. 웹훅 엔드포인트를 구현하는 것은 함수에 데코레이터를 추가하는 것만큼 간단합니다. 서버를 Space에 배포하기 전에 Gradio 터널을 사용하여 웹훅을 머신으로 리디렉션하여 디버깅할 수 있습니다.',Xe,N,Ve,w,B,wa,Ue,Ra=`The <a href="/docs/huggingface_hub/main/ko/package_reference/webhooks_server#huggingface_hub.WebhooksServer">WebhooksServer()</a> class lets you create an instance of a Gradio app that can receive Huggingface webhooks.
These webhooks can be registered using the <code>add_webhook()</code> decorator. Webhook endpoints are added to
the app as a POST endpoint to the FastAPI router. Once all the webhooks are registered, the <code>launch</code> method has to be
called to start the app.`,Ma,je,Qa=`It is recommended to accept <a href="/docs/huggingface_hub/main/ko/package_reference/webhooks_server#huggingface_hub.WebhookPayload">WebhookPayload</a> as the first argument of the webhook function. It is a Pydantic
model that contains all the information about the webhook event. The data will be parsed automatically for you.`,Wa,Te,Na=`Check out the <a href="../guides/webhooks_server">webhooks guide</a> for a step-by-step tutorial on how to setup your
WebhooksServer and deploy it on a Space.`,Pa,J,Ua,x,ja,E,Oe,D,qe,$,F,Ta,Ce,Ba='Decorator to start a <a href="/docs/huggingface_hub/main/ko/package_reference/webhooks_server#huggingface_hub.WebhooksServer">WebhooksServer()</a> and register the decorated function as a webhook endpoint.',Ca,Ie,Da=`This is a helper to get started quickly. If you need more flexibility (custom landing page or webhook secret),
you can use <a href="/docs/huggingface_hub/main/ko/package_reference/webhooks_server#huggingface_hub.WebhooksServer">WebhooksServer()</a> directly. You can register multiple webhook endpoints (to the same server) by using
this decorator multiple times.`,Ia,Le,Fa=`Check out the <a href="../guides/webhooks_server">webhooks guide</a> for a step-by-step tutorial on how to setup your
server and deploy it on a Space.`,La,H,Ga,Z,Sa,Ge,Xa=`Examples:
The default usage is to register a function as a webhook endpoint. The function name will be used as the path.
The server will be started automatically at exit (i.e. at the end of the script).`,Ja,Y,xa,Se,Va=`Advanced usage: register a function as a webhook endpoint and start the server manually. This is useful if you
are running it in a notebook.`,Ea,A,ze,X,Ke,V,Oa='<a href="/docs/huggingface_hub/main/ko/package_reference/webhooks_server#huggingface_hub.WebhookPayload">WebhookPayload</a>는 웹훅의 페이로드를 포함하는 기본 데이터 구조입니다. 이것은 <code>pydantic</code> 클래스로서 FastAPI에서 매우 쉽게 사용할 수 있습니다. 즉 WebhookPayload를 웹후크 엔드포인트에 매개변수로 전달하면 자동으로 유효성이 검사되고 파이썬 객체로 파싱됩니다.',ea,O,qa='웹훅 페이로드에 대한 자세한 사항은 이 <a href="https://huggingface.co/docs/hub/webhooks#webhook-payloads" rel="nofollow">가이드</a>를 참고하세요.',aa,q,z,ta,K,oa,ee,ae,na,te,sa,oe,ne,la,se,ra,le,re,ha,he,ga,ge,ie,ia,ue,ua,pe,de,pa,ce,da,be,fe,ca,me,ba,$e,ye,fa,ke,ma,_e,ve,$a,we,ya,Me,We,ka,Pe,_a,xe,va;return T=new j({props:{title:"웹훅 서버",local:"webhooks-server",headingTag:"h1"}}),G=new Je({props:{$$slots:{default:[rt]},$$scope:{ctx:_}}}),S=new Je({props:{warning:!0,$$slots:{default:[ht]},$$scope:{ctx:_}}}),R=new j({props:{title:"서버",local:"server",headingTag:"h2"}}),N=new j({props:{title:"WebhooksServer",local:"huggingface_hub.WebhooksServer ][ huggingface_hub.WebhooksServer",headingTag:"h3"}}),B=new C({props:{name:"huggingface_hub.WebhooksServer",anchor:"huggingface_hub.WebhooksServer",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"huggingface_hub.WebhooksServer.ui",description:`<strong>ui</strong> (<code>gradio.Blocks</code>, optional) &#x2014;
A Gradio UI instance to be used as the Space landing page. If <code>None</code>, a UI displaying instructions
about the configured webhooks is created.`,name:"ui"},{anchor:"huggingface_hub.WebhooksServer.webhook_secret",description:`<strong>webhook_secret</strong> (<code>str</code>, optional) &#x2014;
A secret key to verify incoming webhook requests. You can set this value to any secret you want as long as
you also configure it in your <a href="https://huggingface.co/settings/webhooks" rel="nofollow">webhooks settings panel</a>. You
can also set this value as the <code>WEBHOOK_SECRET</code> environment variable. If no secret is provided, the
webhook endpoints are opened without any security.`,name:"webhook_secret"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_server.py#L42"}}),J=new Je({props:{warning:!0,$$slots:{default:[gt]},$$scope:{ctx:_}}}),x=new Je({props:{warning:!0,$$slots:{default:[it]},$$scope:{ctx:_}}}),E=new Ha({props:{anchor:"huggingface_hub.WebhooksServer.example",$$slots:{default:[ut]},$$scope:{ctx:_}}}),D=new j({props:{title:"@webhook_endpoint",local:"huggingface_hub.webhook_endpoint ][ huggingface_hub.webhook_endpoint",headingTag:"h3"}}),F=new C({props:{name:"huggingface_hub.webhook_endpoint",anchor:"huggingface_hub.webhook_endpoint",parameters:[{name:"path",val:": typing.Optional[str] = None"}],parametersDescription:[{anchor:"huggingface_hub.webhook_endpoint.path",description:`<strong>path</strong> (<code>str</code>, optional) &#x2014;
The URL path to register the webhook function. If not provided, the function name will be used as the path.
In any case, all webhooks are registered under <code>/webhooks</code>.`,name:"path"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_server.py#L230"}}),H=new Je({props:{warning:!0,$$slots:{default:[pt]},$$scope:{ctx:_}}}),Z=new Je({props:{warning:!0,$$slots:{default:[dt]},$$scope:{ctx:_}}}),Y=new Ha({props:{anchor:"huggingface_hub.webhook_endpoint.example",$$slots:{default:[ct]},$$scope:{ctx:_}}}),A=new Ha({props:{anchor:"huggingface_hub.webhook_endpoint.example-2",$$slots:{default:[bt]},$$scope:{ctx:_}}}),X=new j({props:{title:"페이로드",local:"huggingface_hub.WebhookPayload ][ huggingface_hub.WebhookPayload",headingTag:"h2"}}),z=new C({props:{name:"class huggingface_hub.WebhookPayload",anchor:"huggingface_hub.WebhookPayload",parameters:[{name:"event",val:": WebhookPayloadEvent"},{name:"repo",val:": WebhookPayloadRepo"},{name:"discussion",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadDiscussion] = None"},{name:"comment",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadComment] = None"},{name:"webhook",val:": WebhookPayloadWebhook"},{name:"movedTo",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadMovedTo] = None"},{name:"updatedRefs",val:": typing.Optional[typing.List[huggingface_hub._webhooks_payload.WebhookPayloadUpdatedRef]] = None"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L130"}}),K=new j({props:{title:"WebhookPayload",local:"huggingface_hub.WebhookPayload ][ huggingface_hub.WebhookPayload",headingTag:"h3"}}),ae=new C({props:{name:"class huggingface_hub.WebhookPayload",anchor:"huggingface_hub.WebhookPayload",parameters:[{name:"event",val:": WebhookPayloadEvent"},{name:"repo",val:": WebhookPayloadRepo"},{name:"discussion",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadDiscussion] = None"},{name:"comment",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadComment] = None"},{name:"webhook",val:": WebhookPayloadWebhook"},{name:"movedTo",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadMovedTo] = None"},{name:"updatedRefs",val:": typing.Optional[typing.List[huggingface_hub._webhooks_payload.WebhookPayloadUpdatedRef]] = None"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L130"}}),te=new j({props:{title:"WebhookPayloadComment",local:"huggingface_hub.WebhookPayloadComment ][ huggingface_hub.WebhookPayloadComment",headingTag:"h3"}}),ne=new C({props:{name:"class huggingface_hub.WebhookPayloadComment",anchor:"huggingface_hub.WebhookPayloadComment",parameters:[{name:"id",val:": str"},{name:"author",val:": ObjectId"},{name:"hidden",val:": bool"},{name:"content",val:": typing.Optional[str] = None"},{name:"url",val:": WebhookPayloadUrl"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L95"}}),se=new j({props:{title:"WebhookPayloadDiscussion",local:"huggingface_hub.WebhookPayloadDiscussion ][ huggingface_hub.WebhookPayloadDiscussion",headingTag:"h3"}}),re=new C({props:{name:"class huggingface_hub.WebhookPayloadDiscussion",anchor:"huggingface_hub.WebhookPayloadDiscussion",parameters:[{name:"id",val:": str"},{name:"num",val:": int"},{name:"author",val:": ObjectId"},{name:"url",val:": WebhookPayloadUrl"},{name:"title",val:": str"},{name:"isPullRequest",val:": bool"},{name:"status",val:": typing.Literal['closed', 'draft', 'open', 'merged']"},{name:"changes",val:": typing.Optional[huggingface_hub._webhooks_payload.WebhookPayloadDiscussionChanges] = None"},{name:"pinned",val:": typing.Optional[bool] = None"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L102"}}),he=new j({props:{title:"WebhookPayloadDiscussionChanges",local:"huggingface_hub.WebhookPayloadDiscussionChanges ][ huggingface_hub.WebhookPayloadDiscussionChanges",headingTag:"h3"}}),ie=new C({props:{name:"class huggingface_hub.WebhookPayloadDiscussionChanges",anchor:"huggingface_hub.WebhookPayloadDiscussionChanges",parameters:[{name:"base",val:": str"},{name:"mergeCommitId",val:": typing.Optional[str] = None"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L90"}}),ue=new j({props:{title:"WebhookPayloadEvent",local:"huggingface_hub.WebhookPayloadEvent ][ huggingface_hub.WebhookPayloadEvent",headingTag:"h3"}}),de=new C({props:{name:"class huggingface_hub.WebhookPayloadEvent",anchor:"huggingface_hub.WebhookPayloadEvent",parameters:[{name:"action",val:": typing.Literal['create', 'delete', 'move', 'update']"},{name:"scope",val:": str"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L85"}}),ce=new j({props:{title:"WebhookPayloadMovedTo",local:"huggingface_hub.WebhookPayloadMovedTo ][ huggingface_hub.WebhookPayloadMovedTo",headingTag:"h3"}}),fe=new C({props:{name:"class huggingface_hub.WebhookPayloadMovedTo",anchor:"huggingface_hub.WebhookPayloadMovedTo",parameters:[{name:"name",val:": str"},{name:"owner",val:": ObjectId"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L76"}}),me=new j({props:{title:"WebhookPayloadRepo",local:"huggingface_hub.WebhookPayloadRepo ][ huggingface_hub.WebhookPayloadRepo",headingTag:"h3"}}),ye=new C({props:{name:"class huggingface_hub.WebhookPayloadRepo",anchor:"huggingface_hub.WebhookPayloadRepo",parameters:[{name:"id",val:": str"},{name:"owner",val:": ObjectId"},{name:"head_sha",val:": typing.Optional[str] = None"},{name:"name",val:": str"},{name:"private",val:": bool"},{name:"subdomain",val:": typing.Optional[str] = None"},{name:"tags",val:": typing.Optional[typing.List[str]] = None"},{name:"type",val:": typing.Literal['dataset', 'model', 'space']"},{name:"url",val:": WebhookPayloadUrl"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L113"}}),ke=new j({props:{title:"WebhookPayloadUrl",local:"huggingface_hub.WebhookPayloadUrl ][ huggingface_hub.WebhookPayloadUrl",headingTag:"h3"}}),ve=new C({props:{name:"class huggingface_hub.WebhookPayloadUrl",anchor:"huggingface_hub.WebhookPayloadUrl",parameters:[{name:"web",val:": str"},{name:"api",val:": typing.Optional[str] = None"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L71"}}),we=new j({props:{title:"WebhookPayloadWebhook",local:"huggingface_hub.WebhookPayloadWebhook ][ huggingface_hub.WebhookPayloadWebhook",headingTag:"h3"}}),We=new C({props:{name:"class huggingface_hub.WebhookPayloadWebhook",anchor:"huggingface_hub.WebhookPayloadWebhook",parameters:[{name:"id",val:": str"},{name:"version",val:": typing.Literal[3]"}],source:"https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/_webhooks_payload.py#L81"}}),Pe=new lt({props:{source:"https://github.com/huggingface/huggingface_hub/blob/main/docs/source/ko/package_reference/webhooks_server.md"}}),{c(){t=b("meta"),c=l(),n=b("p"),m=l(),h(T.$$.fragment),v=l(),I=b("p"),I.innerHTML=Ya,Ne=l(),h(G.$$.fragment),Be=l(),h(S.$$.fragment),De=l(),h(R.$$.fragment),Fe=l(),Q=b("p"),Q.innerHTML=Aa,Xe=l(),h(N.$$.fragment),Ve=l(),w=b("div"),h(B.$$.fragment),wa=l(),Ue=b("p"),Ue.innerHTML=Ra,Ma=l(),je=b("p"),je.innerHTML=Qa,Wa=l(),Te=b("p"),Te.innerHTML=Na,Pa=l(),h(J.$$.fragment),Ua=l(),h(x.$$.fragment),ja=l(),h(E.$$.fragment),Oe=l(),h(D.$$.fragment),qe=l(),$=b("div"),h(F.$$.fragment),Ta=l(),Ce=b("p"),Ce.innerHTML=Ba,Ca=l(),Ie=b("p"),Ie.innerHTML=Da,Ia=l(),Le=b("p"),Le.innerHTML=Fa,La=l(),h(H.$$.fragment),Ga=l(),h(Z.$$.fragment),Sa=l(),Ge=b("p"),Ge.textContent=Xa,Ja=l(),h(Y.$$.fragment),xa=l(),Se=b("p"),Se.textContent=Va,Ea=l(),h(A.$$.fragment),ze=l(),h(X.$$.fragment),Ke=l(),V=b("p"),V.innerHTML=Oa,ea=l(),O=b("p"),O.innerHTML=qa,aa=l(),q=b("div"),h(z.$$.fragment),ta=l(),h(K.$$.fragment),oa=l(),ee=b("div"),h(ae.$$.fragment),na=l(),h(te.$$.fragment),sa=l(),oe=b("div"),h(ne.$$.fragment),la=l(),h(se.$$.fragment),ra=l(),le=b("div"),h(re.$$.fragment),ha=l(),h(he.$$.fragment),ga=l(),ge=b("div"),h(ie.$$.fragment),ia=l(),h(ue.$$.fragment),ua=l(),pe=b("div"),h(de.$$.fragment),pa=l(),h(ce.$$.fragment),da=l(),be=b("div"),h(fe.$$.fragment),ca=l(),h(me.$$.fragment),ba=l(),$e=b("div"),h(ye.$$.fragment),fa=l(),h(ke.$$.fragment),ma=l(),_e=b("div"),h(ve.$$.fragment),$a=l(),h(we.$$.fragment),ya=l(),Me=b("div"),h(We.$$.fragment),ka=l(),h(Pe.$$.fragment),_a=l(),xe=b("p"),this.h()},l(e){const a=st("svelte-u9bgzb",document.head);t=f(a,"META",{name:!0,content:!0}),a.forEach(o),c=r(e),n=f(e,"P",{}),P(n).forEach(o),m=r(e),g(T.$$.fragment,e),v=r(e),I=f(e,"P",{"data-svelte-h":!0}),M(I)!=="svelte-t2ccrn"&&(I.innerHTML=Ya),Ne=r(e),g(G.$$.fragment,e),Be=r(e),g(S.$$.fragment,e),De=r(e),g(R.$$.fragment,e),Fe=r(e),Q=f(e,"P",{"data-svelte-h":!0}),M(Q)!=="svelte-toyanw"&&(Q.innerHTML=Aa),Xe=r(e),g(N.$$.fragment,e),Ve=r(e),w=f(e,"DIV",{class:!0});var W=P(w);g(B.$$.fragment,W),wa=r(W),Ue=f(W,"P",{"data-svelte-h":!0}),M(Ue)!=="svelte-1racsz1"&&(Ue.innerHTML=Ra),Ma=r(W),je=f(W,"P",{"data-svelte-h":!0}),M(je)!=="svelte-1msja7c"&&(je.innerHTML=Qa),Wa=r(W),Te=f(W,"P",{"data-svelte-h":!0}),M(Te)!=="svelte-19yut5m"&&(Te.innerHTML=Na),Pa=r(W),g(J.$$.fragment,W),Ua=r(W),g(x.$$.fragment,W),ja=r(W),g(E.$$.fragment,W),W.forEach(o),Oe=r(e),g(D.$$.fragment,e),qe=r(e),$=f(e,"DIV",{class:!0});var k=P($);g(F.$$.fragment,k),Ta=r(k),Ce=f(k,"P",{"data-svelte-h":!0}),M(Ce)!=="svelte-137eevd"&&(Ce.innerHTML=Ba),Ca=r(k),Ie=f(k,"P",{"data-svelte-h":!0}),M(Ie)!=="svelte-njvgbl"&&(Ie.innerHTML=Da),Ia=r(k),Le=f(k,"P",{"data-svelte-h":!0}),M(Le)!=="svelte-1fvc5uk"&&(Le.innerHTML=Fa),La=r(k),g(H.$$.fragment,k),Ga=r(k),g(Z.$$.fragment,k),Sa=r(k),Ge=f(k,"P",{"data-svelte-h":!0}),M(Ge)!=="svelte-a86ntl"&&(Ge.textContent=Xa),Ja=r(k),g(Y.$$.fragment,k),xa=r(k),Se=f(k,"P",{"data-svelte-h":!0}),M(Se)!=="svelte-t28ynx"&&(Se.textContent=Va),Ea=r(k),g(A.$$.fragment,k),k.forEach(o),ze=r(e),g(X.$$.fragment,e),Ke=r(e),V=f(e,"P",{"data-svelte-h":!0}),M(V)!=="svelte-1laegfa"&&(V.innerHTML=Oa),ea=r(e),O=f(e,"P",{"data-svelte-h":!0}),M(O)!=="svelte-17c948s"&&(O.innerHTML=qa),aa=r(e),q=f(e,"DIV",{class:!0});var Ee=P(q);g(z.$$.fragment,Ee),Ee.forEach(o),ta=r(e),g(K.$$.fragment,e),oa=r(e),ee=f(e,"DIV",{class:!0});var He=P(ee);g(ae.$$.fragment,He),He.forEach(o),na=r(e),g(te.$$.fragment,e),sa=r(e),oe=f(e,"DIV",{class:!0});var Ze=P(oe);g(ne.$$.fragment,Ze),Ze.forEach(o),la=r(e),g(se.$$.fragment,e),ra=r(e),le=f(e,"DIV",{class:!0});var Ye=P(le);g(re.$$.fragment,Ye),Ye.forEach(o),ha=r(e),g(he.$$.fragment,e),ga=r(e),ge=f(e,"DIV",{class:!0});var Ae=P(ge);g(ie.$$.fragment,Ae),Ae.forEach(o),ia=r(e),g(ue.$$.fragment,e),ua=r(e),pe=f(e,"DIV",{class:!0});var Re=P(pe);g(de.$$.fragment,Re),Re.forEach(o),pa=r(e),g(ce.$$.fragment,e),da=r(e),be=f(e,"DIV",{class:!0});var Qe=P(be);g(fe.$$.fragment,Qe),Qe.forEach(o),ca=r(e),g(me.$$.fragment,e),ba=r(e),$e=f(e,"DIV",{class:!0});var za=P($e);g(ye.$$.fragment,za),za.forEach(o),fa=r(e),g(ke.$$.fragment,e),ma=r(e),_e=f(e,"DIV",{class:!0});var Ka=P(_e);g(ve.$$.fragment,Ka),Ka.forEach(o),$a=r(e),g(we.$$.fragment,e),ya=r(e),Me=f(e,"DIV",{class:!0});var et=P(Me);g(We.$$.fragment,et),et.forEach(o),ka=r(e),g(Pe.$$.fragment,e),_a=r(e),xe=f(e,"P",{}),P(xe).forEach(o),this.h()},h(){U(t,"name","hf:doc:metadata"),U(t,"content",mt),U(w,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U($,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(ee,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(oe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(ge,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(pe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(be,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U($e,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(_e,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),U(Me,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,a){y(document.head,t),s(e,c,a),s(e,n,a),s(e,m,a),i(T,e,a),s(e,v,a),s(e,I,a),s(e,Ne,a),i(G,e,a),s(e,Be,a),i(S,e,a),s(e,De,a),i(R,e,a),s(e,Fe,a),s(e,Q,a),s(e,Xe,a),i(N,e,a),s(e,Ve,a),s(e,w,a),i(B,w,null),y(w,wa),y(w,Ue),y(w,Ma),y(w,je),y(w,Wa),y(w,Te),y(w,Pa),i(J,w,null),y(w,Ua),i(x,w,null),y(w,ja),i(E,w,null),s(e,Oe,a),i(D,e,a),s(e,qe,a),s(e,$,a),i(F,$,null),y($,Ta),y($,Ce),y($,Ca),y($,Ie),y($,Ia),y($,Le),y($,La),i(H,$,null),y($,Ga),i(Z,$,null),y($,Sa),y($,Ge),y($,Ja),i(Y,$,null),y($,xa),y($,Se),y($,Ea),i(A,$,null),s(e,ze,a),i(X,e,a),s(e,Ke,a),s(e,V,a),s(e,ea,a),s(e,O,a),s(e,aa,a),s(e,q,a),i(z,q,null),s(e,ta,a),i(K,e,a),s(e,oa,a),s(e,ee,a),i(ae,ee,null),s(e,na,a),i(te,e,a),s(e,sa,a),s(e,oe,a),i(ne,oe,null),s(e,la,a),i(se,e,a),s(e,ra,a),s(e,le,a),i(re,le,null),s(e,ha,a),i(he,e,a),s(e,ga,a),s(e,ge,a),i(ie,ge,null),s(e,ia,a),i(ue,e,a),s(e,ua,a),s(e,pe,a),i(de,pe,null),s(e,pa,a),i(ce,e,a),s(e,da,a),s(e,be,a),i(fe,be,null),s(e,ca,a),i(me,e,a),s(e,ba,a),s(e,$e,a),i(ye,$e,null),s(e,fa,a),i(ke,e,a),s(e,ma,a),s(e,_e,a),i(ve,_e,null),s(e,$a,a),i(we,e,a),s(e,ya,a),s(e,Me,a),i(We,Me,null),s(e,ka,a),i(Pe,e,a),s(e,_a,a),s(e,xe,a),va=!0},p(e,[a]){const W={};a&2&&(W.$$scope={dirty:a,ctx:e}),G.$set(W);const k={};a&2&&(k.$$scope={dirty:a,ctx:e}),S.$set(k);const Ee={};a&2&&(Ee.$$scope={dirty:a,ctx:e}),J.$set(Ee);const He={};a&2&&(He.$$scope={dirty:a,ctx:e}),x.$set(He);const Ze={};a&2&&(Ze.$$scope={dirty:a,ctx:e}),E.$set(Ze);const Ye={};a&2&&(Ye.$$scope={dirty:a,ctx:e}),H.$set(Ye);const Ae={};a&2&&(Ae.$$scope={dirty:a,ctx:e}),Z.$set(Ae);const Re={};a&2&&(Re.$$scope={dirty:a,ctx:e}),Y.$set(Re);const Qe={};a&2&&(Qe.$$scope={dirty:a,ctx:e}),A.$set(Qe)},i(e){va||(u(T.$$.fragment,e),u(G.$$.fragment,e),u(S.$$.fragment,e),u(R.$$.fragment,e),u(N.$$.fragment,e),u(B.$$.fragment,e),u(J.$$.fragment,e),u(x.$$.fragment,e),u(E.$$.fragment,e),u(D.$$.fragment,e),u(F.$$.fragment,e),u(H.$$.fragment,e),u(Z.$$.fragment,e),u(Y.$$.fragment,e),u(A.$$.fragment,e),u(X.$$.fragment,e),u(z.$$.fragment,e),u(K.$$.fragment,e),u(ae.$$.fragment,e),u(te.$$.fragment,e),u(ne.$$.fragment,e),u(se.$$.fragment,e),u(re.$$.fragment,e),u(he.$$.fragment,e),u(ie.$$.fragment,e),u(ue.$$.fragment,e),u(de.$$.fragment,e),u(ce.$$.fragment,e),u(fe.$$.fragment,e),u(me.$$.fragment,e),u(ye.$$.fragment,e),u(ke.$$.fragment,e),u(ve.$$.fragment,e),u(we.$$.fragment,e),u(We.$$.fragment,e),u(Pe.$$.fragment,e),va=!0)},o(e){p(T.$$.fragment,e),p(G.$$.fragment,e),p(S.$$.fragment,e),p(R.$$.fragment,e),p(N.$$.fragment,e),p(B.$$.fragment,e),p(J.$$.fragment,e),p(x.$$.fragment,e),p(E.$$.fragment,e),p(D.$$.fragment,e),p(F.$$.fragment,e),p(H.$$.fragment,e),p(Z.$$.fragment,e),p(Y.$$.fragment,e),p(A.$$.fragment,e),p(X.$$.fragment,e),p(z.$$.fragment,e),p(K.$$.fragment,e),p(ae.$$.fragment,e),p(te.$$.fragment,e),p(ne.$$.fragment,e),p(se.$$.fragment,e),p(re.$$.fragment,e),p(he.$$.fragment,e),p(ie.$$.fragment,e),p(ue.$$.fragment,e),p(de.$$.fragment,e),p(ce.$$.fragment,e),p(fe.$$.fragment,e),p(me.$$.fragment,e),p(ye.$$.fragment,e),p(ke.$$.fragment,e),p(ve.$$.fragment,e),p(we.$$.fragment,e),p(We.$$.fragment,e),p(Pe.$$.fragment,e),va=!1},d(e){e&&(o(c),o(n),o(m),o(v),o(I),o(Ne),o(Be),o(De),o(Fe),o(Q),o(Xe),o(Ve),o(w),o(Oe),o(qe),o($),o(ze),o(Ke),o(V),o(ea),o(O),o(aa),o(q),o(ta),o(oa),o(ee),o(na),o(sa),o(oe),o(la),o(ra),o(le),o(ha),o(ga),o(ge),o(ia),o(ua),o(pe),o(pa),o(da),o(be),o(ca),o(ba),o($e),o(fa),o(ma),o(_e),o($a),o(ya),o(Me),o(ka),o(_a),o(xe)),o(t),d(T,e),d(G,e),d(S,e),d(R,e),d(N,e),d(B),d(J),d(x),d(E),d(D,e),d(F),d(H),d(Z),d(Y),d(A),d(X,e),d(z),d(K,e),d(ae),d(te,e),d(ne),d(se,e),d(re),d(he,e),d(ie),d(ue,e),d(de),d(ce,e),d(fe),d(me,e),d(ye),d(ke,e),d(ve),d(we,e),d(We),d(Pe,e)}}}const mt='{"title":"웹훅 서버","local":"webhooks-server","sections":[{"title":"서버","local":"server","sections":[{"title":"WebhooksServer","local":"huggingface_hub.WebhooksServer ][ huggingface_hub.WebhooksServer","sections":[],"depth":3},{"title":"@webhook_endpoint","local":"huggingface_hub.webhook_endpoint ][ huggingface_hub.webhook_endpoint","sections":[],"depth":3}],"depth":2},{"title":"페이로드","local":"huggingface_hub.WebhookPayload ][ huggingface_hub.WebhookPayload","sections":[{"title":"WebhookPayload","local":"huggingface_hub.WebhookPayload ][ huggingface_hub.WebhookPayload","sections":[],"depth":3},{"title":"WebhookPayloadComment","local":"huggingface_hub.WebhookPayloadComment ][ huggingface_hub.WebhookPayloadComment","sections":[],"depth":3},{"title":"WebhookPayloadDiscussion","local":"huggingface_hub.WebhookPayloadDiscussion ][ huggingface_hub.WebhookPayloadDiscussion","sections":[],"depth":3},{"title":"WebhookPayloadDiscussionChanges","local":"huggingface_hub.WebhookPayloadDiscussionChanges ][ huggingface_hub.WebhookPayloadDiscussionChanges","sections":[],"depth":3},{"title":"WebhookPayloadEvent","local":"huggingface_hub.WebhookPayloadEvent ][ huggingface_hub.WebhookPayloadEvent","sections":[],"depth":3},{"title":"WebhookPayloadMovedTo","local":"huggingface_hub.WebhookPayloadMovedTo ][ huggingface_hub.WebhookPayloadMovedTo","sections":[],"depth":3},{"title":"WebhookPayloadRepo","local":"huggingface_hub.WebhookPayloadRepo ][ huggingface_hub.WebhookPayloadRepo","sections":[],"depth":3},{"title":"WebhookPayloadUrl","local":"huggingface_hub.WebhookPayloadUrl ][ huggingface_hub.WebhookPayloadUrl","sections":[],"depth":3},{"title":"WebhookPayloadWebhook","local":"huggingface_hub.WebhookPayloadWebhook ][ huggingface_hub.WebhookPayloadWebhook","sections":[],"depth":3}],"depth":2}],"depth":1}';function $t(_){return tt(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Pt extends ot{constructor(t){super(),nt(this,t,$t,ft,at,{})}}export{Pt as component};
