import{c as u,q as c}from"./index-DZqSbjFw.js";import{u as p}from"./useQuery-KlPPWaKy.js";import{K as n}from"./constants-Mpett05j.js";async function f(l){return l.getServerCapabilities()?.resources?await l.listResources():{resources:[]}}async function b(l,e){return await l.readResource({uri:e})}function R(l){const e=u.c(12);let t,s;e[0]!==l?({client:t,...s}=l,e[0]=l,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let r;e[3]!==t?(r=n.mcpResourcesList(t),e[3]=t,e[4]=r):r=e[4];let i;e[5]!==t?(i=()=>f(t),e[5]=t,e[6]=i):i=e[6];const o=s.staleTime??3e4;let a;return e[7]!==s||e[8]!==r||e[9]!==i||e[10]!==o?(a={...s,queryKey:r,queryFn:i,staleTime:o,retry:!1},e[7]=s,e[8]=r,e[9]=i,e[10]=o,e[11]=a):a=e[11],c(a)}function L(l){const e=u.c(12);let t,s;e[0]!==l?({client:t,...s}=l,e[0]=l,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let r;e[3]!==t?(r=n.mcpResourcesList(t),e[3]=t,e[4]=r):r=e[4];let i;e[5]!==t?(i=()=>f(t),e[5]=t,e[6]=i):i=e[6];const o=s.staleTime??3e4;let a;return e[7]!==s||e[8]!==r||e[9]!==i||e[10]!==o?(a={...s,queryKey:r,queryFn:i,staleTime:o,retry:!1},e[7]=s,e[8]=r,e[9]=i,e[10]=o,e[11]=a):a=e[11],p(a)}async function m(l){return l.getServerCapabilities()?.prompts?await l.listPrompts():{prompts:[]}}async function T(l,e,t){if(!l.getServerCapabilities()?.prompts)throw new Error("Prompts capability not supported");return await l.getPrompt({name:e,arguments:t??{}})}function g(l){const e=u.c(12);let t,s;e[0]!==l?({client:t,...s}=l,e[0]=l,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let r;e[3]!==t?(r=n.mcpPromptsList(t),e[3]=t,e[4]=r):r=e[4];let i;e[5]!==t?(i=()=>m(t),e[5]=t,e[6]=i):i=e[6];const o=s.staleTime??3e4;let a;return e[7]!==s||e[8]!==r||e[9]!==i||e[10]!==o?(a={...s,queryKey:r,queryFn:i,staleTime:o,retry:!1},e[7]=s,e[8]=r,e[9]=i,e[10]=o,e[11]=a):a=e[11],c(a)}function C(l){const e=u.c(12);let t,s;e[0]!==l?({client:t,...s}=l,e[0]=l,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let r;e[3]!==t?(r=n.mcpPromptsList(t),e[3]=t,e[4]=r):r=e[4];let i;e[5]!==t?(i=()=>m(t),e[5]=t,e[6]=i):i=e[6];const o=s.staleTime??3e4;let a;return e[7]!==s||e[8]!==r||e[9]!==i||e[10]!==o?(a={...s,queryKey:r,queryFn:i,staleTime:o,retry:!1},e[7]=s,e[8]=r,e[9]=i,e[10]=o,e[11]=a):a=e[11],p(a)}export{f as a,C as b,R as c,L as d,T as g,m as l,b as r,g as u};
