@whoz-oss/coday-client 0.145.1 → 0.147.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/browser/{chunk-VZTMSCXJ.js → chunk-27VMXNKO.js} +1 -1
- package/browser/{chunk-IJHAKS36.js → chunk-4BA742MQ.js} +1 -1
- package/browser/{chunk-BFSLBE5E.js → chunk-5FQ263AJ.js} +1 -1
- package/browser/{chunk-CPFVLY3T.js → chunk-5SMSD425.js} +1 -1
- package/browser/{chunk-KLKZMHAD.js → chunk-74QUDUXA.js} +1 -1
- package/browser/{chunk-ADQOXBBW.js → chunk-A75US5OS.js} +1 -1
- package/browser/{chunk-I7DNESMT.js → chunk-AQ7HC7RU.js} +1 -1
- package/browser/{chunk-VQHYAE3Z.js → chunk-DK7CV3ER.js} +1 -1
- package/browser/{chunk-E3JFJFIJ.js → chunk-FH7GLF4A.js} +1 -1
- package/browser/{chunk-FQHQCCYN.js → chunk-FVTEJ3CC.js} +1 -1
- package/browser/chunk-FXEVP5EI.js +1 -0
- package/browser/{chunk-6AOSL3EI.js → chunk-GFM6GNN4.js} +1 -1
- package/browser/{chunk-VUMSWC3G.js → chunk-GHZFCBZI.js} +1 -1
- package/browser/{chunk-EFRFG6GO.js → chunk-IBOCXMQ4.js} +1 -1
- package/browser/{chunk-IDDQUVUO.js → chunk-K3JZBQNI.js} +1 -1
- package/browser/{chunk-6MYFTPPD.js → chunk-KDWFOH5N.js} +1 -1
- package/browser/{chunk-FASC6WKR.js → chunk-M6PPDBCV.js} +1 -1
- package/browser/{chunk-57LCJDBW.js → chunk-MFP22ZDH.js} +1 -1
- package/browser/{chunk-LJOYPBE3.js → chunk-MPWUESX7.js} +1 -1
- package/browser/{chunk-YUXJIFVV.js → chunk-MW254KMZ.js} +1 -1
- package/browser/{chunk-GGNCDOF3.js → chunk-NEH5OLEF.js} +1 -1
- package/browser/{chunk-G6MC26UY.js → chunk-POUIHGLE.js} +1 -1
- package/browser/{chunk-OHT3DAE2.js → chunk-QBQFRY6E.js} +1 -1
- package/browser/{chunk-PKGUR3OJ.js → chunk-R4YBTA4J.js} +1 -1
- package/browser/{chunk-KM7CQJ3E.js → chunk-TIUJWVDI.js} +1 -1
- package/browser/{chunk-IEGDP7IZ.js → chunk-WXOL2LXZ.js} +1 -1
- package/browser/{chunk-PUJBA6OY.js → chunk-X6SZS62E.js} +1 -1
- package/browser/{chunk-UCQMPA3P.js → chunk-XNTXJPF5.js} +1 -1
- package/browser/{chunk-MMPI6RMV.js → chunk-ZFS375I4.js} +1 -1
- package/browser/index.html +1 -1
- package/browser/{main-ADK3DSZE.js → main-3P5CH7OO.js} +1 -1
- package/package.json +1 -1
- package/browser/chunk-J65IZXMJ.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Pc as z,Qc as u,Rc as Q,Sc as j,Z as A,a as b,aa as k,b as f,ba as x,ca as O,da as L,g as D,pa as K}from"./chunk-QPN22TF2.js";var y=class{apiKeys;username;password;accessToken;basePath;withCredentials;encoder;encodeParam;credentials;constructor({accessToken:h,apiKeys:n,basePath:a,credentials:i,encodeParam:r,encoder:t,password:e,username:p,withCredentials:d}={}){n&&(this.apiKeys=n),p!==void 0&&(this.username=p),e!==void 0&&(this.password=e),h!==void 0&&(this.accessToken=h),a!==void 0&&(this.basePath=a),d!==void 0&&(this.withCredentials=d),t&&(this.encoder=t),this.encodeParam=r??(o=>this.defaultEncodeParam(o)),this.credentials=i??{}}selectHeaderContentType(h){if(h.length===0)return;let n=h.find(a=>this.isJsonMime(a));return n===void 0?h[0]:n}selectHeaderAccept(h){if(h.length===0)return;let n=h.find(a=>this.isJsonMime(a));return n===void 0?h[0]:n}isJsonMime(h){let n=new RegExp("^(application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(;.*)?$","i");return h!==null&&(n.test(h)||h.toLowerCase()==="application/json-patch+json")}lookupCredential(h){let n=this.credentials[h];return typeof n=="function"?n():n}addCredentialToHeaders(h,n,a,i){let r=this.lookupCredential(h);return r?a.set(n,(i??"")+r):a}addCredentialToQuery(h,n,a){let i=this.lookupCredential(h);return i?a.set(n,i):a}defaultEncodeParam(h){let n=h.dataFormat==="date-time"&&h.value instanceof Date?h.value.toISOString():h.value;return encodeURIComponent(String(n))}};var v=new k("basePath");var V=class{encodeKey(h){return encodeURIComponent(h)}encodeValue(h){return encodeURIComponent(h)}decodeKey(h){return decodeURIComponent(h)}decodeValue(h){return decodeURIComponent(h)}};var m=class{basePath="http://localhost:8124";defaultHeaders=new z;configuration;encoder;constructor(h,n){if(this.configuration=n||new y,typeof this.configuration.basePath!="string"){let a=Array.isArray(h)?h[0]:void 0;a!=null&&(h=a),typeof h!="string"&&(h=this.basePath),this.configuration.basePath=h}this.encoder=this.configuration.encoder||new V}canConsumeForm(h){return h.indexOf("multipart/form-data")!==-1}addToHttpParams(h,n,a,i=!1){return typeof n=="object"&&!(n instanceof Date)?this.addToHttpParamsRecursive(h,n,i?a:void 0,i):this.addToHttpParamsRecursive(h,n,a)}addToHttpParamsRecursive(h,n,a,i=!1){if(n==null)return h;if(typeof n=="object"){if(a!=null)return i?Object.keys(n).reduce((r,t)=>r.append(`${a}[${t}]`,n[t]),h):h.append(a,JSON.stringify(n));if(Array.isArray(n))n.forEach(r=>h=this.addToHttpParamsRecursive(h,r,a));else if(n instanceof Date)if(a!=null)h=h.append(a,n.toISOString());else throw Error("key may not be null if value is Date");else Object.keys(n).forEach(r=>{let t=a?`${a}.${r}`:r;h=this.addToHttpParamsRecursive(h,n[r],t)});return h}else if(a!=null)return h.append(a,n);throw Error("key may not be null if value is not object or array")}};var R=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter agentConfig was null or undefined when calling createAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/agent-configs",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/agent-configs/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/agent-configs/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateAgentConfig(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAgentConfig.");if(a==null)throw new Error("Required parameter agentConfig was null or undefined when calling updateAgentConfig.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var E=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter aiModel was null or undefined when calling createAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-models",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-models/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByNamespaceIdAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listByNamespaceIdAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/by-namespaceId/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateAiModel(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAiModel.");if(a==null)throw new Error("Required parameter aiModel was null or undefined when calling updateAiModel.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var $=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter aiProvider was null or undefined when calling createAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-providers",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-providers/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByNamespaceIdAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listByNamespaceIdAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/by-namespaceId/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByUserIdAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userId was null or undefined when calling listByUserIdAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/by-userId/${this.configuration.encodeParam({name:"userId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateAiProvider(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAiProvider.");if(a==null)throw new Error("Required parameter aiProvider was null or undefined when calling updateAiProvider.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var M=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}addMessageCase(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling addMessageCase.");if(a==null)throw new Error("Required parameter addMessageRequest was null or undefined when calling addMessageCase.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/messages`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("post",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}createCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter _case was null or undefined when calling createCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/cases",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/cases/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}interruptCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling interruptCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/interrupt`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}killCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling killCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/kill`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateCase(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateCase.");if(a==null)throw new Error("Required parameter _case was null or undefined when calling updateCase.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var B=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter integrationConfig was null or undefined when calling createIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/integration-configs",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/integration-configs/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-configs/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateIntegrationConfig(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateIntegrationConfig.");if(a==null)throw new Error("Required parameter integrationConfig was null or undefined when calling updateIntegrationConfig.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var q=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}getTypeIntegrationType(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter type was null or undefined when calling getTypeIntegrationType.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-types/${this.configuration.encodeParam({name:"type",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listTypesIntegrationType(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/integration-types",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var U=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespace was null or undefined when calling createNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/namespaces",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/namespaces/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listAllNamespace(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/namespaces",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}listByParentNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateNamespace(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateNamespace.");if(a==null)throw new Error("Required parameter namespace was null or undefined when calling updateNamespace.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var Y=(a=>(a.OpenAI="OpenAI",a.Anthropic="Anthropic",a.Gemini="Gemini",a))(Y||{});var S=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}getByIdCaseEventRest(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdCaseEventRest.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/case-events/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsCaseEventRest(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsCaseEventRest.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/case-events/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByCaseCaseEventRest(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling listByCaseCaseEventRest.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/case-events/by-parentId/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var N=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}grantAdmin(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling grantAdmin.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling grantAdmin.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/admins/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("put",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}grantMember(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling grantMember.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling grantMember.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/members/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("put",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}listNamespaceUsers(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listNamespaceUsers.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/users`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}revokeAdmin(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling revokeAdmin.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling revokeAdmin.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/admins/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("delete",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}revokeMember(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling revokeMember.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling revokeMember.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/members/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("delete",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var G=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}debugAllPlugins(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins/debug",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}debugPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling debugPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/debug`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getAllPlugins(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}getPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling getPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}reloadAllAgentsPlugin(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins/reload-agents",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("post",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}reloadPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling reloadPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/reload`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}startPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling startPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/start`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}stopPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling stopPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/stop`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}unloadPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling unloadPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}uploadPlugin(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins/upload",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("post",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var J=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}streamEventsCaseEventSse(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling streamEventsCaseEventSse.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["text/event-stream"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/events`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var W=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter user was null or undefined when calling createUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/users",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/users/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getGroupsByExternalIdsUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getGroupsByExternalIdsUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/users/groups-by-external-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getMeUser(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/users/me",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}listAllUser(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/users",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}listByParentUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/users/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateUser(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateUser.");if(a==null)throw new Error("Required parameter user was null or undefined when calling updateUser.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var F=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userGroupCreateRequest was null or undefined when calling createUserGroup.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/user-groups",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userGroupId was null or undefined when calling deleteUserGroup.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/user-groups/${this.configuration.encodeParam({name:"userGroupId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userGroupId was null or undefined when calling getByIdUserGroup.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/user-groups/${this.configuration.encodeParam({name:"userGroupId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}searchByNamespaceExternalIdUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceExternalId was null or undefined when calling searchByNamespaceExternalIdUserGroup.");let t=new Q({encoder:this.encoder});t=this.addToHttpParams(t,n,"namespaceExternalId");let e=this.defaultHeaders,p=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=r?.context??new u,o=r?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s="/api/user-groups",{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("get",`${c}${s}`,f(b({context:d,params:t,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:a,transferCache:o,reportProgress:i}))}updateUserGroup(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter userGroupId was null or undefined when calling updateUserGroup.");if(a==null)throw new Error("Required parameter userGroupUpdateRequest was null or undefined when calling updateUserGroup.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/user-groups/${this.configuration.encodeParam({name:"userGroupId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("post",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};function $r(H){return L([typeof H=="string"?{provide:v,useValue:H}:{provide:y,useValue:new y(b({},H))}])}var _=class H{config=O(y);zone=O(K);connect(h){let n=`${this.config.basePath}/api/cases/${h}/events`;return new D(a=>{let i=this.zone.runOutsideAngular(()=>new EventSource(n));return i.onmessage=r=>{try{let t=JSON.parse(r.data);this.zone.run(()=>a.next(t))}catch(t){this.zone.run(()=>a.error(new Error(`Failed to parse SSE event: ${t}`)))}},i.onerror=r=>{i.readyState===EventSource.CLOSED?this.zone.run(()=>a.complete()):this.zone.run(()=>a.error(new Error(`SSE connection error for case ${h}`))),i.close()},()=>i.close()})}static \u0275fac=function(n){return new(n||H)};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};export{y as a,R as b,E as c,$ as d,M as e,B as f,q as g,U as h,G as i,W as j,Y as k,$r as l};
|
|
1
|
+
import{Pc as Q,Qc as u,Rc as V,Sc as j,Z as A,a as b,aa as L,b as f,ba as x,ca as R,da as K,g as k,pa as z}from"./chunk-QPN22TF2.js";var y=class{apiKeys;username;password;accessToken;basePath;withCredentials;encoder;encodeParam;credentials;constructor({accessToken:h,apiKeys:n,basePath:a,credentials:i,encodeParam:r,encoder:t,password:e,username:p,withCredentials:d}={}){n&&(this.apiKeys=n),p!==void 0&&(this.username=p),e!==void 0&&(this.password=e),h!==void 0&&(this.accessToken=h),a!==void 0&&(this.basePath=a),d!==void 0&&(this.withCredentials=d),t&&(this.encoder=t),this.encodeParam=r??(o=>this.defaultEncodeParam(o)),this.credentials=i??{}}selectHeaderContentType(h){if(h.length===0)return;let n=h.find(a=>this.isJsonMime(a));return n===void 0?h[0]:n}selectHeaderAccept(h){if(h.length===0)return;let n=h.find(a=>this.isJsonMime(a));return n===void 0?h[0]:n}isJsonMime(h){let n=new RegExp("^(application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(;.*)?$","i");return h!==null&&(n.test(h)||h.toLowerCase()==="application/json-patch+json")}lookupCredential(h){let n=this.credentials[h];return typeof n=="function"?n():n}addCredentialToHeaders(h,n,a,i){let r=this.lookupCredential(h);return r?a.set(n,(i??"")+r):a}addCredentialToQuery(h,n,a){let i=this.lookupCredential(h);return i?a.set(n,i):a}defaultEncodeParam(h){let n=h.dataFormat==="date-time"&&h.value instanceof Date?h.value.toISOString():h.value;return encodeURIComponent(String(n))}};var v=new L("basePath");var O=class{encodeKey(h){return encodeURIComponent(h)}encodeValue(h){return encodeURIComponent(h)}decodeKey(h){return decodeURIComponent(h)}decodeValue(h){return decodeURIComponent(h)}};var m=class{basePath="http://localhost:8124";defaultHeaders=new Q;configuration;encoder;constructor(h,n){if(this.configuration=n||new y,typeof this.configuration.basePath!="string"){let a=Array.isArray(h)?h[0]:void 0;a!=null&&(h=a),typeof h!="string"&&(h=this.basePath),this.configuration.basePath=h}this.encoder=this.configuration.encoder||new O}canConsumeForm(h){return h.indexOf("multipart/form-data")!==-1}addToHttpParams(h,n,a,i=!1){return typeof n=="object"&&!(n instanceof Date)?this.addToHttpParamsRecursive(h,n,i?a:void 0,i):this.addToHttpParamsRecursive(h,n,a)}addToHttpParamsRecursive(h,n,a,i=!1){if(n==null)return h;if(typeof n=="object"){if(a!=null)return i?Object.keys(n).reduce((r,t)=>r.append(`${a}[${t}]`,n[t]),h):h.append(a,JSON.stringify(n));if(Array.isArray(n))n.forEach(r=>h=this.addToHttpParamsRecursive(h,r,a));else if(n instanceof Date)if(a!=null)h=h.append(a,n.toISOString());else throw Error("key may not be null if value is Date");else Object.keys(n).forEach(r=>{let t=a?`${a}.${r}`:r;h=this.addToHttpParamsRecursive(h,n[r],t)});return h}else if(a!=null)return h.append(a,n);throw Error("key may not be null if value is not object or array")}};var E=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter agentConfig was null or undefined when calling createAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/agent-configs",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/agent-configs/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentAgentConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAgentConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/agent-configs/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateAgentConfig(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAgentConfig.");if(a==null)throw new Error("Required parameter agentConfig was null or undefined when calling updateAgentConfig.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var $=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter aiModel was null or undefined when calling createAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-models",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-models/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByNamespaceIdAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listByNamespaceIdAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/by-namespaceId/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentAiModel(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAiModel.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-models/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateAiModel(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAiModel.");if(a==null)throw new Error("Required parameter aiModel was null or undefined when calling updateAiModel.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var B=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter aiProvider was null or undefined when calling createAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-providers",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/ai-providers/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByNamespaceIdAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listByNamespaceIdAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/by-namespaceId/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByUserIdAiProvider(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userId was null or undefined when calling listByUserIdAiProvider.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/ai-providers/by-userId/${this.configuration.encodeParam({name:"userId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateAiProvider(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAiProvider.");if(a==null)throw new Error("Required parameter aiProvider was null or undefined when calling updateAiProvider.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var M=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}addMessageCase(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling addMessageCase.");if(a==null)throw new Error("Required parameter addMessageRequest was null or undefined when calling addMessageCase.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/messages`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("post",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}createCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter _case was null or undefined when calling createCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/cases",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/cases/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}interruptCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling interruptCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/interrupt`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}killCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling killCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/kill`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentCase(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentCase.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/cases/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateCase(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateCase.");if(a==null)throw new Error("Required parameter _case was null or undefined when calling updateCase.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var q=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter integrationConfig was null or undefined when calling createIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/integration-configs",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/integration-configs/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentIntegrationConfig(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentIntegrationConfig.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-configs/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateIntegrationConfig(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateIntegrationConfig.");if(a==null)throw new Error("Required parameter integrationConfig was null or undefined when calling updateIntegrationConfig.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var U=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}getTypeIntegrationType(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter type was null or undefined when calling getTypeIntegrationType.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/integration-types/${this.configuration.encodeParam({name:"type",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listTypesIntegrationType(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/integration-types",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var S=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespace was null or undefined when calling createNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/namespaces",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/namespaces/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listAllNamespace(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/namespaces",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}listByExternalIdsNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling listByExternalIdsNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/namespaces/by-external-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByParentNamespace(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentNamespace.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateNamespace(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateNamespace.");if(a==null)throw new Error("Required parameter namespace was null or undefined when calling updateNamespace.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var Y=(i=>(i.OpenAI="OpenAI",i.Anthropic="Anthropic",i.Gemini="Gemini",i.vLLM="vLLM",i))(Y||{});var N=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}getByIdCaseEventRest(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdCaseEventRest.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/case-events/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsCaseEventRest(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsCaseEventRest.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/case-events/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}listByCaseCaseEventRest(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling listByCaseCaseEventRest.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/case-events/by-parentId/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var G=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}grantAdmin(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling grantAdmin.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling grantAdmin.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/admins/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("put",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}grantMember(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling grantMember.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling grantMember.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/members/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("put",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}listNamespaceUsers(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listNamespaceUsers.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/users`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}revokeAdmin(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling revokeAdmin.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling revokeAdmin.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/admins/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("delete",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}revokeMember(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling revokeMember.");if(a==null)throw new Error("Required parameter targetUserId was null or undefined when calling revokeMember.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s=`/api/namespaces/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/members/${this.configuration.encodeParam({name:"targetUserId",value:a,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("delete",`${c}${s}`,f(b({context:d,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var J=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}debugAllPlugins(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins/debug",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}debugPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling debugPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/debug`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getAllPlugins(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}getPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling getPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}reloadAllAgentsPlugin(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins/reload-agents",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("post",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}reloadPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling reloadPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/reload`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}startPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling startPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/start`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}stopPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling stopPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/stop`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("post",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}unloadPlugin(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling unloadPlugin.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}uploadPlugin(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/plugins/upload",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("post",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var W=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}streamEventsCaseEventSse(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling streamEventsCaseEventSse.");let e=new V({encoder:this.encoder});e=this.addToHttpParams(e,a,"live");let p=this.defaultHeaders,d=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["text/event-stream"]);d!==void 0&&(p=p.set("Accept",d));let o=t?.context??new u,l=t?.transferCache??!0,s="json";d&&(d.startsWith("text")?s="text":this.configuration.isJsonMime(d)?s="json":s="blob");let c=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/events`,{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("get",`${C}${c}`,f(b({context:o,params:e,responseType:s},g?{withCredentials:g}:{}),{headers:p,observe:i,transferCache:l,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var F=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter user was null or undefined when calling createUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/users",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdsUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/users/by-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getGroupsByExternalIdsUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getGroupsByExternalIdsUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/users/groups-by-external-ids",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getMeUser(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/users/me",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}listAllUser(n="body",a=!1,i){let r=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(r=r.set("Accept",t));let e=i?.context??new u,p=i?.transferCache??!0,d="json";t&&(t.startsWith("text")?d="text":this.configuration.isJsonMime(t)?d="json":d="blob");let o="/api/users",{basePath:l,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${l}${o}`,f(b({context:e,responseType:d},s?{withCredentials:s}:{}),{headers:r,observe:n,transferCache:p,reportProgress:a}))}listByParentUser(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentUser.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/users/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}updateUser(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateUser.");if(a==null)throw new Error("Required parameter user was null or undefined when calling updateUser.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};var _=class H extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userGroupCreateRequest was null or undefined when calling createUserGroup.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o=["application/json"],l=this.configuration.selectHeaderContentType(o);l!==void 0&&(t=t.set("Content-Type",l));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let c="/api/user-groups",{basePath:C,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${C}${c}`,f(b({context:p,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}deleteUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userGroupId was null or undefined when calling deleteUserGroup.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/user-groups/${this.configuration.encodeParam({name:"userGroupId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("delete",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}getByIdUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter userGroupId was null or undefined when calling getByIdUserGroup.");let t=this.defaultHeaders,e=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let p=r?.context??new u,d=r?.transferCache??!0,o="json";e&&(e.startsWith("text")?o="text":this.configuration.isJsonMime(e)?o="json":o="blob");let l=`/api/user-groups/${this.configuration.encodeParam({name:"userGroupId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:c}=this.configuration;return this.httpClient.request("get",`${s}${l}`,f(b({context:p,responseType:o},c?{withCredentials:c}:{}),{headers:t,observe:a,transferCache:d,reportProgress:i}))}searchByNamespaceExternalIdUserGroup(n,a="body",i=!1,r){if(n==null)throw new Error("Required parameter namespaceExternalId was null or undefined when calling searchByNamespaceExternalIdUserGroup.");let t=new V({encoder:this.encoder});t=this.addToHttpParams(t,n,"namespaceExternalId");let e=this.defaultHeaders,p=r?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=r?.context??new u,o=r?.transferCache??!0,l="json";p&&(p.startsWith("text")?l="text":this.configuration.isJsonMime(p)?l="json":l="blob");let s="/api/user-groups",{basePath:c,withCredentials:C}=this.configuration;return this.httpClient.request("get",`${c}${s}`,f(b({context:d,params:t,responseType:l},C?{withCredentials:C}:{}),{headers:e,observe:a,transferCache:o,reportProgress:i}))}updateUserGroup(n,a,i="body",r=!1,t){if(n==null)throw new Error("Required parameter userGroupId was null or undefined when calling updateUserGroup.");if(a==null)throw new Error("Required parameter userGroupUpdateRequest was null or undefined when calling updateUserGroup.");let e=this.defaultHeaders,p=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);p!==void 0&&(e=e.set("Accept",p));let d=t?.context??new u,o=t?.transferCache??!0,l=["application/json"],s=this.configuration.selectHeaderContentType(l);s!==void 0&&(e=e.set("Content-Type",s));let c="json";p&&(p.startsWith("text")?c="text":this.configuration.isJsonMime(p)?c="json":c="blob");let C=`/api/user-groups/${this.configuration.encodeParam({name:"userGroupId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("post",`${g}${C}`,f(b({context:d,body:a,responseType:c},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:o,reportProgress:r}))}static \u0275fac=function(a){return new(a||H)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};function $r(H){return K([typeof H=="string"?{provide:v,useValue:H}:{provide:y,useValue:new y(b({},H))}])}var D=class H{config=R(y);zone=R(z);connect(h){let n=`${this.config.basePath}/api/cases/${h}/events`;return new k(a=>{let i=this.zone.runOutsideAngular(()=>new EventSource(n));return i.onmessage=r=>{try{let t=JSON.parse(r.data);this.zone.run(()=>a.next(t))}catch(t){this.zone.run(()=>a.error(new Error(`Failed to parse SSE event: ${t}`)))}},i.onerror=r=>{i.readyState===EventSource.CLOSED?this.zone.run(()=>a.complete()):this.zone.run(()=>a.error(new Error(`SSE connection error for case ${h}`))),i.close()},()=>i.close()})}static \u0275fac=function(n){return new(n||H)};static \u0275prov=A({token:H,factory:H.\u0275fac,providedIn:"root"})};export{y as a,E as b,$ as c,B as d,M as e,q as f,U as g,S as h,J as i,F as j,Y as k,$r as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as B}from"./chunk-
|
|
1
|
+
import{b as B}from"./chunk-NEH5OLEF.js";import{b as q,d as v}from"./chunk-UARV2YUR.js";import{p as $,u as z,v as F}from"./chunk-WER6464F.js";import"./chunk-7YDOHTEK.js";import{a as I}from"./chunk-UCFKZZMU.js";import"./chunk-2GHS5VUE.js";import"./chunk-DYANOPHQ.js";import"./chunk-N5UH5PRX.js";import"./chunk-4YLSQZJK.js";import{Bb as u,Db as s,Fb as c,Hc as V,Ka as g,Pb as R,S as M,Tb as l,Ub as y,Wa as b,ab as P,ac as S,ca as m,dc as T,ec as N,ga as d,ha as p,hc as O,i as w,lb as f,ma as k,mb as _,oa as D,rb as C,sb as a,t as A,ta as E,tb as r}from"./chunk-QPN22TF2.js";function U(t,n){if(t&1&&(a(0,"span",3),l(1),r()),t&2){let e=c();g(),y(e.config.modelName)}}function W(t,n){if(t&1&&(a(0,"span",4),l(1),r()),t&2){let e=c();g(),y(e.config.description)}}function G(t,n){if(t&1){let e=u();a(0,"span",7),l(1,"Delete?"),r(),a(2,"ds-icon-button",8),s("action",function(){d(e);let o=c();return p(o.onDeleteConfirmed())}),r(),a(3,"ds-icon-button",9),s("action",function(){d(e);let o=c();return p(o.onDeleteCancelled())}),r()}}function H(t,n){if(t&1){let e=u();a(0,"ds-kebab-menu",10),s("itemSelected",function(o){d(e);let x=c();return p(x.onMenuAction(o))}),r()}if(t&2){let e=c();C("items",e.menuItems)}}var h=class t{router=m(v);config;namespaceId;deleteRequested=new D;pendingDelete=E(!1);menuItems=[{key:"edit",label:"Edit agent config",icon:"edit"},{key:"delete",label:"Delete agent config",icon:"delete",variant:"danger"}];onMenuAction(n){switch(n){case"edit":this.router.navigate(["/agentos",this.namespaceId,"agent-configs",this.config.id,"edit"]);break;case"delete":this.pendingDelete.set(!0);break}}onDeleteConfirmed(){this.pendingDelete.set(!1),this.deleteRequested.emit(this.config)}onDeleteCancelled(){this.pendingDelete.set(!1)}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=b({type:t,selectors:[["agentos-agent-config-item"]],inputs:{config:"config",namespaceId:"namespaceId"},outputs:{deleteRequested:"deleteRequested"},decls:9,vars:4,consts:[["role","listitem",1,"agent-config-item"],[1,"agent-config-item__body"],[1,"agent-config-item__name"],[1,"agent-config-item__model"],[1,"agent-config-item__description"],[1,"agent-config-item__actions"],[3,"items"],[1,"agent-config-item__confirm-label"],["icon","check","variant","danger","title","Confirm deletion",3,"action"],["icon","close","title","Cancel deletion",3,"action"],[3,"itemSelected","items"]],template:function(e,i){e&1&&(a(0,"div",0)(1,"div",1)(2,"span",2),l(3),r(),f(4,U,2,1,"span",3),f(5,W,2,1,"span",4),r(),a(6,"div",5),f(7,G,4,0)(8,H,1,1,"ds-kebab-menu",6),r()()),e&2&&(g(3),y(i.config.name),g(),_(i.config.modelName?4:-1),g(),_(i.config.description?5:-1),g(2),_(i.pendingDelete()?7:8))},dependencies:[F,$],styles:[".agent-config-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:.75rem 1rem;border-radius:10px;border:1px solid var(--color-border, rgba(0, 0, 0, .08));background:var(--glass-bg, rgba(255, 255, 255, .72));-webkit-backdrop-filter:var(--glass-backdrop-blur, blur(20px));backdrop-filter:var(--glass-backdrop-blur, blur(20px));transition:background .15s ease,border-color .15s ease}.agent-config-item[_ngcontent-%COMP%]:hover{background:var(--color-bg-hover, rgba(0, 0, 0, .04));border-color:var(--color-primary, #007aff)}.agent-config-item__body[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;gap:.2rem;min-width:0}.agent-config-item__name[_ngcontent-%COMP%]{font-size:.95rem;font-weight:500;color:var(--color-text, #1d1d1f);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.agent-config-item__model[_ngcontent-%COMP%]{font-size:.78rem;color:var(--color-text-secondary, #6e6e73);font-family:monospace;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.agent-config-item__description[_ngcontent-%COMP%]{font-size:.75rem;color:var(--color-text-secondary, #6e6e73);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.agent-config-item__actions[_ngcontent-%COMP%]{flex-shrink:0;display:flex;align-items:center;gap:.125rem;opacity:0;transition:opacity .15s ease}.agent-config-item[_ngcontent-%COMP%]:hover .agent-config-item__actions[_ngcontent-%COMP%], .agent-config-item[_ngcontent-%COMP%]:focus-within .agent-config-item__actions[_ngcontent-%COMP%]{opacity:1}.agent-config-item__confirm-label[_ngcontent-%COMP%]{font-size:.8rem;font-weight:500;color:var(--color-error, #ff3b30);margin-right:.25rem;white-space:nowrap}"],changeDetection:0})};var J=()=>[];function Q(t,n){if(t&1){let e=u();a(0,"agentos-agent-config-item",4),s("deleteRequested",function(o){d(e);let x=c(2);return p(x.deleteConfig(o))}),r()}if(t&2){let e=c(2);C("config",n)("namespaceId",e.namespaceId)}}function X(t,n){if(t&1&&f(0,Q,1,2,"agentos-agent-config-item",3),t&2){let e,i=n.$implicit,o=c();_((e=o.resolveConfig(i.id))?0:-1,e)}}var j=class t{route=m(q);router=m(v);destroyRef=m(k);agentConfigController=m(B);namespaceId=this.route.snapshot.params.namespaceId;refresh$=new w(void 0);configs$=this.refresh$.pipe(M(()=>this.agentConfigController.listByParentAgentConfig(this.namespaceId)));configItems$=this.configs$.pipe(A(n=>n.map(e=>({id:e.id??"",name:e.name,description:e.description}))));configsById=new Map;constructor(){this.configs$.pipe(I(this.destroyRef)).subscribe(n=>{this.configsById=new Map(n.map(e=>[e.id??"",e]))})}goBack(){this.router.navigate(["/agentos","namespaces"])}openCreateForm(){this.router.navigate(["/agentos",this.namespaceId,"agent-configs","new"])}deleteConfig(n){this.agentConfigController.deleteAgentConfig(n.id??"").pipe(I(this.destroyRef)).subscribe(()=>this.refresh$.next())}resolveConfig(n){return this.configsById.get(n)??null}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=b({type:t,selectors:[["agentos-namespace-agent-configs"]],decls:6,vars:6,consts:[["agentConfigItemTpl",""],["title","Agent Configs","emptyMessage","No agent configs defined yet. Add one above.","cardMinWidth","400px",3,"createRequested","items","showCreate","itemTemplate"],["toolbar-start","","type","button",1,"namespace-agent-configs__back",3,"click"],[3,"config","namespaceId"],[3,"deleteRequested","config","namespaceId"]],template:function(e,i){if(e&1&&(a(0,"ds-entity-list",1),T(1,"async"),s("createRequested",function(){return i.openCreateForm()}),a(2,"button",2),s("click",function(){return i.goBack()}),l(3," \u2190 Namespaces "),r()(),P(4,X,1,1,"ng-template",null,0,O)),e&2){let o=R(5);C("items",N(1,3,i.configItems$)??S(5,J))("showCreate",!0)("itemTemplate",o)}},dependencies:[z,h,V],styles:[".namespace-agent-configs__back[_ngcontent-%COMP%]{background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;color:var(--color-primary, #007aff);font-family:inherit}.namespace-agent-configs__back[_ngcontent-%COMP%]:hover{text-decoration:underline}"],changeDetection:0})};export{j as NamespaceAgentConfigsComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as m}from"./chunk-
|
|
1
|
+
import{b as m}from"./chunk-R4YBTA4J.js";import{c as l}from"./chunk-UARV2YUR.js";import{Wa as a,sb as t,tb as i,ub as o}from"./chunk-QPN22TF2.js";var s=class n{static \u0275fac=function(e){return new(e||n)};static \u0275cmp=a({type:n,selectors:[["agentos-layout"]],decls:4,vars:0,consts:[[1,"layout"],[1,"layout__content"]],template:function(e,u){e&1&&(t(0,"div",0),o(1,"agentos-header"),t(2,"main",1),o(3,"router-outlet"),i()())},dependencies:[l,m],styles:[".layout[_ngcontent-%COMP%]{display:flex;flex-direction:column;min-height:100vh}.layout__content[_ngcontent-%COMP%]{flex:1;overflow-y:auto}"]})};export{s as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as w}from"./chunk-
|
|
1
|
+
import{a as w}from"./chunk-GHZFCBZI.js";import{i as M}from"./chunk-NEH5OLEF.js";import{d as O}from"./chunk-UARV2YUR.js";import{a as S}from"./chunk-UCFKZZMU.js";import{Db as u,Fb as k,Ka as a,Rb as x,Tb as l,Ub as P,Wa as d,ca as i,lb as p,ma as f,mb as m,rb as v,sb as r,ta as h,tb as s,ub as b,vb as y,wb as C,xb as g}from"./chunk-QPN22TF2.js";function H(e,t){e&1&&g(0,"span",1)}function D(e,t){e&1&&g(0,"span",2)}function B(e,t){e&1&&g(0,"span",3)}var _=class e{pluginService=i(M);online=h(null);ngOnInit(){this.pluginService.getAllPlugins().subscribe({next:()=>this.online.set(!0),error:()=>this.online.set(!1)})}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=d({type:e,selectors:[["agentos-backend-status"]],decls:4,vars:1,consts:[[1,"backend-status"],["title","AgentOS online",1,"dot","dot--online"],["title","AgentOS offline",1,"dot","dot--offline"],["title","Checking\u2026",1,"dot","dot--checking"]],template:function(n,o){if(n&1&&(y(0,"div",0),p(1,H,1,0,"span",1)(2,D,1,0,"span",2)(3,B,1,0,"span",3),C()),n&2){let c;a(),m((c=o.online())===!0?1:c===!1?2:3)}},styles:[".backend-status[_ngcontent-%COMP%]{display:flex;align-items:center}.dot[_ngcontent-%COMP%]{width:8px;height:8px;border-radius:50%;flex-shrink:0}.dot--online[_ngcontent-%COMP%]{background:var(--color-success, #34c759)}.dot--offline[_ngcontent-%COMP%]{background:var(--color-error, #ff3b30)}.dot--checking[_ngcontent-%COMP%]{background:var(--color-text-secondary, #6e6e73);opacity:.5;animation:_ngcontent-%COMP%_pulse 1.2s ease-in-out infinite}@keyframes _ngcontent-%COMP%_pulse{0%,to{opacity:.5}50%{opacity:1}}"]})};function U(e,t){if(e&1&&(r(0,"span",8),l(1),s()),e&2){let n=k();a(),P(n.userInitials)}}function A(e,t){e&1&&(r(0,"span",9),l(1,"\u25EF"),s())}var E=class e{router=i(O);userState=i(w);destroyRef=i(f);currentUser=this.userState.currentUser;navigateHome(){this.router.navigate(["/agentos"])}navigateToAdmin(){this.router.navigate(["/agentos/admin/users"])}ngOnInit(){this.currentUser()||this.userState.loadMe().pipe(S(this.destroyRef)).subscribe()}get userInitials(){let t=this.currentUser();if(!t)return"";let n=t.firstname?.[0]??"",o=t.lastname?.[0]??"";return(n+o).toUpperCase()||t.email?.[0]?.toUpperCase()||"?"}get isOnProfilePage(){return this.router.url.startsWith("/agentos/me")}toggleProfile(){this.isOnProfilePage?window.history.length>1?window.history.back():this.router.navigate(["/agentos"]):this.router.navigate(["/agentos/me"])}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=d({type:e,selectors:[["agentos-header"]],decls:13,vars:4,consts:[[1,"header"],["type","button","title","Home",1,"header__brand",3,"click"],["src","CODAY-Logo.png","alt","Coday",1,"header__logo-img"],[1,"header__logo-text"],[1,"header__nav"],["type","button","title","Admin",1,"header__admin-btn",3,"click"],[1,"header__admin-icon"],["type","button",1,"header__user-btn",3,"click","title"],[1,"header__user-initials"],[1,"header__user-icon"]],template:function(n,o){n&1&&(r(0,"header",0)(1,"button",1),u("click",function(){return o.navigateHome()}),b(2,"img",2),r(3,"span",3),l(4,"Coday"),s()(),r(5,"nav",4),b(6,"agentos-backend-status"),r(7,"button",5),u("click",function(){return o.navigateToAdmin()}),r(8,"span",6),l(9,"\u2699\uFE0F"),s()(),r(10,"button",7),u("click",function(){return o.toggleProfile()}),p(11,U,2,1,"span",8)(12,A,2,0,"span",9),s()()()),n&2&&(a(10),x("header__user-btn--active",o.isOnProfilePage),v("title",o.isOnProfilePage?"Back":"My profile"),a(),m(o.userInitials?11:12))},dependencies:[_],styles:[".header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:0 1.5rem;height:56px;background:var(--glass-bg, rgba(255, 255, 255, .72));border-bottom:1px solid var(--glass-border, rgba(255, 255, 255, .18));backdrop-filter:var(--glass-backdrop-blur, blur(20px));-webkit-backdrop-filter:var(--glass-backdrop-blur, blur(20px));position:sticky;top:0;z-index:100}.header__brand[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;background:none;border:none;padding:0;cursor:pointer;border-radius:6px;transition:opacity .15s ease}.header__brand[_ngcontent-%COMP%]:hover{opacity:.7}.header__logo-img[_ngcontent-%COMP%]{width:24px;height:24px;object-fit:contain}.header__logo-text[_ngcontent-%COMP%]{font-size:1rem;font-weight:600;letter-spacing:-.02em;color:var(--color-text, #1d1d1f)}.header__nav[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.header__admin-btn[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:50%;border:1.5px solid var(--color-border, rgba(0, 0, 0, .1));background:var(--color-bg-secondary, rgba(0, 0, 0, .04));cursor:pointer;transition:background .15s ease,border-color .15s ease;padding:0;font-family:inherit;font-size:1rem;line-height:1}.header__admin-btn[_ngcontent-%COMP%]:hover{background:var(--color-bg-hover, rgba(0, 0, 0, .08));border-color:var(--color-primary, #007aff)}.header__admin-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.header__user-btn[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:50%;border:1.5px solid var(--color-border, rgba(0, 0, 0, .1));background:var(--color-bg-secondary, rgba(0, 0, 0, .04));cursor:pointer;transition:background .15s ease,border-color .15s ease;padding:0;font-family:inherit}.header__user-btn[_ngcontent-%COMP%]:hover{background:var(--color-bg-hover, rgba(0, 0, 0, .08));border-color:var(--color-primary, #007aff)}.header__user-btn--active[_ngcontent-%COMP%]{background:var(--color-primary, #007aff);border-color:var(--color-primary, #007aff)}.header__user-btn--active[_ngcontent-%COMP%] .header__user-initials[_ngcontent-%COMP%], .header__user-btn--active[_ngcontent-%COMP%] .header__user-icon[_ngcontent-%COMP%]{color:#fff}.header__user-initials[_ngcontent-%COMP%]{font-size:.75rem;font-weight:600;color:var(--color-text, #1d1d1f);line-height:1;letter-spacing:.02em}.header__user-icon[_ngcontent-%COMP%]{font-size:1rem;color:var(--color-text-secondary, #6e6e73);line-height:1}"]})};export{_ as a,E as b};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as z,f as D}from"./chunk-GGNCDOF3.js";import{b as V,d as T}from"./chunk-UARV2YUR.js";import{a as M}from"./chunk-UCFKZZMU.js";import{D as U,b as L,c as B,e as O,g as $,h as G,i as W,l as d,n as j,s as q,u as J}from"./chunk-N5UH5PRX.js";import{Bb as E,Db as h,Fb as s,Ka as a,Tb as r,Ub as w,Vb as R,Wa as A,a as k,b as P,ca as p,ga as v,ha as y,lb as C,ma as S,mb as b,pb as F,qb as N,rb as c,sb as o,ta as _,tb as n,ub as f,z as I}from"./chunk-QPN22TF2.js";var K=(i,t)=>t.config.id;function Q(i,t){i&1&&(o(0,"p",5),r(1,"Loading\u2026"),n())}function X(i,t){if(i&1&&(o(0,"span",32),r(1),n()),i&2){let e=s().$implicit;a(),w(e.config.integrationType)}}function Y(i,t){if(i&1&&f(0,"input",33),i&2){let e=s().$implicit;c("formControl",e.toolsControl)}}function Z(i,t){if(i&1){let e=E();o(0,"div",28)(1,"label",29)(2,"input",30),h("change",function(){let g=v(e).$implicit,m=s(3);return y(m.toggleIntegration(g))}),n(),o(3,"span",31),r(4),n(),C(5,X,2,1,"span",32),n(),C(6,Y,1,1,"input",33),n()}if(i&2){let e=t.$implicit;a(2),c("checked",e.enabled()),a(2),w(e.config.name),a(),b(e.config.integrationType?5:-1),a(),b(e.enabled()?6:-1)}}function ee(i,t){if(i&1&&(o(0,"fieldset",18)(1,"legend",26),r(2,"Integrations"),n(),o(3,"p",27),r(4," Select which integrations this agent can use. Leave tool names empty to allow all tools from an integration. "),n(),F(5,Z,7,4,"div",28,K),n()),i&2){let e=s(2);a(5),N(e.integrationRows())}}function ne(i,t){if(i&1){let e=E();o(0,"form",7),h("ngSubmit",function(){v(e);let g=s();return y(g.submit())}),o(1,"div",8)(2,"label",9),r(3,"Name "),o(4,"span",10),r(5,"*"),n()(),f(6,"input",11),n(),o(7,"div",8)(8,"label",12),r(9,"Description"),n(),f(10,"input",13),n(),o(11,"div",8)(12,"label",14),r(13,"Model name"),n(),f(14,"input",15),n(),o(15,"div",8)(16,"label",16),r(17,"Instructions"),n(),f(18,"textarea",17),n(),C(19,ee,7,0,"fieldset",18),o(20,"div",8)(21,"label",19),f(22,"input",20),o(23,"span",21),r(24,"Advanced mode"),n()(),o(25,"p",22),r(26," When enabled, this agent uses a multi-step reasoning loop instead of a single LLM call. "),n()(),o(27,"div",23)(28,"button",24),r(29),n(),o(30,"button",25),h("click",function(){v(e);let g=s();return y(g.cancel())}),r(31,"Cancel"),n()()()}if(i&2){let e=s();c("formGroup",e.form),a(6),c("formControl",e.nameControl),a(4),c("formControl",e.descriptionControl),a(4),c("formControl",e.modelNameControl),a(4),c("formControl",e.instructionsControl),a(),b(e.integrationRows().length>0?19:-1),a(3),c("formControl",e.advancedExecutionControl),a(6),c("disabled",e.form.invalid||e.isSubmitting()),a(),R(" ",e.isEditMode()?"Save changes":"Create"," ")}}var H=class i{route=p(V);router=p(T);destroyRef=p(S);agentConfigController=p(z);integrationConfigController=p(D);namespaceId=this.route.snapshot.params.namespaceId;form=new W({name:new d("",{nonNullable:!0,validators:[O.required,O.minLength(1)]}),description:new d(null),modelName:new d(null),instructions:new d(null),advancedExecution:new d(!1,{nonNullable:!0})});get nameControl(){return this.form.controls.name}get descriptionControl(){return this.form.controls.description}get modelNameControl(){return this.form.controls.modelName}get instructionsControl(){return this.form.controls.instructions}get advancedExecutionControl(){return this.form.controls.advancedExecution}isEditMode=_(!1);isSubmitting=_(!1);isLoading=_(!1);integrationRows=_([]);existingConfig=null;ngOnInit(){let t=this.route.snapshot.paramMap.get("agentConfigId");t?(this.isEditMode.set(!0),this.loadConfigAndIntegrations(t)):this.loadIntegrations(void 0)}loadConfigAndIntegrations(t){this.isLoading.set(!0),I({config:this.agentConfigController.getByIdAgentConfig(t),integrations:this.integrationConfigController.listByParentIntegrationConfig(this.namespaceId)}).pipe(M(this.destroyRef)).subscribe({next:({config:e,integrations:l})=>{this.existingConfig=e,this.nameControl.setValue(e.name),this.descriptionControl.setValue(e.description??null),this.modelNameControl.setValue(e.modelName??null),this.instructionsControl.setValue(e.instructions??null),this.advancedExecutionControl.setValue(e.advancedExecution??!1),this.integrationRows.set(this.buildIntegrationRows(l,e.integrations??void 0)),this.isLoading.set(!1)},error:()=>{this.isLoading.set(!1),this.navigateBack()}})}loadIntegrations(t){this.integrationConfigController.listByParentIntegrationConfig(this.namespaceId).pipe(M(this.destroyRef)).subscribe({next:e=>{this.integrationRows.set(this.buildIntegrationRows(e,t??void 0))}})}buildIntegrationRows(t,e){return t.map(l=>{let g=l.name??"",m=e?.[g],x=e!=null&&g in e,u=Array.isArray(m)?m.join(", "):"";return{config:l,enabled:_(x),toolsControl:new d(u,{nonNullable:!0})}})}toggleIntegration(t){t.enabled.update(e=>!e)}buildIntegrationsPayload(){let e=this.integrationRows().filter(g=>g.enabled());if(e.length===0)return;let l={};for(let g of e){let m=g.config.name??"",x=g.toolsControl.value.trim();x===""?l[m]=null:l[m]=x.split(",").map(u=>u.trim()).filter(u=>u.length>0)}return l}submit(){if(this.form.invalid||this.isSubmitting())return;this.isSubmitting.set(!0);let t=P(k({},this.existingConfig??{}),{namespaceId:this.namespaceId,name:this.nameControl.value.trim(),description:this.descriptionControl.value?.trim()||void 0,modelName:this.modelNameControl.value?.trim()||void 0,instructions:this.instructionsControl.value?.trim()||void 0,integrations:this.buildIntegrationsPayload(),advancedExecution:this.advancedExecutionControl.value});(this.isEditMode()?this.agentConfigController.updateAgentConfig(this.existingConfig.id??"",t):this.agentConfigController.createAgentConfig(t)).pipe(M(this.destroyRef)).subscribe({next:()=>this.navigateBack(),error:()=>this.isSubmitting.set(!1)})}cancel(){this.navigateBack()}navigateBack(){this.router.navigate(["/agentos",this.namespaceId,"agent-configs"])}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=A({type:i,selectors:[["agentos-agent-config-form"]],decls:10,vars:2,consts:[[1,"agent-config-form"],[1,"agent-config-form__header"],["type","button","title","Back to agent configs",1,"agent-config-form__back",3,"click"],[1,"agent-config-form__back-icon"],[1,"agent-config-form__title"],[1,"agent-config-form__loading"],[1,"agent-config-form__form",3,"formGroup"],[1,"agent-config-form__form",3,"ngSubmit","formGroup"],[1,"agent-config-form__field"],["for","agent-config-name",1,"agent-config-form__label"],["aria-hidden","true"],["id","agent-config-name","type","text","placeholder","e.g. Support agent","autocomplete","off",1,"agent-config-form__input",3,"formControl"],["for","agent-config-description",1,"agent-config-form__label"],["id","agent-config-description","type","text","placeholder","Optional \u2014 short description of this agent","autocomplete","off",1,"agent-config-form__input",3,"formControl"],["for","agent-config-model-name",1,"agent-config-form__label"],["id","agent-config-model-name","type","text","placeholder","Optional \u2014 model alias or name to use","autocomplete","off",1,"agent-config-form__input",3,"formControl"],["for","agent-config-instructions",1,"agent-config-form__label"],["id","agent-config-instructions","rows","6","placeholder","Optional \u2014 system instructions for this agent",1,"agent-config-form__textarea",3,"formControl"],[1,"agent-config-form__integrations"],[1,"agent-config-form__toggle-label"],["type","checkbox",1,"agent-config-form__toggle-checkbox",3,"formControl"],[1,"agent-config-form__toggle-text"],[1,"agent-config-form__toggle-hint"],[1,"agent-config-form__actions"],["type","submit",1,"agent-config-form__btn","agent-config-form__btn--primary",3,"disabled"],["type","button",1,"agent-config-form__btn",3,"click"],[1,"agent-config-form__label"],[1,"agent-config-form__integrations-hint"],[1,"agent-config-form__integration-row"],[1,"agent-config-form__integration-toggle"],["type","checkbox",1,"agent-config-form__integration-checkbox",3,"change","checked"],[1,"agent-config-form__integration-name"],[1,"agent-config-form__integration-type"],["type","text","placeholder","Tool names, comma-separated (empty = all tools)","autocomplete","off",1,"agent-config-form__input","agent-config-form__integration-tools",3,"formControl"]],template:function(e,l){e&1&&(o(0,"div",0)(1,"header",1)(2,"button",2),h("click",function(){return l.cancel()}),o(3,"span",3),r(4,"\u2190"),n(),r(5," Agent Configs "),n(),o(6,"h1",4),r(7),n()(),C(8,Q,2,0,"p",5)(9,ne,32,9,"form",6),n()),e&2&&(a(7),w(l.isEditMode()?"Edit agent config":"New agent config"),a(),b(l.isLoading()?8:9))},dependencies:[U,j,B,L,$,G,q,J],styles:[".agent-config-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:560px;margin:0 auto;padding:2rem 1rem}.agent-config-form__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.agent-config-form__back[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.375rem;background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;color:var(--color-primary, #007aff);font-family:inherit}.agent-config-form__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-form__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.agent-config-form__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.agent-config-form__loading[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;margin:0}.agent-config-form__form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.25rem}.agent-config-form__field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.agent-config-form__label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:var(--color-text, #1d1d1f)}.agent-config-form__input[_ngcontent-%COMP%], .agent-config-form__textarea[_ngcontent-%COMP%]{width:100%;padding:.625rem .875rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:transparent;color:var(--color-text, #1d1d1f);font-size:.9375rem;font-family:inherit;outline:none;box-sizing:border-box;transition:border-color .15s ease}.agent-config-form__input[_ngcontent-%COMP%]:focus, .agent-config-form__textarea[_ngcontent-%COMP%]:focus{border-color:var(--color-primary, #007aff)}.agent-config-form__input[_ngcontent-%COMP%]::placeholder, .agent-config-form__textarea[_ngcontent-%COMP%]::placeholder{color:var(--color-text-secondary, #6e6e73)}.agent-config-form__textarea[_ngcontent-%COMP%]{resize:vertical;min-height:120px;line-height:1.5}.agent-config-form__integrations[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .1));border-radius:8px;padding:1rem;margin:0;display:flex;flex-direction:column;gap:.75rem}.agent-config-form__integrations-hint[_ngcontent-%COMP%]{margin:0;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.agent-config-form__integration-row[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.agent-config-form__integration-toggle[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none}.agent-config-form__integration-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.agent-config-form__integration-name[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500;color:var(--color-text, #1d1d1f)}.agent-config-form__integration-type[_ngcontent-%COMP%]{font-size:.75rem;color:var(--color-text-secondary, #6e6e73);font-family:monospace}.agent-config-form__integration-tools[_ngcontent-%COMP%]{margin-left:1.5rem;font-size:.875rem}.agent-config-form__toggle-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none}.agent-config-form__toggle-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.agent-config-form__toggle-text[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500;color:var(--color-text, #1d1d1f)}.agent-config-form__toggle-hint[_ngcontent-%COMP%]{margin:.25rem 0 0 1.5rem;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.agent-config-form__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem;padding-top:.5rem}.agent-config-form__btn[_ngcontent-%COMP%]{padding:.6rem 1.25rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:transparent;color:var(--color-text, #1d1d1f);font-size:.9375rem;font-family:inherit;cursor:pointer;transition:background .15s ease,border-color .15s ease}.agent-config-form__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.agent-config-form__btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:not-allowed}.agent-config-form__btn--primary[_ngcontent-%COMP%]{background:var(--color-primary, #007aff);border-color:var(--color-primary, #007aff);color:#fff}.agent-config-form__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-primary-hover, #0051d5);border-color:var(--color-primary-hover, #0051d5)}"],changeDetection:0})};export{H as AgentConfigFormComponent};
|
|
1
|
+
import{b as z,f as D}from"./chunk-NEH5OLEF.js";import{b as V,d as T}from"./chunk-UARV2YUR.js";import{a as M}from"./chunk-UCFKZZMU.js";import{D as U,b as L,c as B,e as O,g as $,h as G,i as W,l as d,n as j,s as q,u as J}from"./chunk-N5UH5PRX.js";import{Bb as E,Db as h,Fb as s,Ka as a,Tb as r,Ub as w,Vb as R,Wa as A,a as k,b as P,ca as p,ga as v,ha as y,lb as C,ma as S,mb as b,pb as F,qb as N,rb as c,sb as o,ta as _,tb as n,ub as f,z as I}from"./chunk-QPN22TF2.js";var K=(i,t)=>t.config.id;function Q(i,t){i&1&&(o(0,"p",5),r(1,"Loading\u2026"),n())}function X(i,t){if(i&1&&(o(0,"span",32),r(1),n()),i&2){let e=s().$implicit;a(),w(e.config.integrationType)}}function Y(i,t){if(i&1&&f(0,"input",33),i&2){let e=s().$implicit;c("formControl",e.toolsControl)}}function Z(i,t){if(i&1){let e=E();o(0,"div",28)(1,"label",29)(2,"input",30),h("change",function(){let g=v(e).$implicit,m=s(3);return y(m.toggleIntegration(g))}),n(),o(3,"span",31),r(4),n(),C(5,X,2,1,"span",32),n(),C(6,Y,1,1,"input",33),n()}if(i&2){let e=t.$implicit;a(2),c("checked",e.enabled()),a(2),w(e.config.name),a(),b(e.config.integrationType?5:-1),a(),b(e.enabled()?6:-1)}}function ee(i,t){if(i&1&&(o(0,"fieldset",18)(1,"legend",26),r(2,"Integrations"),n(),o(3,"p",27),r(4," Select which integrations this agent can use. Leave tool names empty to allow all tools from an integration. "),n(),F(5,Z,7,4,"div",28,K),n()),i&2){let e=s(2);a(5),N(e.integrationRows())}}function ne(i,t){if(i&1){let e=E();o(0,"form",7),h("ngSubmit",function(){v(e);let g=s();return y(g.submit())}),o(1,"div",8)(2,"label",9),r(3,"Name "),o(4,"span",10),r(5,"*"),n()(),f(6,"input",11),n(),o(7,"div",8)(8,"label",12),r(9,"Description"),n(),f(10,"input",13),n(),o(11,"div",8)(12,"label",14),r(13,"Model name"),n(),f(14,"input",15),n(),o(15,"div",8)(16,"label",16),r(17,"Instructions"),n(),f(18,"textarea",17),n(),C(19,ee,7,0,"fieldset",18),o(20,"div",8)(21,"label",19),f(22,"input",20),o(23,"span",21),r(24,"Advanced mode"),n()(),o(25,"p",22),r(26," When enabled, this agent uses a multi-step reasoning loop instead of a single LLM call. "),n()(),o(27,"div",23)(28,"button",24),r(29),n(),o(30,"button",25),h("click",function(){v(e);let g=s();return y(g.cancel())}),r(31,"Cancel"),n()()()}if(i&2){let e=s();c("formGroup",e.form),a(6),c("formControl",e.nameControl),a(4),c("formControl",e.descriptionControl),a(4),c("formControl",e.modelNameControl),a(4),c("formControl",e.instructionsControl),a(),b(e.integrationRows().length>0?19:-1),a(3),c("formControl",e.advancedExecutionControl),a(6),c("disabled",e.form.invalid||e.isSubmitting()),a(),R(" ",e.isEditMode()?"Save changes":"Create"," ")}}var H=class i{route=p(V);router=p(T);destroyRef=p(S);agentConfigController=p(z);integrationConfigController=p(D);namespaceId=this.route.snapshot.params.namespaceId;form=new W({name:new d("",{nonNullable:!0,validators:[O.required,O.minLength(1)]}),description:new d(null),modelName:new d(null),instructions:new d(null),advancedExecution:new d(!1,{nonNullable:!0})});get nameControl(){return this.form.controls.name}get descriptionControl(){return this.form.controls.description}get modelNameControl(){return this.form.controls.modelName}get instructionsControl(){return this.form.controls.instructions}get advancedExecutionControl(){return this.form.controls.advancedExecution}isEditMode=_(!1);isSubmitting=_(!1);isLoading=_(!1);integrationRows=_([]);existingConfig=null;ngOnInit(){let t=this.route.snapshot.paramMap.get("agentConfigId");t?(this.isEditMode.set(!0),this.loadConfigAndIntegrations(t)):this.loadIntegrations(void 0)}loadConfigAndIntegrations(t){this.isLoading.set(!0),I({config:this.agentConfigController.getByIdAgentConfig(t),integrations:this.integrationConfigController.listByParentIntegrationConfig(this.namespaceId)}).pipe(M(this.destroyRef)).subscribe({next:({config:e,integrations:l})=>{this.existingConfig=e,this.nameControl.setValue(e.name),this.descriptionControl.setValue(e.description??null),this.modelNameControl.setValue(e.modelName??null),this.instructionsControl.setValue(e.instructions??null),this.advancedExecutionControl.setValue(e.advancedExecution??!1),this.integrationRows.set(this.buildIntegrationRows(l,e.integrations??void 0)),this.isLoading.set(!1)},error:()=>{this.isLoading.set(!1),this.navigateBack()}})}loadIntegrations(t){this.integrationConfigController.listByParentIntegrationConfig(this.namespaceId).pipe(M(this.destroyRef)).subscribe({next:e=>{this.integrationRows.set(this.buildIntegrationRows(e,t??void 0))}})}buildIntegrationRows(t,e){return t.map(l=>{let g=l.name??"",m=e?.[g],x=e!=null&&g in e,u=Array.isArray(m)?m.join(", "):"";return{config:l,enabled:_(x),toolsControl:new d(u,{nonNullable:!0})}})}toggleIntegration(t){t.enabled.update(e=>!e)}buildIntegrationsPayload(){let e=this.integrationRows().filter(g=>g.enabled());if(e.length===0)return;let l={};for(let g of e){let m=g.config.name??"",x=g.toolsControl.value.trim();x===""?l[m]=null:l[m]=x.split(",").map(u=>u.trim()).filter(u=>u.length>0)}return l}submit(){if(this.form.invalid||this.isSubmitting())return;this.isSubmitting.set(!0);let t=P(k({},this.existingConfig??{}),{namespaceId:this.namespaceId,name:this.nameControl.value.trim(),description:this.descriptionControl.value?.trim()||void 0,modelName:this.modelNameControl.value?.trim()||void 0,instructions:this.instructionsControl.value?.trim()||void 0,integrations:this.buildIntegrationsPayload(),advancedExecution:this.advancedExecutionControl.value});(this.isEditMode()?this.agentConfigController.updateAgentConfig(this.existingConfig.id??"",t):this.agentConfigController.createAgentConfig(t)).pipe(M(this.destroyRef)).subscribe({next:()=>this.navigateBack(),error:()=>this.isSubmitting.set(!1)})}cancel(){this.navigateBack()}navigateBack(){this.router.navigate(["/agentos",this.namespaceId,"agent-configs"])}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=A({type:i,selectors:[["agentos-agent-config-form"]],decls:10,vars:2,consts:[[1,"agent-config-form"],[1,"agent-config-form__header"],["type","button","title","Back to agent configs",1,"agent-config-form__back",3,"click"],[1,"agent-config-form__back-icon"],[1,"agent-config-form__title"],[1,"agent-config-form__loading"],[1,"agent-config-form__form",3,"formGroup"],[1,"agent-config-form__form",3,"ngSubmit","formGroup"],[1,"agent-config-form__field"],["for","agent-config-name",1,"agent-config-form__label"],["aria-hidden","true"],["id","agent-config-name","type","text","placeholder","e.g. Support agent","autocomplete","off",1,"agent-config-form__input",3,"formControl"],["for","agent-config-description",1,"agent-config-form__label"],["id","agent-config-description","type","text","placeholder","Optional \u2014 short description of this agent","autocomplete","off",1,"agent-config-form__input",3,"formControl"],["for","agent-config-model-name",1,"agent-config-form__label"],["id","agent-config-model-name","type","text","placeholder","Optional \u2014 model alias or name to use","autocomplete","off",1,"agent-config-form__input",3,"formControl"],["for","agent-config-instructions",1,"agent-config-form__label"],["id","agent-config-instructions","rows","6","placeholder","Optional \u2014 system instructions for this agent",1,"agent-config-form__textarea",3,"formControl"],[1,"agent-config-form__integrations"],[1,"agent-config-form__toggle-label"],["type","checkbox",1,"agent-config-form__toggle-checkbox",3,"formControl"],[1,"agent-config-form__toggle-text"],[1,"agent-config-form__toggle-hint"],[1,"agent-config-form__actions"],["type","submit",1,"agent-config-form__btn","agent-config-form__btn--primary",3,"disabled"],["type","button",1,"agent-config-form__btn",3,"click"],[1,"agent-config-form__label"],[1,"agent-config-form__integrations-hint"],[1,"agent-config-form__integration-row"],[1,"agent-config-form__integration-toggle"],["type","checkbox",1,"agent-config-form__integration-checkbox",3,"change","checked"],[1,"agent-config-form__integration-name"],[1,"agent-config-form__integration-type"],["type","text","placeholder","Tool names, comma-separated (empty = all tools)","autocomplete","off",1,"agent-config-form__input","agent-config-form__integration-tools",3,"formControl"]],template:function(e,l){e&1&&(o(0,"div",0)(1,"header",1)(2,"button",2),h("click",function(){return l.cancel()}),o(3,"span",3),r(4,"\u2190"),n(),r(5," Agent Configs "),n(),o(6,"h1",4),r(7),n()(),C(8,Q,2,0,"p",5)(9,ne,32,9,"form",6),n()),e&2&&(a(7),w(l.isEditMode()?"Edit agent config":"New agent config"),a(),b(l.isLoading()?8:9))},dependencies:[U,j,B,L,$,G,q,J],styles:[".agent-config-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:560px;margin:0 auto;padding:2rem 1rem}.agent-config-form__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.agent-config-form__back[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.375rem;background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;color:var(--color-primary, #007aff);font-family:inherit}.agent-config-form__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-form__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.agent-config-form__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.agent-config-form__loading[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;margin:0}.agent-config-form__form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.25rem}.agent-config-form__field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.agent-config-form__label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:var(--color-text, #1d1d1f)}.agent-config-form__input[_ngcontent-%COMP%], .agent-config-form__textarea[_ngcontent-%COMP%]{width:100%;padding:.625rem .875rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:transparent;color:var(--color-text, #1d1d1f);font-size:.9375rem;font-family:inherit;outline:none;box-sizing:border-box;transition:border-color .15s ease}.agent-config-form__input[_ngcontent-%COMP%]:focus, .agent-config-form__textarea[_ngcontent-%COMP%]:focus{border-color:var(--color-primary, #007aff)}.agent-config-form__input[_ngcontent-%COMP%]::placeholder, .agent-config-form__textarea[_ngcontent-%COMP%]::placeholder{color:var(--color-text-secondary, #6e6e73)}.agent-config-form__textarea[_ngcontent-%COMP%]{resize:vertical;min-height:120px;line-height:1.5}.agent-config-form__integrations[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .1));border-radius:8px;padding:1rem;margin:0;display:flex;flex-direction:column;gap:.75rem}.agent-config-form__integrations-hint[_ngcontent-%COMP%]{margin:0;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.agent-config-form__integration-row[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.agent-config-form__integration-toggle[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none}.agent-config-form__integration-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.agent-config-form__integration-name[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500;color:var(--color-text, #1d1d1f)}.agent-config-form__integration-type[_ngcontent-%COMP%]{font-size:.75rem;color:var(--color-text-secondary, #6e6e73);font-family:monospace}.agent-config-form__integration-tools[_ngcontent-%COMP%]{margin-left:1.5rem;font-size:.875rem}.agent-config-form__toggle-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none}.agent-config-form__toggle-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.agent-config-form__toggle-text[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500;color:var(--color-text, #1d1d1f)}.agent-config-form__toggle-hint[_ngcontent-%COMP%]{margin:.25rem 0 0 1.5rem;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.agent-config-form__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem;padding-top:.5rem}.agent-config-form__btn[_ngcontent-%COMP%]{padding:.6rem 1.25rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:transparent;color:var(--color-text, #1d1d1f);font-size:.9375rem;font-family:inherit;cursor:pointer;transition:background .15s ease,border-color .15s ease}.agent-config-form__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.agent-config-form__btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:not-allowed}.agent-config-form__btn--primary[_ngcontent-%COMP%]{background:var(--color-primary, #007aff);border-color:var(--color-primary, #007aff);color:#fff}.agent-config-form__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-primary-hover, #0051d5);border-color:var(--color-primary-hover, #0051d5)}"],changeDetection:0})};export{H as AgentConfigFormComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as V}from"./chunk-
|
|
1
|
+
import{h as V}from"./chunk-NEH5OLEF.js";import{d as E}from"./chunk-UARV2YUR.js";import{u as D,v as O}from"./chunk-WER6464F.js";import{a as N}from"./chunk-UCFKZZMU.js";import{Bb as I,Db as l,Fb as o,Hc as A,Ka as _,Pb as k,S as w,Tb as y,Ub as h,Wa as f,ab as M,ac as T,ca as g,dc as P,ec as L,ga as r,ha as m,hc as S,i as R,lb as C,ma as q,mb as v,oa as c,rb as u,sb as p,t as x,tb as d}from"./chunk-QPN22TF2.js";function K(s,t){if(s&1&&(p(0,"span",3),y(1),d()),s&2){let e=o();_(),h(e.namespace.description)}}var b=class s{namespace;selected=new c;editRequested=new c;integrationsRequested=new c;aiProvidersRequested=new c;aiModelsRequested=new c;agentConfigsRequested=new c;deleteRequested=new c;menuItems=[{key:"edit",label:"Edit namespace",icon:"edit"},{key:"integrations",label:"Manage integrations",icon:"settings"},{key:"ai-providers",label:"AI Providers",icon:"smart_toy"},{key:"ai-models",label:"AI models",icon:"model_training"},{key:"agent-configs",label:"Agent Configs",icon:"support_agent"},{key:"delete",label:"Delete namespace",icon:"delete",variant:"danger"}];onSelect(){this.selected.emit(this.namespace)}onMenuAction(t){switch(t){case"edit":this.editRequested.emit(this.namespace);break;case"integrations":this.integrationsRequested.emit(this.namespace);break;case"ai-providers":this.aiProvidersRequested.emit(this.namespace);break;case"ai-models":this.aiModelsRequested.emit(this.namespace);break;case"agent-configs":this.agentConfigsRequested.emit(this.namespace);break;case"delete":confirm(`Delete namespace "${this.namespace.name}"?`)&&this.deleteRequested.emit(this.namespace);break}}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=f({type:s,selectors:[["agentos-namespace-item"]],inputs:{namespace:"namespace"},outputs:{selected:"selected",editRequested:"editRequested",integrationsRequested:"integrationsRequested",aiProvidersRequested:"aiProvidersRequested",aiModelsRequested:"aiModelsRequested",agentConfigsRequested:"agentConfigsRequested",deleteRequested:"deleteRequested"},decls:7,vars:3,consts:[["role","listitem",1,"namespace-item"],["type","button",1,"namespace-item__body",3,"click"],[1,"namespace-item__name"],[1,"namespace-item__desc"],[1,"namespace-item__actions"],[3,"itemSelected","items"]],template:function(e,a){e&1&&(p(0,"div",0)(1,"button",1),l("click",function(){return a.onSelect()}),p(2,"span",2),y(3),d(),C(4,K,2,1,"span",3),d(),p(5,"div",4)(6,"ds-kebab-menu",5),l("itemSelected",function(i){return a.onMenuAction(i)}),d()()()),e&2&&(_(3),h(a.namespace.name),_(),v(a.namespace.description?4:-1),_(2),u("items",a.menuItems))},dependencies:[O],styles:[".namespace-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:.875rem 1.25rem;border-radius:10px;border:1px solid var(--color-border, rgba(0, 0, 0, .08));background:var(--glass-bg, rgba(255, 255, 255, .72));-webkit-backdrop-filter:var(--glass-backdrop-blur, blur(20px));backdrop-filter:var(--glass-backdrop-blur, blur(20px));transition:background .15s ease,border-color .15s ease}.namespace-item[_ngcontent-%COMP%]:hover{background:var(--color-bg-hover, rgba(0, 0, 0, .04));border-color:var(--color-primary, #007aff)}.namespace-item__body[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;align-items:flex-start;gap:.2rem;background:none;border:none;padding:0;cursor:pointer;text-align:left;min-width:0}.namespace-item__name[_ngcontent-%COMP%]{font-size:.95rem;font-weight:500;color:var(--color-text, #1d1d1f);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.namespace-item__desc[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-text-secondary, #6e6e73);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.namespace-item__actions[_ngcontent-%COMP%]{flex-shrink:0;display:flex;align-items:center;gap:.125rem;opacity:0;transition:opacity .15s ease}.namespace-item[_ngcontent-%COMP%]:hover .namespace-item__actions[_ngcontent-%COMP%], .namespace-item[_ngcontent-%COMP%]:focus-within .namespace-item__actions[_ngcontent-%COMP%]{opacity:1}"],changeDetection:0})};var j=()=>[];function z(s,t){if(s&1){let e=I();p(0,"agentos-namespace-item",3),l("selected",function(n){r(e);let i=o(2);return m(i.navigateToCases(n.id??""))})("editRequested",function(n){r(e);let i=o(2);return m(i.navigateToEdit(n))})("deleteRequested",function(n){r(e);let i=o(2);return m(i.deleteNamespace(n))})("integrationsRequested",function(n){r(e);let i=o(2);return m(i.openIntegrations(n))})("aiProvidersRequested",function(n){r(e);let i=o(2);return m(i.openAiProviders(n))})("aiModelsRequested",function(n){r(e);let i=o(2);return m(i.openAiModels(n))})("agentConfigsRequested",function(n){r(e);let i=o(2);return m(i.openAgentConfigs(n))}),d()}s&2&&u("namespace",t)}function U(s,t){if(s&1&&C(0,z,1,1,"agentos-namespace-item",2),s&2){let e,a=t.$implicit,n=o();v((e=n.resolveNamespace(a.id))?0:-1,e)}}var $=class s{router=g(E);namespaceController=g(V);destroyRef=g(q);refresh$=new R(void 0);namespaces$=this.refresh$.pipe(w(()=>this.namespaceController.listAllNamespace()));namespaceItems$=this.namespaces$.pipe(x(t=>t.map(e=>({id:e.id??"",name:e.name,description:e.description,badges:e.defaultAgentName?[{label:e.defaultAgentName,variant:"info"}]:void 0}))));namespacesById=new Map;constructor(){this.namespaces$.pipe(N(this.destroyRef)).subscribe(t=>{this.namespacesById=new Map(t.map(e=>[e.id??"",e]))})}navigateToCases(t){this.router.navigate(["/agentos",t,"cases"])}navigateToCreate(){this.router.navigate(["/agentos/namespaces/new"])}navigateToEdit(t){this.router.navigate(["/agentos/namespaces",t.id??"","edit"])}openIntegrations(t){this.router.navigate(["/agentos",t.id,"integrations"])}openAiProviders(t){this.router.navigate(["/agentos",t.id,"ai-providers"])}openAiModels(t){this.router.navigate(["/agentos",t.id,"ai-models"])}openAgentConfigs(t){this.router.navigate(["/agentos",t.id,"agent-configs"])}deleteNamespace(t){this.namespaceController.deleteNamespace(t.id??"").pipe(N(this.destroyRef)).subscribe(()=>this.refresh$.next())}resolveNamespace(t){return this.namespacesById.get(t)??null}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=f({type:s,selectors:[["agentos-namespace-list"]],decls:4,vars:6,consts:[["namespaceItemTpl",""],["title","Namespaces","emptyMessage","No namespaces yet. Create one to get started.","cardMinWidth","400px",3,"itemSelected","createRequested","items","showCreate","itemTemplate"],[3,"namespace"],[3,"selected","editRequested","deleteRequested","integrationsRequested","aiProvidersRequested","aiModelsRequested","agentConfigsRequested","namespace"]],template:function(e,a){if(e&1&&(p(0,"ds-entity-list",1),P(1,"async"),l("itemSelected",function(i){return a.navigateToCases(i)})("createRequested",function(){return a.navigateToCreate()}),d(),M(2,U,1,1,"ng-template",null,0,S)),e&2){let n=k(3);u("items",L(1,3,a.namespaceItems$)??T(5,j))("showCreate",!0)("itemTemplate",n)}},dependencies:[b,D,A],encapsulation:2})};export{b as a,$ as b};
|