1import{n as G,t as F,u as O}from"./chunk-C4QdCJLp.js";import{Dn as Xt,Ir as m,Kt as Qe,Mt as O$1,Ui as zC,Xn as bI}from"./chunk-yy1P56-H.js";import{C as Id,Lt as ms,T as Ir}from"./chunk-B1jIYn5g.js";import{An as f1,at as N}from"./chunk-BbhpfZ9Z.js";import{t as r}from"./chunk-09YKW5c5.js";import{L as E,R as U$1}from"./main-OQ7FOJSC.js";var U=(()=>{class i{#t=m(bI);#s=m(U$1);#e=m(Ir);#r=m(ms);#o=new f1;createSession(t){return zC(this.#t.post(N.api+`chat/sessions`,t).pipe(Qe(()=>this.#o.next(`chat.service`))))}getSessions(t,e=20,s=0){return zC(this.#t.get(N.api+`chat/sessions`,{params:{groupId:t.toString(),limit:e.toString(),offset:s.toString()}}))}getSessionsByContext(t,e){return zC(this.#t.get(N.api+`chat/sessions/context/${t}/${e}`))}getSession(t){return zC(this.#t.get(N.api+`chat/sessions/${t}`))}getMessages(t){return zC(this.#t.get(N.api+`chat/sessions/${t}/messages`))}createAiFetch(){return(t,e)=>O(this,null,function*(){if(this.#e.mode!==`remote`)throw new Xt({status:this.#e.mode===`local`?0:401,statusText:this.#e.mode===`local`?`Local access only`:`Authentication required`});let s=new Headers(e?.headers),a=yield this.#s.getToken();if(!a)throw new Error(`auth_token_not_found`);let{identifier:y}=yield E.getId(),k=this.#r.is(`hybrid`)?(yield Id.getInfo()).version:r.version;return s.set(`ngsw-bypass`,`true`),s.set(`X-Amz-Security-Token`,a),s.set(`X-AMZ-META-VERSION`,k||``),s.set(`X-AMZ-META-UUID`,y||``),fetch(t,G(F({},e),{headers:s}))})}archiveSession(t){return zC(this.#t.delete(N.api+`chat/sessions/${t}`))}static{this.ɵfac=function(e){return new(e||i)}}static{this.ɵprov=O$1({token:i,factory:i.ɵfac,providedIn:`root`})}}return i})();export{U as t};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.