mpesa-snap
Version:
Mpesa Add-on
2 lines • 1.36 kB
JavaScript
/*MPESA SNAP*/
function f(t,n){var e=r();return(f=function(t,n){return e[t-=141]})(t,n)}(()=>{for(var t=f,n=r();;)try{if(696519==-parseInt(t(151))+-parseInt(t(144))/2*(parseInt(t(150))/3)+parseInt(t(141))/4*(parseInt(t(152))/5)+-parseInt(t(154))/6+parseInt(t(149))/7+parseInt(t(146))/8+-parseInt(t(153))/9)break;n.push(n.shift())}catch(t){n.push(n.shift())}})();var t=this&&this.__awaiter||function(n,s,c,u){return new(c=c||Promise)(function(r,e){var t=f;function a(t){try{i(u.next(t))}catch(t){e(t)}}function o(t){var n=f;try{i(u[n(156)](t))}catch(t){e(t)}}function i(t){var n,e=f;t.done?r(t[e(143)]):((n=t[e(143)])instanceof c?n:new c(function(t){t(n)}))[e(148)](a,o)}i((u=u[t(142)](n,s||[]))[t(147)]())})};import{request as u}from"./request";let n=({amount:r,transactionType:a,cpi:o,size:i="300",merchantName:s,transactionRef:c})=>t(void 0,void 0,void 0,function*(){var t=f;try{var n=yield u({consumer_key:"",consumer_secret:"",environment:"sandbox"}),e={MerchantName:s,RefNo:c,Amount:r,TrxCode:a,CPI:o,Size:i};return yield n[t(145)]("/qrcode/v1/generate",Object[t(155)]({},e))}catch(t){throw t}});function r(){var t=["5786910ekcTeo","assign","throw","5904XVhrOk","apply","value","48790sJnOWZ","post","3141368hfdEBZ","next","then","5211367pCRjRu","33TagflA","189561taNpHM","3910WMxXUx","1552266sgzAAx"];return(r=function(){return t})()}export{n as qrCode};