import{a7 as p,aQ as u,a4 as a}from"./index-BKr2rJhV.js";const h=p.injectEndpoints({endpoints:s=>({getFSSharedWith:s.query({query:({pId:e})=>({url:`project/${e}/featurestores/share`,method:"GET"}),providesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureStoreShare,"pId"),transformResponse:e=>e.items}),importDefaultFeatureGroups:s.mutation({query:({pId:e})=>({url:`project/${e}/featurestores/import-defaults`,method:"POST"}),invalidatesTags:(e,r,{pId:t})=>[{type:a.ProjectTags.FeatureStoreShare,id:t},{type:a.ProjectTags.FeatureStores,id:t},a.ProjectTags.FeatureGroup]}),shareFS:s.mutation({query:({pId:e,targetProjectId:r})=>({url:`project/${e}/featurestores/share?project=${r}`,method:"POST"}),invalidatesTags:(e,r,{pId:t,targetProjectId:o})=>[{type:a.ProjectTags.FeatureStoreShare,id:t},{type:a.ProjectTags.FeatureStores,id:o}]}),unShareFS:s.mutation({query:({pId:e,targetProjectId:r})=>({url:`project/${e}/featurestores/share?project=${r}`,method:"DELETE"}),invalidatesTags:(e,r,{pId:t,targetProjectId:o})=>[{type:a.ProjectTags.FeatureStoreShare,id:t},{type:a.ProjectTags.FeatureStores,id:o}]}),getFGSharedWith:s.query({query:({pId:e,featureGroupId:r})=>({url:`project/${e}/featurestores/share/featuregroups/${r}`,method:"GET"}),providesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureGroupShare,"featureGroupId"),transformResponse:e=>e.items}),shareFG:s.mutation({query:({pId:e,featureGroupId:r,targetProjectId:t})=>({url:`project/${e}/featurestores/share/featuregroups/${r}?project=${t}`,method:"POST"}),invalidatesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureGroupShare,"featureGroupId")}),shareFeatures:s.mutation({query:({pId:e,featureGroupId:r,targetProjectId:t,features:o})=>({url:`project/${e}/featurestores/share/featuregroups/${r}?project=${t}&${o.map(c=>`feature=${c}`).join("&")}`,method:"POST"}),invalidatesTags:(e,r,{featureGroupId:t})=>[{type:a.ProjectTags.FeatureGroupShare,id:t}]}),unShareFG:s.mutation({query:({pId:e,featureGroupId:r,targetProjectId:t})=>({url:`project/${e}/featurestores/share/featuregroups/${r}?project=${t}`,method:"DELETE"}),invalidatesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureGroupShare,"featureGroupId")}),removeReceivedFGShare:s.mutation({query:({pId:e,featureGroupId:r})=>({url:`project/${e}/featurestores/share/featuregroups/${r}/received`,method:"DELETE"}),invalidatesTags:(e,r,{pId:t})=>[{type:a.ProjectTags.FeatureStoreShare,id:t},{type:a.ProjectTags.FeatureStores,id:t},a.ProjectTags.FeatureGroup]}),removeReceivedFSShare:s.mutation({query:({pId:e,featurestoreId:r})=>({url:`project/${e}/featurestores/share/received?featurestore=${r}`,method:"DELETE"}),invalidatesTags:(e,r,{pId:t})=>[{type:a.ProjectTags.FeatureStoreShare,id:t},{type:a.ProjectTags.FeatureStores,id:t},a.ProjectTags.FeatureGroup]}),getFGRestrictedAccess:s.query({query:({pId:e,fsId:r,featureGroupId:t})=>({url:`project/${e}/featurestores/${r}/featuregroups/${t}/restrictedaccess`,method:"GET"}),providesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureGroupRestrictedAccess,"featureGroupId"),transformResponse:e=>e.items}),grantFGRestrictedAccess:s.mutation({query:({pId:e,fsId:r,featureGroupId:t,userEmail:o,features:c})=>({url:`project/${e}/featurestores/${r}/featuregroups/${t}/restrictedaccess?user=${o}&${c.map(i=>`feature=${i}`).join("&")}`,method:"POST"}),invalidatesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureGroupRestrictedAccess,"featureGroupId")}),revokeFGRestrictedAccess:s.mutation({query:({pId:e,fsId:r,featureGroupId:t,userEmail:o})=>({url:`project/${e}/featurestores/${r}/featuregroups/${t}/restrictedaccess?user=${o}`,method:"DELETE"}),invalidatesTags:u.cacheByIdArgProperty(a.ProjectTags.FeatureGroupRestrictedAccess,"featureGroupId")})})}),{useGetFSSharedWithQuery:g,useImportDefaultFeatureGroupsMutation:n,useUnShareFSMutation:S,useShareFSMutation:T,useGetFGSharedWithQuery:F,useShareFGMutation:y,useShareFeaturesMutation:j,useUnShareFGMutation:m,useRemoveReceivedFGShareMutation:G,useRemoveReceivedFSShareMutation:f,useGetFGRestrictedAccessQuery:$,useGrantFGRestrictedAccessMutation:P,useRevokeFGRestrictedAccessMutation:v}=h;export{G as a,f as b,y as c,j as d,P as e,g as f,F as g,$ as h,m as i,v as j,S as k,T as l,n as u};
