import{Z as s}from"./index-4e8c1b57.js";const c=(t,e)=>{let r=`/api/experiments/${t}/`;if(e){const a=new URLSearchParams(e);r+=`?${a.toString()}`}return fetch(s(r))},o=(t,e,r,a)=>{const n=new URLSearchParams(e);return fetch(s(`/api/experiments/${t}/?${n.toString()}`,"PUT",r,a))},i=t=>{const e=new URLSearchParams;return Object.entries(t).forEach(([r,a])=>{Array.isArray(a)?a.forEach(n=>e.append(r,n)):e.set(r,a)}),fetch(s(`/api/experiments/?${e.toString()}`))},m=t=>{const e=new URLSearchParams(t);return fetch(s(`/api/experiments/?${e.toString()}`,"POST"))},P=(t,e)=>fetch(s(`/api/experiments/${t}/collaborators/`,"POST",e)),x=(t,e)=>fetch(s(`/api/experiments/${t}/collaborators/`,"DELETE",e)),f=(t,e)=>fetch(s(`/api/experiment/${t}/transfers/`,"POST",e)),h=(t,e)=>fetch(s(`/api/experiment/${t}/transfers/`,"PUT",e)),E=()=>fetch(s("/api/experiment-templates/")),l=(t,e,r)=>{const a=new URLSearchParams(e);return fetch(s(`/api/experiments/${t}/elements?${a.toString()}`,"PUT",r))},S=(t,e,r)=>{const a=new URLSearchParams(e);return fetch(s(`/api/experiments/${t}/elements?${a.toString()}`,"DELETE",r))},u=(t,e,r)=>{const a=new URLSearchParams(e);return fetch(s(`/api/experiments/${t}/elements?${a.toString()}`,"POST",r))};export{E as a,i as b,m as c,o as d,u as e,S as f,c as g,l as h,P as i,x as j,f as r,h as u};