"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function M(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}var B={exports:{}},_={exports:{}};(function(){var c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",h={rotl:function(f,a){return f<>>32-a},rotr:function(f,a){return f<<32-a|f>>>a},endian:function(f){if(f.constructor==Number)return h.rotl(f,8)&16711935|h.rotl(f,24)&4278255360;for(var a=0;a0;f--)a.push(Math.floor(Math.random()*256));return a},bytesToWords:function(f){for(var a=[],i=0,s=0;i>>5]|=f[i]<<24-s%32;return a},wordsToBytes:function(f){for(var a=[],i=0;i>>5]>>>24-i%32&255);return a},bytesToHex:function(f){for(var a=[],i=0;i>>4).toString(16)),a.push((f[i]&15).toString(16));return a.join("")},hexToBytes:function(f){for(var a=[],i=0;i>>6*(3-l)&63)):a.push("=");return a.join("")},base64ToBytes:function(f){f=f.replace(/[^A-Z0-9+\/]/ig,"");for(var a=[],i=0,s=0;i>>6-s*2);return a}};_.exports=h})();var D=_.exports,T={utf8:{stringToBytes:function(c){return T.bin.stringToBytes(unescape(encodeURIComponent(c)))},bytesToString:function(c){return decodeURIComponent(escape(T.bin.bytesToString(c)))}},bin:{stringToBytes:function(c){for(var h=[],f=0;f * @license MIT */var w=function(c){return c!=null&&(C(c)||H(c)||!!c._isBuffer)};function C(c){return!!c.constructor&&typeof c.constructor.isBuffer=="function"&&c.constructor.isBuffer(c)}function H(c){return typeof c.readFloatLE=="function"&&typeof c.slice=="function"&&C(c.slice(0,0))}(function(){var c=D,h=F.utf8,f=w,a=F.bin,i=function(s,l){s.constructor==String?l&&l.encoding==="binary"?s=a.stringToBytes(s):s=h.stringToBytes(s):f(s)?s=Array.prototype.slice.call(s,0):!Array.isArray(s)&&s.constructor!==Uint8Array&&(s=s.toString());for(var e=c.bytesToWords(s),S=s.length*8,n=1732584193,r=-271733879,o=-1732584194,t=271733878,u=0;u>>24)&16711935|(e[u]<<24|e[u]>>>8)&4278255360;e[S>>>5]|=128<>>9<<4)+14]=S;for(var p=i._ff,v=i._gg,g=i._hh,d=i._ii,u=0;u>>0,r=r+A>>>0,o=o+E>>>0,t=t+I>>>0}return c.endian([n,r,o,t])};i._ff=function(s,l,e,S,n,r,o){var t=s+(l&e|~l&S)+(n>>>0)+o;return(t<>>32-r)+l},i._gg=function(s,l,e,S,n,r,o){var t=s+(l&S|e&~S)+(n>>>0)+o;return(t<>>32-r)+l},i._hh=function(s,l,e,S,n,r,o){var t=s+(l^e^S)+(n>>>0)+o;return(t<>>32-r)+l},i._ii=function(s,l,e,S,n,r,o){var t=s+(e^(l|~S))+(n>>>0)+o;return(t<>>32-r)+l},i._blocksize=16,i._digestsize=16,B.exports=function(s,l){if(s==null)throw new Error("Illegal argument "+s);var e=c.wordsToBytes(i(s,l));return l&&l.asBytes?e:l&&l.asString?a.bytesToString(e):c.bytesToHex(e)}})();var O=B.exports;const P=M(O);var y=(c=>(c.CreateSession="createsession",c))(y||{}),x=(c=>(c.SmitePC="SMITE_PC",c))(x||{});function z(c){const h=c.getUTCFullYear().toString(),f=(c.getUTCMonth()+1).toString().padStart(2,"0"),a=c.getUTCDate().toString().padStart(2,"0"),i=c.getUTCHours().toString().padStart(2,"0"),s=c.getUTCMinutes().toString().padStart(2,"0"),l=c.getUTCSeconds().toString().padStart(2,"0");return h+f+a+i+s+l}function G(c,h,f,a){return P(c+f+h+a)}async function R(c){if(process.env[c]===void 0){const h=z(new Date),f=await fetch("https://api.smitegame.com/smiteapi.svc/"+y.CreateSession+"Json/"+process.env.DEV_ID+"/"+G(process.env.DEV_ID||"",process.env.AUTH_KEY||"",y.CreateSession,h)+"/"+h).then(a=>a.json());process.env[c]=f.session_id}return process.env[c]||""}exports.Method=y;exports.Platform=x;exports.create=R;