Buckets:

HuggingFaceDocBuilder's picture
download
raw
19.9 kB
import{s as Ot,n as Kt,o as en}from"../chunks/scheduler.de5597d1.js";import{S as tn,i as nn,e as a,s,c as p,h as ln,a as o,d as n,b as i,f as $e,g as c,j as r,k as Dt,l as f,m as l,n as u,t as m,o as d,p as h}from"../chunks/index.f8bac2c1.js";import{C as sn,H as T,E as an}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.9a4a4f42.js";import{C as Te}from"../chunks/CodeBlock.528d2ca0.js";import{M as on}from"../chunks/MermaidChart.80c7bbe8.js";function rn(gt){let J,ge,Je,ye,$,xe,g,ke,y,yt="To invoke any API’s mentioned in this specification a client MUST first acquire a token (and the URL) to authenticate against the server which serves these API’s.",je,x,xt='The Xet protocol server uses bearer authentication via a token generated by the Hugging Face Hub (<a href="https://huggingface.co" rel="nofollow">https://huggingface.co</a>).',ve,k,kt="The following section explains how to acquire such a token.",Ue,j,be,v,jt="<strong>URL Pattern:</strong>",He,U,Ie,b,vt="<strong>Parameters:</strong>",Ce,H,Ut="All parameters are required to form the URL.",Le,I,bt="<li><code>repo_type</code>: Type of repository - <code>model</code>, <code>dataset</code>, or <code>space</code></li> <li><code>repo_id</code>: Repository identifier in format <code>namespace/repo-name</code></li> <li><code>token_type</code>: Either <code>read</code> or <code>write</code>.</li> <li><code>revision</code>: Git revision (branch, tag, or commit hash; default to using <code>main</code> if no specific ref is required)</li>",Be,C,Ht='To understand the distinction for between <code>token_type</code> values read onwards in this document to <a href="./auth#token-scope">Token Scope</a>.',Ze,L,It="<strong>Example URLs:</strong>",Re,B,Ee,Z,Ct="<strong>HTTP Method:</strong> GET",Xe,R,Lt="<strong>Required Headers:</strong>",_e,E,Bt="<li><code>Authorization</code>: Bearer token for Hugging Face Hub authentication</li>",Ge,X,Ae,_,Zt="A JSON encoded object with the following format:",Ye,G,We,A,Rt="<li>accessToken is the token to be used when invoking API’s on the Xet CAS service (any Xet API denoted in this specification)</li> <li>exp is the unix timestamp of when this token expires</li> <li>casUrl is the API service endpoint URL</li>",Se,Y,Et="Users MAY assume the “accessToken” and “casUrl” fields lengths have an upper limit of 64000 characters.",qe,W,Ve,S,ze,q,Fe,V,Ne,z,Xt="<li><strong>401 Unauthorized</strong>: Invalid or missing Hub authentication token</li> <li><strong>403 Forbidden</strong>: Insufficient permissions for the requested token type</li> <li><strong>404 Not Found</strong>: Repository or revision does not exist</li>",Pe,F,Qe,N,_t="Here’s a basic implementation flow:",De,M,P,de,Gt="<strong>Make the request:</strong>",ft,Q,Tt,D,he,At="<strong>Parse the response</strong>",Jt,O,wt,Me,Yt=`<p><strong>Use the token with Xet service:</strong>
Use Bearer authentication with the value for the <code>accessToken</code> key to authenticate with the Xet service at <code>endpoint</code> until <code>expiration</code> time.</p>`,$t,fe,Wt=`<p><strong>Token refresh (when needed):</strong>
Use the same API to generate a new token.</p> <blockquote class="note"><p>In <code>xet-core</code> we SHOULD add 30 seconds of buffer time before the provided <code>expiration</code> time to refresh the token.</p></blockquote>`,Oe,K,Ke,ee,St=`Xet tokens can have either a <code>read</code> or a <code>write</code> scope.
<code>write</code> scope supersedes <code>read</code> scope and all <code>read</code> scope API’s can be invoked when using a <code>write</code> scope token.
The type of token issued is determined on the <code>token_type</code> URI path component when requesting the token from the Hugging Face Hub (see above).`,et,te,qt="Check API specification for what scope level is necessary to invoke each API (briefly, only <code>POST /shard</code> and <code>POST /xorb/*</code> API’s require <code>write</code> scope).",tt,ne,Vt="The scope of the Xet tokens is limited to the repository and ref for which they were issued. To upload or download from different repositories or refs (different branches) clients MUST be issued different tokens.",nt,le,lt,se,zt="When requesting a Xet token from the Hugging Face Hub, you will only receive a Xet token matching the requested parameters if you actually have access to them, based on the access afforded to your Hub authentication token.",st,ie,Ft="If you require a <code>write</code> scope Xet token, then you MUST request it using a Hugging Face Hub token that has write access to the particular repository and ref that you want to access.",it,ae,Nt="If you request a <code>read</code> scope Xet token, then you MUST request it using a Hugging Face Hub token that has at least read access to the particular repository and ref you want to access.",at,oe,Pt="If you are using Fine-grained Hugging Face Hub Access Tokens, your tokens MUST have read or write access to the contents of repositories to be issues read or write Xet tokens respectively.",ot,re,rt,pe,Qt="<li>Xet tokens are time-limited and SHOULD be refreshed/swapped before expiration</li> <li>Store tokens securely and SHOULD NOT log them (both Hub authentication tokens and Xet tokens)</li> <li>SHOULD use read tokens when possible; only request write tokens when necessary</li>",pt,ce,ct,ue,ut,me,mt,we,dt;return $=new sn({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),g=new T({props:{title:"Authentication and Authorization",local:"authentication-and-authorization",headingTag:"h1"}}),j=new T({props:{title:"Token Request API Endpoints",local:"token-request-api-endpoints",headingTag:"h2"}}),U=new Te({props:{code:"aHR0cHMlM0ElMkYlMkZodWdnaW5nZmFjZS5jbyUyRmFwaSUyRiU3QnJlcG9fdHlwZSU3RHMlMkYlN0JyZXBvX2lkJTdEJTJGeGV0LSU3QnRva2VuX3R5cGUlN0QtdG9rZW4lMkYlN0JyZXZpc2lvbiU3RA==",highlighted:"https://huggingface.co/api/{repo_type}s/{repo_id}/xet-{token_type}-token/{revision}",lang:"txt",wrap:!1}}),B=new Te({props:{code:"aHR0cHMlM0ElMkYlMkZodWdnaW5nZmFjZS5jbyUyRmFwaSUyRm1vZGVscyUyRnNlbnRlbmNlLXRyYW5zZm9ybWVycyUyRmFsbC1NaW5pTE0tTDYtdjIlMkZ4ZXQtcmVhZC10b2tlbiUyRm1haW4lMEFodHRwcyUzQSUyRiUyRmh1Z2dpbmdmYWNlLmNvJTJGYXBpJTJGZGF0YXNldHMlMkZIdWdnaW5nRmFjZU00JTJGdGhlX2NhdWxkcm9uJTJGeGV0LXdyaXRlLXRva2VuJTJGdjEuMSUwQWh0dHBzJTNBJTJGJTJGaHVnZ2luZ2ZhY2UuY28lMkZhcGklMkZzcGFjZXMlMkZqc3VseiUyRnJlYWR5LXhldC1nbyUyRnhldC1yZWFkLXRva2VuJTJGbWFpbg==",highlighted:`https://huggingface.co/api/models/sentence-transformers/all-MiniLM-L6-v2/xet-read-token/main
https://huggingface.co/api/datasets/HuggingFaceM4/the_cauldron/xet-write-token/v1.1
https://huggingface.co/api/spaces/jsulz/ready-xet-go/xet-read-token/main`,lang:"txt",wrap:!1}}),X=new T({props:{title:"Response Format",local:"response-format",headingTag:"h3"}}),G=new Te({props:{code:"JTdCJTBBJTIwJTIwJTIwJTIyYWNjZXNzVG9rZW4lMjIlM0ElMjBzdHJpbmclMkMlMEElMjAlMjAlMjAlMjJleHAlMjIlM0ElMjBudW1iZXIlMkMlMEElMjAlMjAlMjAlMjJjYXNVcmwlMjIlM0ElMjBzdHJpbmclMkMlMEElN0Q=",highlighted:`{
<span class="hljs-string">&quot;accessToken&quot;</span>: <span class="hljs-built_in">string</span>,
<span class="hljs-string">&quot;exp&quot;</span>: <span class="hljs-built_in">number</span>,
<span class="hljs-string">&quot;casUrl&quot;</span>: <span class="hljs-built_in">string</span>,
}`,lang:"typescript",wrap:!1}}),W=new T({props:{title:"Example Response Object",local:"example-response-object",headingTag:"h4"}}),S=new Te({props:{code:"JTdCJTBBJTIwJTIwJTIwJTIyYWNjZXNzVG9rZW4lMjIlM0ElMjAlMjJ4ZXRfeHh4eHh4eHh4eHglMjIlMkMlMEElMjAlMjAlMjAlMjJleHAlMjIlM0ElMjAxODQ4NTM1NjY4JTJDJTBBJTIwJTIwJTIwJTIyY2FzVXJsJTIyJTNBJTIwJTIyaHR0cHMlM0ElMkYlMkZjYXMtc2VydmVyLnhldGh1Yi5oZi5jbyUyMiUwQSU3RA==",highlighted:`<span class="hljs-punctuation">{</span>
<span class="hljs-attr">&quot;accessToken&quot;</span><span class="hljs-punctuation">:</span> <span class="hljs-string">&quot;xet_xxxxxxxxxxx&quot;</span><span class="hljs-punctuation">,</span>
<span class="hljs-attr">&quot;exp&quot;</span><span class="hljs-punctuation">:</span> <span class="hljs-number">1848535668</span><span class="hljs-punctuation">,</span>
<span class="hljs-attr">&quot;casUrl&quot;</span><span class="hljs-punctuation">:</span> <span class="hljs-string">&quot;https://cas-server.xethub.hf.co&quot;</span>
<span class="hljs-punctuation">}</span>`,lang:"json",wrap:!1}}),q=new T({props:{title:"Error Handling",local:"error-handling",headingTag:"h3"}}),V=new T({props:{title:"HTTP Errors",local:"http-errors",headingTag:"h4"}}),F=new T({props:{title:"Implementation Example",local:"implementation-example",headingTag:"h3"}}),Q=new Te({props:{code:"R0VUJTIwJTJGYXBpJTJGbW9kZWxzJTJGYmxhY2stZm9yZXN0LWxhYnMlMkZGTFVYLjEtZGV2JTJGeGV0LXJlYWQtdG9rZW4lMkZtYWluJTBBSG9zdCUzQSUyMGh1Z2dpbmdmYWNlLmNvJTBBQXV0aG9yaXphdGlvbiUzQSUyMEJlYXJlciUyMHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eA==",highlighted:`GET /api/models/black-forest-labs/FLUX.1-dev/xet-read-token/main
<span class="hljs-attribute">Host</span><span class="hljs-punctuation">: </span>huggingface.co
<span class="hljs-attribute">Authorization</span><span class="hljs-punctuation">: </span>Bearer xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx`,lang:"http",wrap:!1}}),O=new Te({props:{code:"ZW5kcG9pbnQlMjAlM0QlMjByZXNwb25zZV9qc29uJTVCJTIyY2FzVXJsJTIyJTVEJTBBYWNjZXNzX3Rva2VuJTIwJTNEJTIwcmVzcG9uc2VfanNvbiU1QiUyMmFjY2Vzc1Rva2VuJTIyJTVEJTBBZXhwaXJhdGlvbiUyMCUzRCUyMHJlc3BvbnNlX2pzb24lNUIlMjJleHAlMjIlNUQ=",highlighted:`endpoint = response_json[<span class="hljs-string">&quot;casUrl&quot;</span>]
access_token = response_json[<span class="hljs-string">&quot;accessToken&quot;</span>]
expiration = response_json[<span class="hljs-string">&quot;exp&quot;</span>]`,lang:"python",wrap:!1}}),K=new T({props:{title:"Token Scope",local:"token-scope",headingTag:"h2"}}),le=new T({props:{title:"Token Scope Relative to Hugging Face Hub Authentication Token",local:"token-scope-relative-to-hugging-face-hub-authentication-token",headingTag:"h2"}}),re=new T({props:{title:"Security Considerations",local:"security-considerations",headingTag:"h2"}}),ce=new T({props:{title:"Diagram",local:"diagram",headingTag:"h2"}}),ue=new on({props:{code:"c2VxdWVuY2VEaWFncmFtJTBBJTIwJTIwJTIwYXV0b251bWJlciUwQSUyMCUyMCUyMGFjdG9yJTIwQyUyMGFzJTIwQ2xpZW50JTBBJTIwJTIwJTIwcGFydGljaXBhbnQlMjBIJTIwYXMlMjBIdWdnaW5nJTIwRmFjZSUyMEh1YiUyMChodHRwcyUzQSUyRiUyRmh1Z2dpbmdmYWNlLmNvKSUwQSUyMCUyMCUyMHBhcnRpY2lwYW50JTIwQ0FTJTIwYXMlMjBDQVMlMjBBUEklMEElMEElMjAlMjAlMjBsb29wJTIwUmVwZWF0JTIwYWZ0ZXIlMjB0b2tlbiUyMGV4cGlyYXRpb24lMEElMjAlMjAlMjAlMjAlMjAlMjBDLSUzRSUzRUglM0ElMjBodHRwcyUzQSUyRiUyRmh1Z2dpbmdmYWNlLmNvJTJGYXBpJTJGJTdCcmVwb190eXBlJTdEcyUyRiU3QnJlcG9faWQlN0QlMkZ4ZXQtJTdCdG9rZW5fdHlwZSU3RC10b2tlbiUyRiU3QnJldmlzaW9uJTdEJTBBJTIwJTIwJTIwJTIwJTIwJTIwSC0lM0UlM0VDJTNBJTIwJTdCJTIwY2FzVXJsJTJDJTIwYWNjZXNzVG9rZW4lMkMlMjBleHAlMjAlN0QlMEElMEElMjAlMjAlMjAlMjAlMjAlMjBsb29wJTIwQ2xpZW50JTIwaW52b2tpbmclMjBDQVMlMjBBUEkncyUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMEMtJTNFJTNFQ0FTJTNBJTIwQ0FTJTIwQVBJJ3MlMjB1c2luZyUyMGFjY2Vzc1Rva2VuJTIwYW5kJTIwY2FzVXJsJTNDYnIlMkYlM0UoUmVjb25zdHJ1Y3Rpb24lMkMlMjBYb3JiJTIwJTI2JTIwU2hhcmQlMjB1cGxvYWQlMkMlMjBHbG9iYWwlMjBEZWR1cGUpJTBBJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwQ0FTLSUzRSUzRUMlM0ElMjBBUEklMjBSZXNwb25zZXMlMkMlMjByZXR1cm5zJTIwY29kZSUyMDQwMSUyMFVuYXV0aG9yaXplZCUyMGlmJTIwdG9rZW4lMjBleHBpcmVkJTBBJTIwJTIwJTIwJTIwJTIwJTIwZW5kJTBBJTIwJTIwJTIwZW5k"}}),me=new an({props:{source:"https://github.com/huggingface/hub-docs/blob/main/docs/xet/auth.md"}}),{c(){J=a("meta"),ge=s(),Je=a("p"),ye=s(),p($.$$.fragment),xe=s(),p(g.$$.fragment),ke=s(),y=a("p"),y.textContent=yt,je=s(),x=a("p"),x.innerHTML=xt,ve=s(),k=a("p"),k.textContent=kt,Ue=s(),p(j.$$.fragment),be=s(),v=a("p"),v.innerHTML=jt,He=s(),p(U.$$.fragment),Ie=s(),b=a("p"),b.innerHTML=vt,Ce=s(),H=a("p"),H.textContent=Ut,Le=s(),I=a("ul"),I.innerHTML=bt,Be=s(),C=a("p"),C.innerHTML=Ht,Ze=s(),L=a("p"),L.innerHTML=It,Re=s(),p(B.$$.fragment),Ee=s(),Z=a("p"),Z.innerHTML=Ct,Xe=s(),R=a("p"),R.innerHTML=Lt,_e=s(),E=a("ul"),E.innerHTML=Bt,Ge=s(),p(X.$$.fragment),Ae=s(),_=a("p"),_.textContent=Zt,Ye=s(),p(G.$$.fragment),We=s(),A=a("ul"),A.innerHTML=Rt,Se=s(),Y=a("p"),Y.textContent=Et,qe=s(),p(W.$$.fragment),Ve=s(),p(S.$$.fragment),ze=s(),p(q.$$.fragment),Fe=s(),p(V.$$.fragment),Ne=s(),z=a("ul"),z.innerHTML=Xt,Pe=s(),p(F.$$.fragment),Qe=s(),N=a("p"),N.textContent=_t,De=s(),M=a("ol"),P=a("li"),de=a("p"),de.innerHTML=Gt,ft=s(),p(Q.$$.fragment),Tt=s(),D=a("li"),he=a("p"),he.innerHTML=At,Jt=s(),p(O.$$.fragment),wt=s(),Me=a("li"),Me.innerHTML=Yt,$t=s(),fe=a("li"),fe.innerHTML=Wt,Oe=s(),p(K.$$.fragment),Ke=s(),ee=a("p"),ee.innerHTML=St,et=s(),te=a("p"),te.innerHTML=qt,tt=s(),ne=a("p"),ne.textContent=Vt,nt=s(),p(le.$$.fragment),lt=s(),se=a("p"),se.textContent=zt,st=s(),ie=a("p"),ie.innerHTML=Ft,it=s(),ae=a("p"),ae.innerHTML=Nt,at=s(),oe=a("p"),oe.textContent=Pt,ot=s(),p(re.$$.fragment),rt=s(),pe=a("ul"),pe.innerHTML=Qt,pt=s(),p(ce.$$.fragment),ct=s(),p(ue.$$.fragment),ut=s(),p(me.$$.fragment),mt=s(),we=a("p"),this.h()},l(e){const t=ln("svelte-u9bgzb",document.head);J=o(t,"META",{name:!0,content:!0}),t.forEach(n),ge=i(e),Je=o(e,"P",{}),$e(Je).forEach(n),ye=i(e),c($.$$.fragment,e),xe=i(e),c(g.$$.fragment,e),ke=i(e),y=o(e,"P",{"data-svelte-h":!0}),r(y)!=="svelte-1myouam"&&(y.textContent=yt),je=i(e),x=o(e,"P",{"data-svelte-h":!0}),r(x)!=="svelte-18q4s5q"&&(x.innerHTML=xt),ve=i(e),k=o(e,"P",{"data-svelte-h":!0}),r(k)!=="svelte-ylhhzx"&&(k.textContent=kt),Ue=i(e),c(j.$$.fragment,e),be=i(e),v=o(e,"P",{"data-svelte-h":!0}),r(v)!=="svelte-1tcp7mo"&&(v.innerHTML=jt),He=i(e),c(U.$$.fragment,e),Ie=i(e),b=o(e,"P",{"data-svelte-h":!0}),r(b)!=="svelte-gyl88v"&&(b.innerHTML=vt),Ce=i(e),H=o(e,"P",{"data-svelte-h":!0}),r(H)!=="svelte-m42jnh"&&(H.textContent=Ut),Le=i(e),I=o(e,"UL",{"data-svelte-h":!0}),r(I)!=="svelte-13kv85b"&&(I.innerHTML=bt),Be=i(e),C=o(e,"P",{"data-svelte-h":!0}),r(C)!=="svelte-d091v1"&&(C.innerHTML=Ht),Ze=i(e),L=o(e,"P",{"data-svelte-h":!0}),r(L)!=="svelte-yzjc3b"&&(L.innerHTML=It),Re=i(e),c(B.$$.fragment,e),Ee=i(e),Z=o(e,"P",{"data-svelte-h":!0}),r(Z)!=="svelte-eir0si"&&(Z.innerHTML=Ct),Xe=i(e),R=o(e,"P",{"data-svelte-h":!0}),r(R)!=="svelte-wzynsm"&&(R.innerHTML=Lt),_e=i(e),E=o(e,"UL",{"data-svelte-h":!0}),r(E)!=="svelte-1fql46b"&&(E.innerHTML=Bt),Ge=i(e),c(X.$$.fragment,e),Ae=i(e),_=o(e,"P",{"data-svelte-h":!0}),r(_)!=="svelte-1xmx4sp"&&(_.textContent=Zt),Ye=i(e),c(G.$$.fragment,e),We=i(e),A=o(e,"UL",{"data-svelte-h":!0}),r(A)!=="svelte-n7ikyc"&&(A.innerHTML=Rt),Se=i(e),Y=o(e,"P",{"data-svelte-h":!0}),r(Y)!=="svelte-sz174l"&&(Y.textContent=Et),qe=i(e),c(W.$$.fragment,e),Ve=i(e),c(S.$$.fragment,e),ze=i(e),c(q.$$.fragment,e),Fe=i(e),c(V.$$.fragment,e),Ne=i(e),z=o(e,"UL",{"data-svelte-h":!0}),r(z)!=="svelte-y0j74v"&&(z.innerHTML=Xt),Pe=i(e),c(F.$$.fragment,e),Qe=i(e),N=o(e,"P",{"data-svelte-h":!0}),r(N)!=="svelte-10cm6pp"&&(N.textContent=_t),De=i(e),M=o(e,"OL",{});var w=$e(M);P=o(w,"LI",{});var ht=$e(P);de=o(ht,"P",{"data-svelte-h":!0}),r(de)!=="svelte-4yemcr"&&(de.innerHTML=Gt),ft=i(ht),c(Q.$$.fragment,ht),ht.forEach(n),Tt=i(w),D=o(w,"LI",{});var Mt=$e(D);he=o(Mt,"P",{"data-svelte-h":!0}),r(he)!=="svelte-1b5v3no"&&(he.innerHTML=At),Jt=i(Mt),c(O.$$.fragment,Mt),Mt.forEach(n),wt=i(w),Me=o(w,"LI",{"data-svelte-h":!0}),r(Me)!=="svelte-70qh2n"&&(Me.innerHTML=Yt),$t=i(w),fe=o(w,"LI",{"data-svelte-h":!0}),r(fe)!=="svelte-gvnawy"&&(fe.innerHTML=Wt),w.forEach(n),Oe=i(e),c(K.$$.fragment,e),Ke=i(e),ee=o(e,"P",{"data-svelte-h":!0}),r(ee)!=="svelte-882wgm"&&(ee.innerHTML=St),et=i(e),te=o(e,"P",{"data-svelte-h":!0}),r(te)!=="svelte-13jj1ub"&&(te.innerHTML=qt),tt=i(e),ne=o(e,"P",{"data-svelte-h":!0}),r(ne)!=="svelte-wh27bp"&&(ne.textContent=Vt),nt=i(e),c(le.$$.fragment,e),lt=i(e),se=o(e,"P",{"data-svelte-h":!0}),r(se)!=="svelte-wrcyfr"&&(se.textContent=zt),st=i(e),ie=o(e,"P",{"data-svelte-h":!0}),r(ie)!=="svelte-1m39mey"&&(ie.innerHTML=Ft),it=i(e),ae=o(e,"P",{"data-svelte-h":!0}),r(ae)!=="svelte-1y8jpil"&&(ae.innerHTML=Nt),at=i(e),oe=o(e,"P",{"data-svelte-h":!0}),r(oe)!=="svelte-nofkvt"&&(oe.textContent=Pt),ot=i(e),c(re.$$.fragment,e),rt=i(e),pe=o(e,"UL",{"data-svelte-h":!0}),r(pe)!=="svelte-1sl7wzk"&&(pe.innerHTML=Qt),pt=i(e),c(ce.$$.fragment,e),ct=i(e),c(ue.$$.fragment,e),ut=i(e),c(me.$$.fragment,e),mt=i(e),we=o(e,"P",{}),$e(we).forEach(n),this.h()},h(){Dt(J,"name","hf:doc:metadata"),Dt(J,"content",pn)},m(e,t){f(document.head,J),l(e,ge,t),l(e,Je,t),l(e,ye,t),u($,e,t),l(e,xe,t),u(g,e,t),l(e,ke,t),l(e,y,t),l(e,je,t),l(e,x,t),l(e,ve,t),l(e,k,t),l(e,Ue,t),u(j,e,t),l(e,be,t),l(e,v,t),l(e,He,t),u(U,e,t),l(e,Ie,t),l(e,b,t),l(e,Ce,t),l(e,H,t),l(e,Le,t),l(e,I,t),l(e,Be,t),l(e,C,t),l(e,Ze,t),l(e,L,t),l(e,Re,t),u(B,e,t),l(e,Ee,t),l(e,Z,t),l(e,Xe,t),l(e,R,t),l(e,_e,t),l(e,E,t),l(e,Ge,t),u(X,e,t),l(e,Ae,t),l(e,_,t),l(e,Ye,t),u(G,e,t),l(e,We,t),l(e,A,t),l(e,Se,t),l(e,Y,t),l(e,qe,t),u(W,e,t),l(e,Ve,t),u(S,e,t),l(e,ze,t),u(q,e,t),l(e,Fe,t),u(V,e,t),l(e,Ne,t),l(e,z,t),l(e,Pe,t),u(F,e,t),l(e,Qe,t),l(e,N,t),l(e,De,t),l(e,M,t),f(M,P),f(P,de),f(P,ft),u(Q,P,null),f(M,Tt),f(M,D),f(D,he),f(D,Jt),u(O,D,null),f(M,wt),f(M,Me),f(M,$t),f(M,fe),l(e,Oe,t),u(K,e,t),l(e,Ke,t),l(e,ee,t),l(e,et,t),l(e,te,t),l(e,tt,t),l(e,ne,t),l(e,nt,t),u(le,e,t),l(e,lt,t),l(e,se,t),l(e,st,t),l(e,ie,t),l(e,it,t),l(e,ae,t),l(e,at,t),l(e,oe,t),l(e,ot,t),u(re,e,t),l(e,rt,t),l(e,pe,t),l(e,pt,t),u(ce,e,t),l(e,ct,t),u(ue,e,t),l(e,ut,t),u(me,e,t),l(e,mt,t),l(e,we,t),dt=!0},p:Kt,i(e){dt||(m($.$$.fragment,e),m(g.$$.fragment,e),m(j.$$.fragment,e),m(U.$$.fragment,e),m(B.$$.fragment,e),m(X.$$.fragment,e),m(G.$$.fragment,e),m(W.$$.fragment,e),m(S.$$.fragment,e),m(q.$$.fragment,e),m(V.$$.fragment,e),m(F.$$.fragment,e),m(Q.$$.fragment,e),m(O.$$.fragment,e),m(K.$$.fragment,e),m(le.$$.fragment,e),m(re.$$.fragment,e),m(ce.$$.fragment,e),m(ue.$$.fragment,e),m(me.$$.fragment,e),dt=!0)},o(e){d($.$$.fragment,e),d(g.$$.fragment,e),d(j.$$.fragment,e),d(U.$$.fragment,e),d(B.$$.fragment,e),d(X.$$.fragment,e),d(G.$$.fragment,e),d(W.$$.fragment,e),d(S.$$.fragment,e),d(q.$$.fragment,e),d(V.$$.fragment,e),d(F.$$.fragment,e),d(Q.$$.fragment,e),d(O.$$.fragment,e),d(K.$$.fragment,e),d(le.$$.fragment,e),d(re.$$.fragment,e),d(ce.$$.fragment,e),d(ue.$$.fragment,e),d(me.$$.fragment,e),dt=!1},d(e){e&&(n(ge),n(Je),n(ye),n(xe),n(ke),n(y),n(je),n(x),n(ve),n(k),n(Ue),n(be),n(v),n(He),n(Ie),n(b),n(Ce),n(H),n(Le),n(I),n(Be),n(C),n(Ze),n(L),n(Re),n(Ee),n(Z),n(Xe),n(R),n(_e),n(E),n(Ge),n(Ae),n(_),n(Ye),n(We),n(A),n(Se),n(Y),n(qe),n(Ve),n(ze),n(Fe),n(Ne),n(z),n(Pe),n(Qe),n(N),n(De),n(M),n(Oe),n(Ke),n(ee),n(et),n(te),n(tt),n(ne),n(nt),n(lt),n(se),n(st),n(ie),n(it),n(ae),n(at),n(oe),n(ot),n(rt),n(pe),n(pt),n(ct),n(ut),n(mt),n(we)),n(J),h($,e),h(g,e),h(j,e),h(U,e),h(B,e),h(X,e),h(G,e),h(W,e),h(S,e),h(q,e),h(V,e),h(F,e),h(Q),h(O),h(K,e),h(le,e),h(re,e),h(ce,e),h(ue,e),h(me,e)}}}const pn='{"title":"Authentication and Authorization","local":"authentication-and-authorization","sections":[{"title":"Token Request API Endpoints","local":"token-request-api-endpoints","sections":[{"title":"Response Format","local":"response-format","sections":[{"title":"Example Response Object","local":"example-response-object","sections":[],"depth":4}],"depth":3},{"title":"Error Handling","local":"error-handling","sections":[{"title":"HTTP Errors","local":"http-errors","sections":[],"depth":4}],"depth":3},{"title":"Implementation Example","local":"implementation-example","sections":[],"depth":3}],"depth":2},{"title":"Token Scope","local":"token-scope","sections":[],"depth":2},{"title":"Token Scope Relative to Hugging Face Hub Authentication Token","local":"token-scope-relative-to-hugging-face-hub-authentication-token","sections":[],"depth":2},{"title":"Security Considerations","local":"security-considerations","sections":[],"depth":2},{"title":"Diagram","local":"diagram","sections":[],"depth":2}],"depth":1}';function cn(gt){return en(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class fn extends tn{constructor(J){super(),nn(this,J,cn,rn,Ot,{})}}export{fn as component};

Xet Storage Details

Size:
19.9 kB
·
Xet hash:
5e33e36f2b2f918960edbb791c86917d16bd73411dec8aa65414f9213ddc71bd

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.