/*! Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one or more contributor license agreements. * Licensed under the Elastic License 2.0; you may not use this file except in compliance with the Elastic License 2.0. */ (window.apm_bundle_jsonpfunction=window.apm_bundle_jsonpfunction||[]).push([[0],{159:function(t,e,n){"use strict";n.d(e,"b",(function(){return l})),n.d(e,"a",(function(){return c}));var r=n(9),i=n(485),o=n.n(i),u=n(490),a=n.n(u),s=n(44);const f=new o.a({max:100,maxAge:36e5});function l(){f.reset()}async function c({http:t,uiSettings:e},n){const i=e.get(s.enableInspectEsQueries),o=function(t){const{pathname:e,method:n,body:r,query:i,headers:o}=t;return a()({pathname:e,method:n,body:r,query:i,headers:o})}(n),u=f.get(o);if(u)return u;const{pathname:l,method:c="get",...h}=function(t,e){const n=e&&Object(r.startsWith)(t.pathname,"/internal/apm"),{body:i,...o}=t;return{...o,...void 0!==i?{body:JSON.stringify(i)}:{},query:{...t.query,...n?{_inspect:!0}:{}}}}(n,i),p=c.toLowerCase(),d=await t[p](l,h);return function(t){return void 0!==t.isCachable?t.isCachable:!!(t.query&&t.query.start&&t.query.end)&&(Object(r.isString)(t.query.end)&&new Date(t.query.end).getTime()e.maxAge:t[c]&&n>t[c]}function _(t){if(t[s]>t[a])for(var e=t[d].tail;t[s]>t[a]&&null!==e;){var n=e.prev;E(t,e),e=n}}function E(t,e){if(e){var n=e.value;t[h]&&t[h](n.key,n.value),t[s]-=n.length,t[y].delete(n.key),t[d].removeNode(e)}}function A(t,e,n,r,i){this.key=t,this.value=e,this.length=n,this.now=r,this.maxAge=i||0}Object.defineProperty(w.prototype,"max",{set:function(t){(!t||"number"!=typeof t||t<=0)&&(t=1/0),this[a]=t,_(this)},get:function(){return this[a]},enumerable:!0}),Object.defineProperty(w.prototype,"allowStale",{set:function(t){this[l]=!!t},get:function(){return this[l]},enumerable:!0}),Object.defineProperty(w.prototype,"maxAge",{set:function(t){(!t||"number"!=typeof t||t<0)&&(t=0),this[c]=t,_(this)},get:function(){return this[c]},enumerable:!0}),Object.defineProperty(w.prototype,"lengthCalculator",{set:function(t){"function"!=typeof t&&(t=g),t!==this[f]&&(this[f]=t,this[s]=0,this[d].forEach((function(t){t.length=this[f](t.value,t.key),this[s]+=t.length}),this)),_(this)},get:function(){return this[f]},enumerable:!0}),Object.defineProperty(w.prototype,"length",{get:function(){return this[s]},enumerable:!0}),Object.defineProperty(w.prototype,"itemCount",{get:function(){return this[d].length},enumerable:!0}),w.prototype.rforEach=function(t,e){e=e||this;for(var n=this[d].tail;null!==n;){var r=n.prev;v(this,t,n,e),n=r}},w.prototype.forEach=function(t,e){e=e||this;for(var n=this[d].head;null!==n;){var r=n.next;v(this,t,n,e),n=r}},w.prototype.keys=function(){return this[d].toArray().map((function(t){return t.key}),this)},w.prototype.values=function(){return this[d].toArray().map((function(t){return t.value}),this)},w.prototype.reset=function(){this[h]&&this[d]&&this[d].length&&this[d].forEach((function(t){this[h](t.key,t.value)}),this),this[y]=new i,this[d]=new u,this[s]=0},w.prototype.dump=function(){return this[d].map((function(t){if(!m(this,t))return{k:t.key,v:t.value,e:t.now+(t.maxAge||0)}}),this).toArray().filter((function(t){return t}))},w.prototype.dumpLru=function(){return this[d]},w.prototype.inspect=function(t,e){var n="LRUCache {",r=!1;this[l]&&(n+="\n allowStale: true",r=!0);var i=this[a];i&&i!==1/0&&(r&&(n+=","),n+="\n max: "+o.inspect(i,e),r=!0);var u=this[c];u&&(r&&(n+=","),n+="\n maxAge: "+o.inspect(u,e),r=!0);var h=this[f];h&&h!==g&&(r&&(n+=","),n+="\n length: "+o.inspect(this[s],e),r=!0);var p=!1;return this[d].forEach((function(t){p?n+=",\n ":(r&&(n+=",\n"),p=!0,n+="\n ");var i=o.inspect(t.key).split("\n").join("\n "),a={value:t.value};t.maxAge!==u&&(a.maxAge=t.maxAge),h!==g&&(a.length=t.length),m(this,t)&&(a.stale=!0),a=o.inspect(a,e).split("\n").join("\n "),n+=i+" => "+a})),(p||r)&&(n+="\n"),n+="}"},w.prototype.set=function(t,e,n){var r=(n=n||this[c])?Date.now():0,i=this[f](e,t);if(this[y].has(t)){if(i>this[a])return E(this,this[y].get(t)),!1;var o=this[y].get(t).value;return this[h]&&(this[p]||this[h](t,o.value)),o.now=r,o.maxAge=n,o.value=e,this[s]+=i-o.length,o.length=i,this.get(t),_(this),!0}var u=new A(t,e,i,r,n);return u.length>this[a]?(this[h]&&this[h](t,e),!1):(this[s]+=u.length,this[d].unshift(u),this[y].set(t,this[d].head),_(this),!0)},w.prototype.has=function(t){return!!this[y].has(t)&&!m(this,this[y].get(t).value)},w.prototype.get=function(t){return b(this,t,!0)},w.prototype.peek=function(t){return b(this,t,!1)},w.prototype.pop=function(){var t=this[d].tail;return t?(E(this,t),t.value):null},w.prototype.del=function(t){E(this,this[y].get(t))},w.prototype.load=function(t){this.reset();for(var e=Date.now(),n=t.length-1;n>=0;n--){var r=t[n],i=r.e||0;if(0===i)this.set(r.k,r.v);else{var o=i-e;o>0&&this.set(r.k,r.v,o)}}},w.prototype.prune=function(){var t=this;this[y].forEach((function(e,n){b(t,n,!1)}))}},486:function(t,e,n){"pseudomap"===Object({IS_KIBANA_DISTRIBUTABLE:"true"}).npm_package_name&&"test"===Object({IS_KIBANA_DISTRIBUTABLE:"true"}).npm_lifecycle_script&&(Object({IS_KIBANA_DISTRIBUTABLE:"true"}).TEST_PSEUDOMAP="true"),"function"!=typeof Map||Object({IS_KIBANA_DISTRIBUTABLE:"true"}).TEST_PSEUDOMAP?t.exports=n(487):t.exports=Map},487:function(t,e){var n=Object.prototype.hasOwnProperty;function r(t){if(!(this instanceof r))throw new TypeError("Constructor PseudoMap requires 'new'");if(this.clear(),t)if(t instanceof r||"function"==typeof Map&&t instanceof Map)t.forEach((function(t,e){this.set(e,t)}),this);else{if(!Array.isArray(t))throw new TypeError("invalid argument");t.forEach((function(t){this.set(t[0],t[1])}),this)}}function i(t,e){return t===e||t!=t&&e!=e}function o(t,e,n){this.key=t,this.value=e,this._index=n}function u(t,e){for(var r=0,o="_"+e,u=o;n.call(t,u);u=o+r++)if(i(t[u].key,e))return t[u]}t.exports=r,r.prototype.forEach=function(t,e){e=e||this,Object.keys(this._data).forEach((function(n){"size"!==n&&t.call(e,this._data[n].value,this._data[n].key)}),this)},r.prototype.has=function(t){return!!u(this._data,t)},r.prototype.get=function(t){var e=u(this._data,t);return e&&e.value},r.prototype.set=function(t,e){!function(t,e,r){for(var u=0,a="_"+e,s=a;n.call(t,s);s=a+u++)if(i(t[s].key,e))return void(t[s].value=r);t.size++,t[s]=new o(e,r,s)}(this._data,t,e)},r.prototype.delete=function(t){var e=u(this._data,t);e&&(delete this._data[e._index],this._data.size--)},r.prototype.clear=function(){var t=Object.create(null);t.size=0,Object.defineProperty(this,"_data",{value:t,enumerable:!1,configurable:!0,writable:!1})},Object.defineProperty(r.prototype,"size",{get:function(){return this._data.size},set:function(t){},enumerable:!0,configurable:!0}),r.prototype.values=r.prototype.keys=r.prototype.entries=function(){throw new Error("iterators are not implemented in this version")}},488:function(t,e,n){t.exports=n(28)(2948)},489:function(t,e){function n(t){var e=this;if(e instanceof n||(e=new n),e.tail=null,e.head=null,e.length=0,t&&"function"==typeof t.forEach)t.forEach((function(t){e.push(t)}));else if(arguments.length>0)for(var r=0,i=arguments.length;r1)n=e;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");r=this.head.next,n=this.head.value}for(var i=0;null!==r;i++)n=t(n,r.value,i),r=r.next;return n},n.prototype.reduceReverse=function(t,e){var n,r=this.tail;if(arguments.length>1)n=e;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");r=this.tail.prev,n=this.tail.value}for(var i=this.length-1;null!==r;i--)n=t(n,r.value,i),r=r.prev;return n},n.prototype.toArray=function(){for(var t=new Array(this.length),e=0,n=this.head;null!==n;e++)t[e]=n.value,n=n.next;return t},n.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,n=this.tail;null!==n;e++)t[e]=n.value,n=n.prev;return t},n.prototype.slice=function(t,e){(e=e||this.length)<0&&(e+=this.length),(t=t||0)<0&&(t+=this.length);var r=new n;if(ethis.length&&(e=this.length);for(var i=0,o=this.head;null!==o&&ithis.length&&(e=this.length);for(var i=this.length,o=this.tail;null!==o&&i>e;i--)o=o.prev;for(;null!==o&&i>t;i--,o=o.prev)r.push(o.value);return r},n.prototype.reverse=function(){for(var t=this.head,e=this.tail,n=t;null!==n;n=n.prev){var r=n.prev;n.prev=n.next,n.next=r}return this.head=e,this.tail=t,this}},490:function(t,e,n){var r;t.exports=function t(e,n,i){function o(a,s){if(!n[a]){if(!e[a]){if(!s&&"function"==typeof r&&r)return r(a,!0);if(u)return u(a,!0);throw new Error("Cannot find module '"+a+"'")}var f=n[a]={exports:{}};e[a][0].call(f.exports,(function(t){return o(e[a][1][t]||t)}),f,f.exports,t,e,n,i)}return n[a].exports}for(var u="function"==typeof r&&r,a=0;a=0)return this.dispatch("[CIRCULAR:"+a+"]");if(n.push(e),void 0!==o&&o.isBuffer&&o.isBuffer(e))return r("buffer:"),r(e);if("object"===u||"function"===u){var s=Object.keys(e);t.unorderedObjects&&(s=s.sort()),!1===t.respectType||d(e)||s.splice(0,0,"prototype","__proto__","constructor"),t.excludeKeys&&(s=s.filter((function(e){return!t.excludeKeys(e)}))),r("object:"+s.length+":");var f=this;return s.forEach((function(n){f.dispatch(n),r(":"),t.excludeValues||f.dispatch(e[n]),r(",")}))}if(!this["_"+u]){if(t.ignoreUnknown)return r("["+u+"]");throw new Error('Unknown object type "'+u+'"')}this["_"+u](e)},_array:function(e,i){i=void 0!==i?i:!1!==t.unorderedArrays;var o=this;if(r("array:"+e.length+":"),!i||e.length<=1)return e.forEach((function(t){return o.dispatch(t)}));var u=[],a=e.map((function(e){var r=new g,i=n.slice();return y(t,r,i).dispatch(e),u=u.concat(i.slice(n.length)),r.read().toString()}));return n=n.concat(u),a.sort(),this._array(a,!1)},_date:function(t){return r("date:"+t.toJSON())},_symbol:function(t){return r("symbol:"+t.toString())},_error:function(t){return r("error:"+t.toString())},_boolean:function(t){return r("bool:"+t.toString())},_string:function(t){r("string:"+t.length+":"),r(t.toString())},_function:function(e){r("fn:"),d(e)?this.dispatch("[native]"):this.dispatch(e.toString()),!1!==t.respectFunctionNames&&this.dispatch("function-name:"+String(e.name)),t.respectFunctionProperties&&this._object(e)},_number:function(t){return r("number:"+t.toString())},_xml:function(t){return r("xml:"+t.toString())},_null:function(){return r("Null")},_undefined:function(){return r("Undefined")},_regexp:function(t){return r("regex:"+t.toString())},_uint8array:function(t){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(t))},_uint8clampedarray:function(t){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(t))},_int8array:function(t){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(t))},_uint16array:function(t){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(t))},_int16array:function(t){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(t))},_uint32array:function(t){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(t))},_int32array:function(t){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(t))},_float32array:function(t){return r("float32array:"),this.dispatch(Array.prototype.slice.call(t))},_float64array:function(t){return r("float64array:"),this.dispatch(Array.prototype.slice.call(t))},_arraybuffer:function(t){return r("arraybuffer:"),this.dispatch(new Uint8Array(t))},_url:function(t){return r("url:"+t.toString())},_map:function(e){r("map:");var n=Array.from(e);return this._array(n,!1!==t.unorderedSets)},_set:function(e){r("set:");var n=Array.from(e);return this._array(n,!1!==t.unorderedSets)},_blob:function(){if(t.ignoreUnknown)return r("[blob]");throw Error('Hashing Blob objects is currently not supported\n(see https://github.com/puleos/object-hash/issues/26)\nUse "options.replacer" or "options.ignoreUnknown"\n')},_domwindow:function(){return r("domwindow")},_process:function(){return r("process")},_timer:function(){return r("timer")},_pipe:function(){return r("pipe")},_tcp:function(){return r("tcp")},_udp:function(){return r("udp")},_tty:function(){return r("tty")},_statwatcher:function(){return r("statwatcher")},_securecontext:function(){return r("securecontext")},_connection:function(){return r("connection")},_zlib:function(){return r("zlib")},_context:function(){return r("context")},_nodescript:function(){return r("nodescript")},_httpparser:function(){return r("httpparser")},_dataview:function(){return r("dataview")},_signal:function(){return r("signal")},_fsevent:function(){return r("fsevent")},_tlswrap:function(){return r("tlswrap")}}}function g(){return{buf:"",write:function(t){this.buf+=t},end:function(t){this.buf+=t},read:function(){return this.buf}}}var w=t("crypto");(n=e.exports=h).sha1=function(t){return h(t)},n.keys=function(t){return h(t,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},n.MD5=function(t){return h(t,{algorithm:"md5",encoding:"hex"})},n.keysMD5=function(t){return h(t,{algorithm:"md5",encoding:"hex",excludeValues:!0})};var v=w.getHashes?w.getHashes().slice():["sha1","md5"];v.push("passthrough");var b=["buffer","hex","binary","base64"];n.writeToStream=function(t,e,n){return void 0===n&&(n=e,e={}),y(e=p(t,e),n).dispatch(t)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_e8180ef5.js","/")},{buffer:3,crypto:5,lYpoI2:10}],2:[function(t,e,n){(function(t,e,r,i,o,u,a,s,f){var l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(t){"use strict";function e(t){var e=t.charCodeAt(0);return e===r||e===s?62:e===i||e===f?63:e0)throw new Error("Invalid string. Length must be a multiple of 4");var l=t.length;s="="===t.charAt(l-2)?2:"="===t.charAt(l-1)?1:0,f=new n(3*t.length/4-s),u=s>0?t.length-4:t.length;var c=0;for(i=0,o=0;i>16),r((65280&a)>>8),r(255&a);return 2===s?r(255&(a=e(t.charAt(i))<<2|e(t.charAt(i+1))>>4)):1===s&&(r((a=e(t.charAt(i))<<10|e(t.charAt(i+1))<<4|e(t.charAt(i+2))>>2)>>8&255),r(255&a)),f},t.fromByteArray=function(t){function e(t){return l.charAt(t)}function n(t){return e(t>>18&63)+e(t>>12&63)+e(t>>6&63)+e(63&t)}var r,i,o,u=t.length%3,a="";for(r=0,o=t.length-u;r>2),a+=e(i<<4&63),a+="==";break;case 2:a+=e((i=(t[t.length-2]<<8)+t[t.length-1])>>10),a+=e(i>>4&63),a+=e(i<<2&63),a+="="}return a}}(void 0===n?this.base64js={}:n)}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:10}],3:[function(t,e,n){(function(e,r,i,o,u,a,s,f,l){function i(t,e,n){if(!(this instanceof i))return new i(t,e,n);var r,o,u,a=typeof t;if("base64"===e&&"string"===a)for(t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t);t.length%4!=0;)t+="=";if("number"===a)r=j(t);else if("string"===a)r=i.byteLength(t,e);else{if("object"!==a)throw new Error("First argument needs to be a number, array or string.");r=j(t.length)}if(i._useTypedArrays?o=i._augment(new Uint8Array(r)):((o=this).length=r,o._isBuffer=!0),i._useTypedArrays&&"number"==typeof t.byteLength)o._set(t);else if(function(t){return k(t)||i.isBuffer(t)||t&&"object"==typeof t&&"number"==typeof t.length}(t))for(u=0;uo&&(r=o):r=o;var u=e.length;P(u%2==0,"Invalid hex string"),r>u/2&&(r=u/2);for(var a=0;a>8,r=e%256,i.push(r),i.push(n);return i}(e),t,n,r)}function g(t,e,n){var r="";n=Math.min(t.length,n);for(var i=e;i=o))return n?(i=t[e],e+1=o))return n?(e+2>>0)):(e+1>>0),i}function b(t,e,n,r){if(r||(P("boolean"==typeof n,"missing or invalid endian"),P(null!=e,"missing offset"),P(e+1=t.length)){var i=w(t,e,n,!0);return 32768&i?-1*(65535-i+1):i}}function m(t,e,n,r){if(r||(P("boolean"==typeof n,"missing or invalid endian"),P(null!=e,"missing offset"),P(e+3=t.length)){var i=v(t,e,n,!0);return 2147483648&i?-1*(4294967295-i+1):i}}function _(t,e,n,r){return r||(P("boolean"==typeof n,"missing or invalid endian"),P(e+3=o))for(var u=0,a=Math.min(o-n,2);u>>8*(r?u:1-u)}function I(t,e,n,r,i){i||(P(null!=e,"missing value"),P("boolean"==typeof r,"missing or invalid endian"),P(null!=n,"missing offset"),P(n+3=o))for(var u=0,a=Math.min(o-n,4);u>>8*(r?u:3-u)&255}function x(t,e,n,r,i){i||(P(null!=e,"missing value"),P("boolean"==typeof r,"missing or invalid endian"),P(null!=n,"missing offset"),P(n+1=t.length||A(t,e>=0?e:65535+e+1,n,r,i)}function B(t,e,n,r,i){i||(P(null!=e,"missing value"),P("boolean"==typeof r,"missing or invalid endian"),P(null!=n,"missing offset"),P(n+3=t.length||I(t,e>=0?e:4294967295+e+1,n,r,i)}function S(t,e,n,r,i){i||(P(null!=e,"missing value"),P("boolean"==typeof r,"missing or invalid endian"),P(null!=n,"missing offset"),P(n+3=t.length||q.write(t,e,n,r,23,4)}function L(t,e,n,r,i){i||(P(null!=e,"missing value"),P("boolean"==typeof r,"missing or invalid endian"),P(null!=n,"missing offset"),P(n+7=t.length||q.write(t,e,n,r,52,8)}function U(t,e,n){return"number"!=typeof t?n:(t=~~t)>=e?e:t>=0||(t+=e)>=0?t:0}function j(t){return(t=~~Math.ceil(+t))<0?0:t}function k(t){return(Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)})(t)}function C(t){return t<16?"0"+t.toString(16):t.toString(16)}function T(t){for(var e=[],n=0;n=55296&&r<=57343&&n++;for(var o=encodeURIComponent(t.slice(i,n+1)).substr(1).split("%"),u=0;u=e.length||i>=t.length);i++)e[i+n]=t[i];return i}function M(t){try{return decodeURIComponent(t)}catch(t){return String.fromCharCode(65533)}}function D(t,e){P("number"==typeof t,"cannot write a non-number as a number"),P(t>=0,"specified a negative value for writing an unsigned value"),P(t<=e,"value is larger than maximum value for type"),P(Math.floor(t)===t,"value has a fractional component")}function F(t,e,n){P("number"==typeof t,"cannot write a non-number as a number"),P(t<=e,"value larger than maximum allowed value"),P(t>=n,"value smaller than minimum allowed value"),P(Math.floor(t)===t,"value has a fractional component")}function Y(t,e,n){P("number"==typeof t,"cannot write a non-number as a number"),P(t<=e,"value larger than maximum allowed value"),P(t>=n,"value smaller than minimum allowed value")}function P(t,e){if(!t)throw new Error(e||"Failed assertion")}var R=t("base64-js"),q=t("ieee754");n.Buffer=i,n.SlowBuffer=i,n.INSPECT_MAX_BYTES=50,i.poolSize=8192,i._useTypedArrays=function(){try{var t=new ArrayBuffer(0),e=new Uint8Array(t);return e.foo=function(){return 42},42===e.foo()&&"function"==typeof e.subarray}catch(t){return!1}}(),i.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},i.isBuffer=function(t){return!(null==t||!t._isBuffer)},i.byteLength=function(t,e){var n;switch(t+="",e||"utf8"){case"hex":n=t.length/2;break;case"utf8":case"utf-8":n=T(t).length;break;case"ascii":case"binary":case"raw":n=t.length;break;case"base64":n=N(t).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":n=2*t.length;break;default:throw new Error("Unknown encoding")}return n},i.concat=function(t,e){if(P(k(t),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===t.length)return new i(0);if(1===t.length)return t[0];var n;if("number"!=typeof e)for(e=0,n=0;nu&&(n=u):n=u,r=String(r||"utf8").toLowerCase()){case"hex":o=c(this,t,e,n);break;case"utf8":case"utf-8":o=h(this,t,e,n);break;case"ascii":o=p(this,t,e,n);break;case"binary":o=function(t,e,n,r){return p(t,e,n,r)}(this,t,e,n);break;case"base64":o=d(this,t,e,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":o=y(this,t,e,n);break;default:throw new Error("Unknown encoding")}return o},i.prototype.toString=function(t,e,n){var r,i=this;if(t=String(t||"utf8").toLowerCase(),e=Number(e)||0,(n=void 0!==n?Number(n):n=i.length)===e)return"";switch(t){case"hex":r=function(t,e,n){var r=t.length;(!e||e<0)&&(e=0),(!n||n<0||n>r)&&(n=r);for(var i="",o=e;o=n,"sourceEnd < sourceStart"),P(e>=0&&e=0&&n=0&&r<=o.length,"sourceEnd out of bounds"),r>this.length&&(r=this.length),t.length-e=this.length))return this[t]},i.prototype.readUInt16LE=function(t,e){return w(this,t,!0,e)},i.prototype.readUInt16BE=function(t,e){return w(this,t,!1,e)},i.prototype.readUInt32LE=function(t,e){return v(this,t,!0,e)},i.prototype.readUInt32BE=function(t,e){return v(this,t,!1,e)},i.prototype.readInt8=function(t,e){if(e||(P(null!=t,"missing offset"),P(t=this.length))return 128&this[t]?-1*(255-this[t]+1):this[t]},i.prototype.readInt16LE=function(t,e){return b(this,t,!0,e)},i.prototype.readInt16BE=function(t,e){return b(this,t,!1,e)},i.prototype.readInt32LE=function(t,e){return m(this,t,!0,e)},i.prototype.readInt32BE=function(t,e){return m(this,t,!1,e)},i.prototype.readFloatLE=function(t,e){return _(this,t,!0,e)},i.prototype.readFloatBE=function(t,e){return _(this,t,!1,e)},i.prototype.readDoubleLE=function(t,e){return E(this,t,!0,e)},i.prototype.readDoubleBE=function(t,e){return E(this,t,!1,e)},i.prototype.writeUInt8=function(t,e,n){n||(P(null!=t,"missing value"),P(null!=e,"missing offset"),P(e=this.length||(this[e]=t)},i.prototype.writeUInt16LE=function(t,e,n){A(this,t,e,!0,n)},i.prototype.writeUInt16BE=function(t,e,n){A(this,t,e,!1,n)},i.prototype.writeUInt32LE=function(t,e,n){I(this,t,e,!0,n)},i.prototype.writeUInt32BE=function(t,e,n){I(this,t,e,!1,n)},i.prototype.writeInt8=function(t,e,n){n||(P(null!=t,"missing value"),P(null!=e,"missing offset"),P(e=this.length||(t>=0?this.writeUInt8(t,e,n):this.writeUInt8(255+t+1,e,n))},i.prototype.writeInt16LE=function(t,e,n){x(this,t,e,!0,n)},i.prototype.writeInt16BE=function(t,e,n){x(this,t,e,!1,n)},i.prototype.writeInt32LE=function(t,e,n){B(this,t,e,!0,n)},i.prototype.writeInt32BE=function(t,e,n){B(this,t,e,!1,n)},i.prototype.writeFloatLE=function(t,e,n){S(this,t,e,!0,n)},i.prototype.writeFloatBE=function(t,e,n){S(this,t,e,!1,n)},i.prototype.writeDoubleLE=function(t,e,n){L(this,t,e,!0,n)},i.prototype.writeDoubleBE=function(t,e,n){L(this,t,e,!1,n)},i.prototype.fill=function(t,e,n){if(t||(t=0),e||(e=0),n||(n=this.length),"string"==typeof t&&(t=t.charCodeAt(0)),P("number"==typeof t&&!isNaN(t),"value is not a number"),P(n>=e,"end < start"),n!==e&&0!==this.length){P(e>=0&&e=0&&n<=this.length,"end out of bounds");for(var r=e;r"},i.prototype.toArrayBuffer=function(){if("undefined"!=typeof Uint8Array){if(i._useTypedArrays)return new i(this).buffer;for(var t=new Uint8Array(this.length),e=0,n=t.length;ew?e=t(e):e.length>5]|=128<>>9<<4)]=e;for(var n=1732584193,r=-271733879,i=-1732584194,o=271733878,u=0;u>>32-e}(w(w(e,t),w(r,o)),i),n)}function p(t,e,n,r,i,o,u){return h(e&n|~e&r,t,e,i,o,u)}function d(t,e,n,r,i,o,u){return h(e&r|n&~r,t,e,i,o,u)}function y(t,e,n,r,i,o,u){return h(e^n^r,t,e,i,o,u)}function g(t,e,n,r,i,o,u){return h(n^(e|~r),t,e,i,o,u)}function w(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}var v=t("./helpers");e.exports=function(t){return v.hash(t,c,16)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],7:[function(t,e,n){(function(t,n,r,i,o,u,a,s,f){!function(){var t,n;t=function(t){for(var e,n=new Array(t),r=0;r>>((3&r)<<3)&255;return n},this.crypto&&crypto.getRandomValues&&(n=function(t){var e=new Uint8Array(t);return crypto.getRandomValues(e),e}),e.exports=n||t}()}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],8:[function(t,e,n){(function(n,r,i,o,u,a,s,f,l){function c(t,e){t[e>>5]|=128<<24-e%32,t[15+(e+64>>9<<4)]=e;for(var n=Array(80),r=1732584193,i=-271733879,o=-1732584194,u=271733878,a=-1009589776,s=0;s>16)+(e>>16)+(n>>16)<<16|65535&n}function y(t,e){return t<>>32-e}var g=t("./helpers");e.exports=function(t){return g.hash(t,c,20,!0)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],9:[function(t,e,n){(function(n,r,i,o,u,a,s,f,l){var c=t("./helpers"),h=function(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n},p=function(t,e){return t>>>e|t<<32-e},d=function(t,e){return t>>>e},y=function(t,e,n){return t&e^~t&n},g=function(t,e,n){return t&e^t&n^e&n},w=function(t){return p(t,2)^p(t,13)^p(t,22)},v=function(t){return p(t,6)^p(t,11)^p(t,25)},b=function(t){return p(t,7)^p(t,18)^d(t,3)},m=function(t){return p(t,17)^p(t,19)^d(t,10)},_=function(t,e){var n,r,i,o,u,a,s,f,l,c,p=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298),d=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),_=new Array(64);t[e>>5]|=128<<24-e%32,t[15+(e+64>>9<<4)]=e;for(var E=0;E0)&&n.shift()()}),!0),function(t){n.push(t),window.postMessage("process-tick","*")}}return function(t){setTimeout(t,0)}}(),t.title="browser",t.browser=!0,t.env={},t.argv=[],t.on=l,t.addListener=l,t.once=l,t.off=l,t.removeListener=l,t.removeAllListeners=l,t.emit=l,t.binding=function(t){throw new Error("process.binding is not supported")},t.cwd=function(){return"/"},t.chdir=function(t){throw new Error("process.chdir is not supported")}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/process/browser.js","/node_modules/gulp-browserify/node_modules/process")},{buffer:3,lYpoI2:10}],11:[function(t,e,n){(function(t,e,r,i,o,u,a,s,f){n.read=function(t,e,n,r,i){var o,u,a=8*i-r-1,s=(1<>1,l=-7,c=n?i-1:0,h=n?-1:1,p=t[e+c];for(c+=h,o=p&(1<<-l)-1,p>>=-l,l+=a;l>0;o=256*o+t[e+c],c+=h,l-=8);for(u=o&(1<<-l)-1,o>>=-l,l+=r;l>0;u=256*u+t[e+c],c+=h,l-=8);if(0===o)o=1-f;else{if(o===s)return u?NaN:1/0*(p?-1:1);u+=Math.pow(2,r),o-=f}return(p?-1:1)*u*Math.pow(2,o-r)},n.write=function(t,e,n,r,i,o){var u,a,s,f=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,d=r?1:-1,y=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,u=l):(u=Math.floor(Math.log(e)/Math.LN2),e*(s=Math.pow(2,-u))<1&&(u--,s*=2),(e+=u+c>=1?h/s:h*Math.pow(2,1-c))*s>=2&&(u++,s/=2),u+c>=l?(a=0,u=l):u+c>=1?(a=(e*s-1)*Math.pow(2,i),u+=c):(a=e*Math.pow(2,c-1)*Math.pow(2,i),u=0));i>=8;t[n+p]=255&a,p+=d,a/=256,i-=8);for(u=u<0;t[n+p]=255&u,p+=d,u/=256,f-=8);t[n+p-d]|=128*y}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/ieee754/index.js","/node_modules/ieee754")},{buffer:3,lYpoI2:10}]},{},[1])(1)},82:function(t,e,n){"use strict";n.r(e),n.d(e,"callApmApi",(function(){return i})),n.d(e,"createCallApmApi",(function(){return o}));var r=n(159);let i=()=>{throw new Error("callApmApi has to be initialized before used. Call createCallApmApi first.")};function o(t){i=(e,n)=>{const{params:i}=n,{method:o,pathname:u,version:a}=function(t,e={}){const{method:n,pathname:r,version:i}=function(t){var e;const n=t.split(" "),r=n[0].trim().toLowerCase(),i=n[1].trim(),o=null===(e=n[2])||void 0===e?void 0:e.trim();if(!["get","post","put","delete"].includes(r))throw new Error(`Endpoint ${t} was not prefixed with a valid HTTP method`);if(!o&&i.startsWith("/api"))throw new Error(`Missing version for public endpoint ${t}`);return{method:r,pathname:i,version:o}}(t);return{method:n,pathname:Object.keys(e).reduce(((t,n)=>t.replace(`{${n}}`,e[n])),r),version:i}}(e,null==i?void 0:i.path);return Object(r.a)(t,{...n,method:o,pathname:u,body:null==i?void 0:i.body,query:null==i?void 0:i.query,version:a})}}}}]);