var y=Object.create;var s=Object.defineProperty;var P=Object.getOwnPropertyDescriptor;var b=Object.getOwnPropertyNames;var w=Object.getPrototypeOf,k=Object.prototype.hasOwnProperty;var A=(t,e)=>{for(var o in e)s(t,o,{get:e[o],enumerable:!0})},x=(t,e,o,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of b(e))!k.call(t,r)&&r!==o&&s(t,r,{get:()=>e[r],enumerable:!(a=P(e,r))||a.enumerable});return t};var f=(t,e,o)=>(o=t!=null?y(w(t)):{},x(e||!t||!t.__esModule?s(o,"default",{value:t,enumerable:!0}):o,t)),C=t=>x(s({},"__esModule",{value:!0}),t);var d=(t,e,o)=>new Promise((a,r)=>{var h=n=>{try{i(o.next(n))}catch(p){r(p)}},l=n=>{try{i(o.throw(n))}catch(p){r(p)}},i=n=>n.done?a(n.value):Promise.resolve(n.value).then(h,l);i((o=o.apply(t,e)).next())});var _={};A(_,{getSurvey:()=>S,submitSurvey:()=>K});module.exports=C(_);var v=f(require("axios"),1);var c=require("react"),I=require("react/jsx-runtime"),R=(0,c.createContext)(void 0),u="production";var m=u==="development"?"https://qa-api-v2.bandit.network/sdk":"https://api-v2.bandit.network/sdk";var S=t=>d(void 0,null,function*(){try{return(yield v.default.get(`${m}/users/survey?limit=10`,{headers:{"X-API-KEY":t}})).data}catch(e){throw e}}),K=(t,e,o,a)=>d(void 0,null,function*(){try{return(yield v.default.post(`${m}/users/${e}/survey`,{id:o,rating:a},{headers:{"X-API-KEY":t}})).data}catch(r){throw r}});0&&(module.exports={getSurvey,submitSurvey});
