//#region rolldown:runtime
var __create = Object.create;
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __getProtoOf = Object.getPrototypeOf;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __commonJS = (cb, mod) => function() {
	return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
};
var __copyProps = (to, from, except, desc) => {
	if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
		key = keys[i];
		if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
			get: ((k) => from[k]).bind(null, key),
			enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
		});
	}
	return to;
};
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
	value: mod,
	enumerable: true
}) : target, mod));

//#endregion
let node_crypto = require("node:crypto");
node_crypto = __toESM(node_crypto);

//#region ../../node_modules/@1password/sdk-core/nodejs/core.js
var require_core$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk-core/nodejs/core.js": ((exports, module) => {
	let imports = {};
	imports["__wbindgen_placeholder__"] = module.exports;
	let wasm;
	const { TextDecoder: TextDecoder$1, TextEncoder: TextEncoder$1 } = require("util");
	let cachedTextDecoder = new TextDecoder$1("utf-8", {
		ignoreBOM: true,
		fatal: true
	});
	cachedTextDecoder.decode();
	let cachedUint8ArrayMemory0 = null;
	function getUint8ArrayMemory0() {
		if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
		return cachedUint8ArrayMemory0;
	}
	function getStringFromWasm0(ptr, len) {
		ptr = ptr >>> 0;
		return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
	}
	function addToExternrefTable0(obj) {
		const idx = wasm.__externref_table_alloc();
		wasm.__wbindgen_export_2.set(idx, obj);
		return idx;
	}
	function handleError(f, args) {
		try {
			return f.apply(this, args);
		} catch (e) {
			const idx = addToExternrefTable0(e);
			wasm.__wbindgen_exn_store(idx);
		}
	}
	function getArrayU8FromWasm0(ptr, len) {
		ptr = ptr >>> 0;
		return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
	}
	function isLikeNone(x) {
		return x === void 0 || x === null;
	}
	let WASM_VECTOR_LEN = 0;
	let cachedTextEncoder = new TextEncoder$1("utf-8");
	const encodeString = typeof cachedTextEncoder.encodeInto === "function" ? function(arg, view) {
		return cachedTextEncoder.encodeInto(arg, view);
	} : function(arg, view) {
		const buf = cachedTextEncoder.encode(arg);
		view.set(buf);
		return {
			read: arg.length,
			written: buf.length
		};
	};
	function passStringToWasm0(arg, malloc, realloc) {
		if (realloc === void 0) {
			const buf = cachedTextEncoder.encode(arg);
			const ptr$1 = malloc(buf.length, 1) >>> 0;
			getUint8ArrayMemory0().subarray(ptr$1, ptr$1 + buf.length).set(buf);
			WASM_VECTOR_LEN = buf.length;
			return ptr$1;
		}
		let len = arg.length;
		let ptr = malloc(len, 1) >>> 0;
		const mem = getUint8ArrayMemory0();
		let offset = 0;
		for (; offset < len; offset++) {
			const code = arg.charCodeAt(offset);
			if (code > 127) break;
			mem[ptr + offset] = code;
		}
		if (offset !== len) {
			if (offset !== 0) arg = arg.slice(offset);
			ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
			const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
			const ret = encodeString(arg, view);
			offset += ret.written;
			ptr = realloc(ptr, len, offset, 1) >>> 0;
		}
		WASM_VECTOR_LEN = offset;
		return ptr;
	}
	let cachedDataViewMemory0 = null;
	function getDataViewMemory0() {
		if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || cachedDataViewMemory0.buffer.detached === void 0 && cachedDataViewMemory0.buffer !== wasm.memory.buffer) cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
		return cachedDataViewMemory0;
	}
	const CLOSURE_DTORS = typeof FinalizationRegistry === "undefined" ? {
		register: () => {},
		unregister: () => {}
	} : new FinalizationRegistry((state) => {
		wasm.__wbindgen_export_5.get(state.dtor)(state.a, state.b);
	});
	function makeMutClosure(arg0, arg1, dtor, f) {
		const state = {
			a: arg0,
			b: arg1,
			cnt: 1,
			dtor
		};
		const real = (...args) => {
			state.cnt++;
			const a = state.a;
			state.a = 0;
			try {
				return f(a, state.b, ...args);
			} finally {
				if (--state.cnt === 0) {
					wasm.__wbindgen_export_5.get(state.dtor)(a, state.b);
					CLOSURE_DTORS.unregister(state);
				} else state.a = a;
			}
		};
		real.original = state;
		CLOSURE_DTORS.register(real, state, state);
		return real;
	}
	function debugString(val) {
		const type = typeof val;
		if (type == "number" || type == "boolean" || val == null) return `${val}`;
		if (type == "string") return `"${val}"`;
		if (type == "symbol") {
			const description = val.description;
			if (description == null) return "Symbol";
			else return `Symbol(${description})`;
		}
		if (type == "function") {
			const name = val.name;
			if (typeof name == "string" && name.length > 0) return `Function(${name})`;
			else return "Function";
		}
		if (Array.isArray(val)) {
			const length = val.length;
			let debug = "[";
			if (length > 0) debug += debugString(val[0]);
			for (let i = 1; i < length; i++) debug += ", " + debugString(val[i]);
			debug += "]";
			return debug;
		}
		const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
		let className;
		if (builtInMatches && builtInMatches.length > 1) className = builtInMatches[1];
		else return toString.call(val);
		if (className == "Object") try {
			return "Object(" + JSON.stringify(val) + ")";
		} catch (_) {
			return "Object";
		}
		if (val instanceof Error) return `${val.name}: ${val.message}\n${val.stack}`;
		return className;
	}
	/**
	* Initializes an SDK client with a given configuration.
	* @param {string} config
	* @returns {Promise<string>}
	*/
	module.exports.init_client = function(config) {
		const ptr0 = passStringToWasm0(config, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
		const len0 = WASM_VECTOR_LEN;
		return wasm.init_client(ptr0, len0);
	};
	/**
	* Handles all asynchronous invocations to the SDK core received from the SDK.
	* @param {string} parameters
	* @returns {Promise<string>}
	*/
	module.exports.invoke = function(parameters) {
		const ptr0 = passStringToWasm0(parameters, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
		const len0 = WASM_VECTOR_LEN;
		return wasm.invoke(ptr0, len0);
	};
	function takeFromExternrefTable0(idx) {
		const value = wasm.__wbindgen_export_2.get(idx);
		wasm.__externref_table_dealloc(idx);
		return value;
	}
	/**
	* Handles all synchronous invocations to the SDK core received from the SDK.
	* @param {string} parameters
	* @returns {string}
	*/
	module.exports.invoke_sync = function(parameters) {
		let deferred3_0;
		let deferred3_1;
		try {
			const ptr0 = passStringToWasm0(parameters, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
			const len0 = WASM_VECTOR_LEN;
			const ret = wasm.invoke_sync(ptr0, len0);
			var ptr2 = ret[0];
			var len2 = ret[1];
			if (ret[3]) {
				ptr2 = 0;
				len2 = 0;
				throw takeFromExternrefTable0(ret[2]);
			}
			deferred3_0 = ptr2;
			deferred3_1 = len2;
			return getStringFromWasm0(ptr2, len2);
		} finally {
			wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
		}
	};
	/**
	* Drops a client, releasing the memory allocated for it.
	* @param {string} client_id
	*/
	module.exports.release_client = function(client_id) {
		const ptr0 = passStringToWasm0(client_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
		const len0 = WASM_VECTOR_LEN;
		const ret = wasm.release_client(ptr0, len0);
		if (ret[1]) throw takeFromExternrefTable0(ret[0]);
	};
	function __wbg_adapter_30(arg0, arg1) {
		wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h32a292ce38c5403f(arg0, arg1);
	}
	function __wbg_adapter_33(arg0, arg1, arg2) {
		wasm.closure2326_externref_shim(arg0, arg1, arg2);
	}
	function __wbg_adapter_160(arg0, arg1, arg2, arg3) {
		wasm.closure2475_externref_shim(arg0, arg1, arg2, arg3);
	}
	const __wbindgen_enum_RequestCache = [
		"default",
		"no-store",
		"reload",
		"no-cache",
		"force-cache",
		"only-if-cached"
	];
	const __wbindgen_enum_RequestCredentials = [
		"omit",
		"same-origin",
		"include"
	];
	const __wbindgen_enum_RequestMode = [
		"same-origin",
		"no-cors",
		"cors",
		"navigate"
	];
	module.exports.__wbg_abort_410ec47a64ac6117 = function(arg0, arg1) {
		arg0.abort(arg1);
	};
	module.exports.__wbg_abort_775ef1d17fc65868 = function(arg0) {
		arg0.abort();
	};
	module.exports.__wbg_append_8c7dd8d641a5f01b = function() {
		return handleError(function(arg0, arg1, arg2, arg3, arg4) {
			arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
		}, arguments);
	};
	module.exports.__wbg_arrayBuffer_d1b44c4390db422f = function() {
		return handleError(function(arg0) {
			return arg0.arrayBuffer();
		}, arguments);
	};
	module.exports.__wbg_buffer_609cc3eee51ed158 = function(arg0) {
		return arg0.buffer;
	};
	module.exports.__wbg_call_672a4d21634d4a24 = function() {
		return handleError(function(arg0, arg1) {
			return arg0.call(arg1);
		}, arguments);
	};
	module.exports.__wbg_call_7cccdd69e0791ae2 = function() {
		return handleError(function(arg0, arg1, arg2) {
			return arg0.call(arg1, arg2);
		}, arguments);
	};
	module.exports.__wbg_clearTimeout_7a42b49784aea641 = function(arg0) {
		return clearTimeout(arg0);
	};
	module.exports.__wbg_crypto_574e78ad8b13b65f = function(arg0) {
		return arg0.crypto;
	};
	module.exports.__wbg_done_769e5ede4b31c67b = function(arg0) {
		return arg0.done;
	};
	module.exports.__wbg_fetch_509096533071c657 = function(arg0, arg1) {
		return arg0.fetch(arg1);
	};
	module.exports.__wbg_fetch_74a3e84ebd2c9a0e = function(arg0) {
		return fetch(arg0);
	};
	module.exports.__wbg_getFullYear_17d3c9e4db748eb7 = function(arg0) {
		return arg0.getFullYear();
	};
	module.exports.__wbg_getRandomValues_5754b82ca6952f9b = function() {
		return handleError(function(arg0, arg1, arg2) {
			return arg0.getRandomValues(getArrayU8FromWasm0(arg1, arg2));
		}, arguments);
	};
	module.exports.__wbg_getRandomValues_b8f5dbd5f3995a9e = function() {
		return handleError(function(arg0, arg1) {
			arg0.getRandomValues(arg1);
		}, arguments);
	};
	module.exports.__wbg_getTimezoneOffset_6b5752021c499c47 = function(arg0) {
		return arg0.getTimezoneOffset();
	};
	module.exports.__wbg_get_67b2ba62fc30de12 = function() {
		return handleError(function(arg0, arg1) {
			return Reflect.get(arg0, arg1);
		}, arguments);
	};
	module.exports.__wbg_has_a5ea9117f258a0ec = function() {
		return handleError(function(arg0, arg1) {
			return Reflect.has(arg0, arg1);
		}, arguments);
	};
	module.exports.__wbg_headers_9cb51cfd2ac780a4 = function(arg0) {
		return arg0.headers;
	};
	module.exports.__wbg_instanceof_Crypto_437466a97e9010b9 = function(arg0) {
		let result;
		try {
			result = arg0 instanceof Crypto;
		} catch (_) {
			result = false;
		}
		return result;
	};
	module.exports.__wbg_instanceof_Response_f2cc20d9f7dfd644 = function(arg0) {
		let result;
		try {
			result = arg0 instanceof Response;
		} catch (_) {
			result = false;
		}
		return result;
	};
	module.exports.__wbg_instanceof_Window_def73ea0955fc569 = function(arg0) {
		let result;
		try {
			result = arg0 instanceof Window;
		} catch (_) {
			result = false;
		}
		return result;
	};
	module.exports.__wbg_instanceof_WorkerGlobalScope_dbdbdea7e3b56493 = function(arg0) {
		let result;
		try {
			result = arg0 instanceof WorkerGlobalScope;
		} catch (_) {
			result = false;
		}
		return result;
	};
	module.exports.__wbg_iterator_9a24c88df860dc65 = function() {
		return Symbol.iterator;
	};
	module.exports.__wbg_languages_2420955220685766 = function(arg0) {
		return arg0.languages;
	};
	module.exports.__wbg_languages_d8dad509faf757df = function(arg0) {
		return arg0.languages;
	};
	module.exports.__wbg_length_a446193dc22c12f8 = function(arg0) {
		return arg0.length;
	};
	module.exports.__wbg_msCrypto_a61aeb35a24c1329 = function(arg0) {
		return arg0.msCrypto;
	};
	module.exports.__wbg_navigator_0a9bf1120e24fec2 = function(arg0) {
		return arg0.navigator;
	};
	module.exports.__wbg_navigator_1577371c070c8947 = function(arg0) {
		return arg0.navigator;
	};
	module.exports.__wbg_new0_f788a2397c7ca929 = function() {
		return /* @__PURE__ */ new Date();
	};
	module.exports.__wbg_new_018dcc2d6c8c2f6a = function() {
		return handleError(function() {
			return new Headers();
		}, arguments);
	};
	module.exports.__wbg_new_23a2665fac83c611 = function(arg0, arg1) {
		try {
			var state0 = {
				a: arg0,
				b: arg1
			};
			var cb0 = (arg0$1, arg1$1) => {
				const a = state0.a;
				state0.a = 0;
				try {
					return __wbg_adapter_160(a, state0.b, arg0$1, arg1$1);
				} finally {
					state0.a = a;
				}
			};
			return new Promise(cb0);
		} finally {
			state0.a = state0.b = 0;
		}
	};
	module.exports.__wbg_new_31a97dac4f10fab7 = function(arg0) {
		return new Date(arg0);
	};
	module.exports.__wbg_new_405e22f390576ce2 = function() {
		return /* @__PURE__ */ new Object();
	};
	module.exports.__wbg_new_a12002a7f91c75be = function(arg0) {
		return new Uint8Array(arg0);
	};
	module.exports.__wbg_new_e25e5aab09ff45db = function() {
		return handleError(function() {
			return new AbortController();
		}, arguments);
	};
	module.exports.__wbg_newnoargs_105ed471475aaf50 = function(arg0, arg1) {
		return new Function(getStringFromWasm0(arg0, arg1));
	};
	module.exports.__wbg_newwithbyteoffsetandlength_d97e637ebe145a9a = function(arg0, arg1, arg2) {
		return new Uint8Array(arg0, arg1 >>> 0, arg2 >>> 0);
	};
	module.exports.__wbg_newwithlength_a381634e90c276d4 = function(arg0) {
		return new Uint8Array(arg0 >>> 0);
	};
	module.exports.__wbg_newwithstrandinit_06c535e0a867c635 = function() {
		return handleError(function(arg0, arg1, arg2) {
			return new Request(getStringFromWasm0(arg0, arg1), arg2);
		}, arguments);
	};
	module.exports.__wbg_next_25feadfc0913fea9 = function(arg0) {
		return arg0.next;
	};
	module.exports.__wbg_next_6574e1a8a62d1055 = function() {
		return handleError(function(arg0) {
			return arg0.next();
		}, arguments);
	};
	module.exports.__wbg_node_905d3e251edff8a2 = function(arg0) {
		return arg0.node;
	};
	module.exports.__wbg_now_807e54c39636c349 = function() {
		return Date.now();
	};
	module.exports.__wbg_now_d18023d54d4e5500 = function(arg0) {
		return arg0.now();
	};
	module.exports.__wbg_parse_def2e24ef1252aff = function() {
		return handleError(function(arg0, arg1) {
			return JSON.parse(getStringFromWasm0(arg0, arg1));
		}, arguments);
	};
	module.exports.__wbg_process_dc0fbacc7c1c06f7 = function(arg0) {
		return arg0.process;
	};
	module.exports.__wbg_queueMicrotask_97d92b4fcc8a61c5 = function(arg0) {
		queueMicrotask(arg0);
	};
	module.exports.__wbg_queueMicrotask_d3219def82552485 = function(arg0) {
		return arg0.queueMicrotask;
	};
	module.exports.__wbg_randomFillSync_ac0988aba3254290 = function() {
		return handleError(function(arg0, arg1) {
			arg0.randomFillSync(arg1);
		}, arguments);
	};
	module.exports.__wbg_require_60cc747a6bc5215a = function() {
		return handleError(function() {
			return module.require;
		}, arguments);
	};
	module.exports.__wbg_resolve_4851785c9c5f573d = function(arg0) {
		return Promise.resolve(arg0);
	};
	module.exports.__wbg_self_b29ea9f89ecb0567 = function() {
		return handleError(function() {
			return self.self;
		}, arguments);
	};
	module.exports.__wbg_setTimeout_7bb3429662ab1e70 = function(arg0, arg1) {
		return setTimeout(arg0, arg1);
	};
	module.exports.__wbg_set_65595bdd868b3009 = function(arg0, arg1, arg2) {
		arg0.set(arg1, arg2 >>> 0);
	};
	module.exports.__wbg_setbody_5923b78a95eedf29 = function(arg0, arg1) {
		arg0.body = arg1;
	};
	module.exports.__wbg_setcache_12f17c3a980650e4 = function(arg0, arg1) {
		arg0.cache = __wbindgen_enum_RequestCache[arg1];
	};
	module.exports.__wbg_setcredentials_c3a22f1cd105a2c6 = function(arg0, arg1) {
		arg0.credentials = __wbindgen_enum_RequestCredentials[arg1];
	};
	module.exports.__wbg_setheaders_834c0bdb6a8949ad = function(arg0, arg1) {
		arg0.headers = arg1;
	};
	module.exports.__wbg_setmethod_3c5280fe5d890842 = function(arg0, arg1, arg2) {
		arg0.method = getStringFromWasm0(arg1, arg2);
	};
	module.exports.__wbg_setmode_5dc300b865044b65 = function(arg0, arg1) {
		arg0.mode = __wbindgen_enum_RequestMode[arg1];
	};
	module.exports.__wbg_setsignal_75b21ef3a81de905 = function(arg0, arg1) {
		arg0.signal = arg1;
	};
	module.exports.__wbg_signal_aaf9ad74119f20a4 = function(arg0) {
		return arg0.signal;
	};
	module.exports.__wbg_static_accessor_GLOBAL_88a902d13a557d07 = function() {
		const ret = typeof global === "undefined" ? null : global;
		return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
	};
	module.exports.__wbg_static_accessor_GLOBAL_THIS_56578be7e9f832b0 = function() {
		const ret = typeof globalThis === "undefined" ? null : globalThis;
		return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
	};
	module.exports.__wbg_static_accessor_SELF_37c5d418e4bf5819 = function() {
		const ret = typeof self === "undefined" ? null : self;
		return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
	};
	module.exports.__wbg_static_accessor_WINDOW_5de37043a91a9c40 = function() {
		const ret = typeof window === "undefined" ? null : window;
		return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
	};
	module.exports.__wbg_static_accessor_performance_da77b3a901a72934 = function() {
		return performance;
	};
	module.exports.__wbg_status_f6360336ca686bf0 = function(arg0) {
		return arg0.status;
	};
	module.exports.__wbg_stringify_f7ed6987935b4a24 = function() {
		return handleError(function(arg0) {
			return JSON.stringify(arg0);
		}, arguments);
	};
	module.exports.__wbg_subarray_aa9065fa9dc5df96 = function(arg0, arg1, arg2) {
		return arg0.subarray(arg1 >>> 0, arg2 >>> 0);
	};
	module.exports.__wbg_then_44b73946d2fb3e7d = function(arg0, arg1) {
		return arg0.then(arg1);
	};
	module.exports.__wbg_then_48b406749878a531 = function(arg0, arg1, arg2) {
		return arg0.then(arg1, arg2);
	};
	module.exports.__wbg_toLocaleDateString_e5424994746e8415 = function(arg0, arg1, arg2, arg3) {
		return arg0.toLocaleDateString(getStringFromWasm0(arg1, arg2), arg3);
	};
	module.exports.__wbg_url_ae10c34ca209681d = function(arg0, arg1) {
		const ret = arg1.url;
		const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
		const len1 = WASM_VECTOR_LEN;
		getDataViewMemory0().setInt32(arg0 + 4, len1, true);
		getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
	};
	module.exports.__wbg_value_cd1ffa7b1ab794f1 = function(arg0) {
		return arg0.value;
	};
	module.exports.__wbg_values_99f7a68c7f313d66 = function(arg0) {
		return arg0.values();
	};
	module.exports.__wbg_versions_c01dfd4722a88165 = function(arg0) {
		return arg0.versions;
	};
	module.exports.__wbg_window_aa5515e600e96252 = function() {
		return handleError(function() {
			return window.window;
		}, arguments);
	};
	module.exports.__wbindgen_cb_drop = function(arg0) {
		const obj = arg0.original;
		if (obj.cnt-- == 1) {
			obj.a = 0;
			return true;
		}
		return false;
	};
	module.exports.__wbindgen_closure_wrapper8700 = function(arg0, arg1, arg2) {
		return makeMutClosure(arg0, arg1, 2309, __wbg_adapter_30);
	};
	module.exports.__wbindgen_closure_wrapper8731 = function(arg0, arg1, arg2) {
		return makeMutClosure(arg0, arg1, 2327, __wbg_adapter_33);
	};
	module.exports.__wbindgen_debug_string = function(arg0, arg1) {
		const ptr1 = passStringToWasm0(debugString(arg1), wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
		const len1 = WASM_VECTOR_LEN;
		getDataViewMemory0().setInt32(arg0 + 4, len1, true);
		getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
	};
	module.exports.__wbindgen_init_externref_table = function() {
		const table = wasm.__wbindgen_export_2;
		const offset = table.grow(4);
		table.set(0, void 0);
		table.set(offset + 0, void 0);
		table.set(offset + 1, null);
		table.set(offset + 2, true);
		table.set(offset + 3, false);
	};
	module.exports.__wbindgen_is_function = function(arg0) {
		return typeof arg0 === "function";
	};
	module.exports.__wbindgen_is_object = function(arg0) {
		const val = arg0;
		return typeof val === "object" && val !== null;
	};
	module.exports.__wbindgen_is_string = function(arg0) {
		return typeof arg0 === "string";
	};
	module.exports.__wbindgen_is_undefined = function(arg0) {
		return arg0 === void 0;
	};
	module.exports.__wbindgen_memory = function() {
		return wasm.memory;
	};
	module.exports.__wbindgen_number_new = function(arg0) {
		return arg0;
	};
	module.exports.__wbindgen_string_get = function(arg0, arg1) {
		const obj = arg1;
		const ret = typeof obj === "string" ? obj : void 0;
		var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
		var len1 = WASM_VECTOR_LEN;
		getDataViewMemory0().setInt32(arg0 + 4, len1, true);
		getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
	};
	module.exports.__wbindgen_string_new = function(arg0, arg1) {
		return getStringFromWasm0(arg0, arg1);
	};
	module.exports.__wbindgen_throw = function(arg0, arg1) {
		throw new Error(getStringFromWasm0(arg0, arg1));
	};
	const path$1 = require("path").join(__dirname, "core_bg.wasm");
	const bytes = require("fs").readFileSync(path$1);
	const wasmModule = new WebAssembly.Module(bytes);
	wasm = new WebAssembly.Instance(wasmModule, imports).exports;
	module.exports.__wasm = wasm;
	wasm.__wbindgen_start();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/types.js
var require_types = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/types.js": ((exports) => {
	Object.defineProperty(exports, "__esModule", { value: true });
	var GroupType;
	(function(GroupType$1) {
		/**
		* The owners group, which gives the following permissions:
		* - Do everything the Admin group can do
		* - See every vault other than the personal vaults
		* - Change people's names
		* - See billing
		* - Change billing
		* - Make other people owners
		* - Delete a person
		*/
		GroupType$1["Owners"] = "owners";
		/**
		* The administrators group, which gives the following permissions:
		* - Perform recovery
		* - Create new vaults
		* - Invite new members
		* - See vault metadata, including the vault name and who has access.
		* - Make other people admins
		*/
		GroupType$1["Administrators"] = "administrators";
		/**
		* The recovery group. It contains recovery keysets, and is added to every vault to allow for recovery.
		*
		* No one is added to this.
		*/
		GroupType$1["Recovery"] = "recovery";
		/**
		* The external account managers group or EAM is a mandatory group for managed accounts that has
		* same permissions as the owners.
		*/
		GroupType$1["ExternalAccountManagers"] = "externalAccountManagers";
		/** Members of a team that a user is on. */
		GroupType$1["TeamMembers"] = "teamMembers";
		/** A custom, user defined group. */
		GroupType$1["UserDefined"] = "userDefined";
		/** Support for new or renamed group types */
		GroupType$1["Unsupported"] = "unsupported";
	})(GroupType || (exports.GroupType = GroupType = {}));
	var GroupState;
	(function(GroupState$1) {
		/** This group is active */
		GroupState$1["Active"] = "active";
		/** This group has been deleted */
		GroupState$1["Deleted"] = "deleted";
		/** This group is in an unknown state */
		GroupState$1["Unsupported"] = "unsupported";
	})(GroupState || (exports.GroupState = GroupState = {}));
	var VaultAccessorType;
	(function(VaultAccessorType$1) {
		VaultAccessorType$1["User"] = "user";
		VaultAccessorType$1["Group"] = "group";
	})(VaultAccessorType || (exports.VaultAccessorType = VaultAccessorType = {}));
	var ItemCategory;
	(function(ItemCategory$1) {
		ItemCategory$1["Login"] = "Login";
		ItemCategory$1["SecureNote"] = "SecureNote";
		ItemCategory$1["CreditCard"] = "CreditCard";
		ItemCategory$1["CryptoWallet"] = "CryptoWallet";
		ItemCategory$1["Identity"] = "Identity";
		ItemCategory$1["Password"] = "Password";
		ItemCategory$1["Document"] = "Document";
		ItemCategory$1["ApiCredentials"] = "ApiCredentials";
		ItemCategory$1["BankAccount"] = "BankAccount";
		ItemCategory$1["Database"] = "Database";
		ItemCategory$1["DriverLicense"] = "DriverLicense";
		ItemCategory$1["Email"] = "Email";
		ItemCategory$1["MedicalRecord"] = "MedicalRecord";
		ItemCategory$1["Membership"] = "Membership";
		ItemCategory$1["OutdoorLicense"] = "OutdoorLicense";
		ItemCategory$1["Passport"] = "Passport";
		ItemCategory$1["Rewards"] = "Rewards";
		ItemCategory$1["Router"] = "Router";
		ItemCategory$1["Server"] = "Server";
		ItemCategory$1["SshKey"] = "SshKey";
		ItemCategory$1["SocialSecurityNumber"] = "SocialSecurityNumber";
		ItemCategory$1["SoftwareLicense"] = "SoftwareLicense";
		ItemCategory$1["Person"] = "Person";
		ItemCategory$1["Unsupported"] = "Unsupported";
	})(ItemCategory || (exports.ItemCategory = ItemCategory = {}));
	var ItemFieldType;
	(function(ItemFieldType$1) {
		ItemFieldType$1["Text"] = "Text";
		ItemFieldType$1["Concealed"] = "Concealed";
		ItemFieldType$1["CreditCardType"] = "CreditCardType";
		ItemFieldType$1["CreditCardNumber"] = "CreditCardNumber";
		ItemFieldType$1["Phone"] = "Phone";
		ItemFieldType$1["Url"] = "Url";
		ItemFieldType$1["Totp"] = "Totp";
		ItemFieldType$1["Email"] = "Email";
		ItemFieldType$1["Reference"] = "Reference";
		ItemFieldType$1["SshKey"] = "SshKey";
		ItemFieldType$1["Menu"] = "Menu";
		ItemFieldType$1["MonthYear"] = "MonthYear";
		ItemFieldType$1["Address"] = "Address";
		ItemFieldType$1["Date"] = "Date";
		ItemFieldType$1["Unsupported"] = "Unsupported";
	})(ItemFieldType || (exports.ItemFieldType = ItemFieldType = {}));
	/**
	* Controls the auto-fill behavior of a website.
	*
	*
	* For more information, visit <https://support.1password.com/autofill-behavior/>
	*/
	var AutofillBehavior;
	(function(AutofillBehavior$1) {
		/** Auto-fill any page that’s part of the website, including subdomains */
		AutofillBehavior$1["AnywhereOnWebsite"] = "AnywhereOnWebsite";
		/** Auto-fill only if the domain (hostname and port) is an exact match. */
		AutofillBehavior$1["ExactDomain"] = "ExactDomain";
		/** Never auto-fill on this website */
		AutofillBehavior$1["Never"] = "Never";
	})(AutofillBehavior || (exports.AutofillBehavior = AutofillBehavior = {}));
	/** Represents the state of an item in the SDK. */
	var ItemState;
	(function(ItemState$1) {
		/** The item is active */
		ItemState$1["Active"] = "active";
		/** The item is archived meaning it's hidden from regular view and stored in the archive. */
		ItemState$1["Archived"] = "archived";
	})(ItemState || (exports.ItemState = ItemState = {}));
	/** The valid duration options for sharing an item */
	var ItemShareDuration;
	(function(ItemShareDuration$1) {
		/** The share will expire in one hour */
		ItemShareDuration$1["OneHour"] = "OneHour";
		/** The share will expire in one day */
		ItemShareDuration$1["OneDay"] = "OneDay";
		/** The share will expire in seven days */
		ItemShareDuration$1["SevenDays"] = "SevenDays";
		/** The share will expire in fourteen days */
		ItemShareDuration$1["FourteenDays"] = "FourteenDays";
		/** The share will expire in thirty days */
		ItemShareDuration$1["ThirtyDays"] = "ThirtyDays";
	})(ItemShareDuration || (exports.ItemShareDuration = ItemShareDuration = {}));
	/** The allowed types of item sharing, enforced by account policy */
	var AllowedType;
	(function(AllowedType$1) {
		/** Allows creating share links with specific recipients */
		AllowedType$1["Authenticated"] = "Authenticated";
		/** Allows creating public share links */
		AllowedType$1["Public"] = "Public";
	})(AllowedType || (exports.AllowedType = AllowedType = {}));
	/** The allowed recipient types of item sharing, enforced by account policy */
	var AllowedRecipientType;
	(function(AllowedRecipientType$1) {
		/** Recipients can be specified by email address */
		AllowedRecipientType$1["Email"] = "Email";
		/** Recipients can be specified by domain */
		AllowedRecipientType$1["Domain"] = "Domain";
	})(AllowedRecipientType || (exports.AllowedRecipientType = AllowedRecipientType = {}));
	/** Represents the vault type. */
	var VaultType;
	(function(VaultType$1) {
		VaultType$1["Personal"] = "personal";
		VaultType$1["Everyone"] = "everyone";
		VaultType$1["Transfer"] = "transfer";
		VaultType$1["UserCreated"] = "userCreated";
		VaultType$1["Unsupported"] = "unsupported";
	})(VaultType || (exports.VaultType = VaultType = {}));
	var SeparatorType;
	(function(SeparatorType$1) {
		/**
		* Randomly selected digits.
		* E.g, "`correct4horse0battery1staple`"
		*/
		SeparatorType$1["Digits"] = "digits";
		/**
		* Randomly selected digits and symbols.
		* This is useful to get word-based passwords to meet complexity requirements
		* E.g, "`correct4horse-battery1staple`"
		*/
		SeparatorType$1["DigitsAndSymbols"] = "digitsAndSymbols";
		/**
		* Spaces, like the original Diceware.
		* Great for mobile keyboards, not so great when people can overhear you type the password.
		* E.g, "`correct horse battery staple`"
		*/
		SeparatorType$1["Spaces"] = "spaces";
		/**
		* Hyphens "`-`".
		* E.g, "`correct-horse-battery-staple`"
		*/
		SeparatorType$1["Hyphens"] = "hyphens";
		/**
		* "`_`".
		* E.g, "`correct_horse_battery_staple`"
		*/
		SeparatorType$1["Underscores"] = "underscores";
		/**
		* Period (full stop) "`.`".
		* E.g, "`correct.horse.battery.staple`"
		*/
		SeparatorType$1["Periods"] = "periods";
		/**
		* Comma "`,`".
		* E.g, "`correct,horse,battery,staple`"
		*/
		SeparatorType$1["Commas"] = "commas";
	})(SeparatorType || (exports.SeparatorType = SeparatorType = {}));
	var WordListType;
	(function(WordListType$1) {
		/** Agile wordlist */
		WordListType$1["FullWords"] = "fullWords";
		/** English-like syllables */
		WordListType$1["Syllables"] = "syllables";
		/** Three (random) letter "words" */
		WordListType$1["ThreeLetters"] = "threeLetters";
	})(WordListType || (exports.WordListType = WordListType = {}));
	exports.ARCHIVE_ITEMS = 256;
	exports.CREATE_ITEMS = 128;
	exports.DELETE_ITEMS = 512;
	exports.EXPORT_ITEMS = 4194304;
	exports.IMPORT_ITEMS = 2097152;
	exports.MANAGE_VAULT = 2;
	exports.NO_ACCESS = 0;
	exports.PRINT_ITEMS = 8388608;
	exports.READ_ITEMS = 32;
	exports.RECOVER_VAULT = 1;
	exports.REVEAL_ITEM_PASSWORD = 16;
	exports.SEND_ITEMS = 1048576;
	exports.UPDATE_ITEMS = 64;
	exports.UPDATE_ITEM_HISTORY = 1024;
	/**
	* Custom JSON reviver and replacer functions for dynamic data transformation
	* ReviverFunc is used during JSON parsing to detect and transform specific data structures
	* ReplacerFunc is used during JSON serialization to modify certain values before stringifying.
	* These functions allow for flexible encoding and decoding of data, ensuring that complex types are properly handled when converting between TS objects and JSON
	*/
	const ReviverFunc = (key, value) => {
		if (typeof value === "string" && /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?Z$/.test(value) && (key === "createdAt" || key === "updatedAt")) return new Date(value);
		if (Array.isArray(value) && value.every((v) => Number.isInteger(v) && v >= 0 && v <= 255) && value.length > 0) return new Uint8Array(value);
		return value;
	};
	exports.ReviverFunc = ReviverFunc;
	const ReplacerFunc = (key, value) => {
		if (value instanceof Date) return value.toISOString();
		if (value instanceof Uint8Array) return Array.from(value);
		return value;
	};
	exports.ReplacerFunc = ReplacerFunc;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/errors.js
var require_errors = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/errors.js": ((exports) => {
	Object.defineProperty(exports, "__esModule", { value: true });
	var DesktopSessionExpiredError = class extends Error {
		constructor(message) {
			super();
			this.message = message;
		}
	};
	exports.DesktopSessionExpiredError = DesktopSessionExpiredError;
	var RateLimitExceededError = class extends Error {
		constructor(message) {
			super();
			this.message = message;
		}
	};
	exports.RateLimitExceededError = RateLimitExceededError;
	const throwError = (errString) => {
		let err;
		try {
			err = JSON.parse(errString);
		} catch (e) {
			throw new Error(errString);
		}
		switch (err.name) {
			case "DesktopSessionExpired": throw new DesktopSessionExpiredError(err.message);
			case "RateLimitExceeded": throw new RateLimitExceededError(err.message);
			default: throw new Error(err.message);
		}
	};
	exports.throwError = throwError;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/core.js
var require_core = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/core.js": ((exports) => {
	var __awaiter$9 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	Object.defineProperty(exports, "__esModule", { value: true });
	const sdk_core_1 = require_core$1();
	const types_1 = require_types();
	const errors_1$1 = require_errors();
	const messageLimit = 50 * 1024 * 1024;
	var WasmCore = class {
		initClient(config) {
			return __awaiter$9(this, void 0, void 0, function* () {
				try {
					return yield (0, sdk_core_1.init_client)(config);
				} catch (e) {
					(0, errors_1$1.throwError)(e);
				}
			});
		}
		invoke(config) {
			return __awaiter$9(this, void 0, void 0, function* () {
				try {
					return yield (0, sdk_core_1.invoke)(config);
				} catch (e) {
					(0, errors_1$1.throwError)(e);
				}
			});
		}
		releaseClient(clientId) {
			try {
				(0, sdk_core_1.release_client)(clientId);
			} catch (e) {
				console.warn("failed to release client:", e);
			}
		}
	};
	exports.WasmCore = WasmCore;
	/**
	*  An implementation of the `Core` interface that shares resources across all clients.
	*/
	var SharedCore = class {
		constructor() {
			this.inner = new WasmCore();
		}
		setInner(core) {
			this.inner = core;
		}
		initClient(config) {
			return __awaiter$9(this, void 0, void 0, function* () {
				const serializedConfig = JSON.stringify(config);
				return this.inner.initClient(serializedConfig);
			});
		}
		invoke(config) {
			return __awaiter$9(this, void 0, void 0, function* () {
				const serializedConfig = JSON.stringify(config, types_1.ReplacerFunc);
				if (new TextEncoder().encode(serializedConfig).length > messageLimit) (0, errors_1$1.throwError)(`message size exceeds the limit of ${messageLimit} bytes, please contact 1Password at support@1password.com or https://developer.1password.com/joinslack if you need help."`);
				return this.inner.invoke(serializedConfig);
			});
		}
		invoke_sync(config) {
			const serializedConfig = JSON.stringify(config, types_1.ReplacerFunc);
			if (new TextEncoder().encode(serializedConfig).length > messageLimit) (0, errors_1$1.throwError)(`message size exceeds the limit of ${messageLimit} bytes, please contact 1Password at support@1password.com or https://developer.1password.com/joinslack if you need help.`);
			return (0, sdk_core_1.invoke_sync)(serializedConfig);
		}
		releaseClient(clientId) {
			const serializedId = JSON.stringify(clientId);
			this.inner.releaseClient(serializedId);
		}
	};
	exports.SharedCore = SharedCore;
	/**
	*  Represents the client instance on which a call is made.
	*/
	var InnerClient = class {
		constructor(id, core, config) {
			this.id = id;
			this.core = core;
			this.config = config;
		}
		invoke(config) {
			return __awaiter$9(this, void 0, void 0, function* () {
				try {
					return yield this.core.invoke(config);
				} catch (err) {
					if (err instanceof errors_1$1.DesktopSessionExpiredError) {
						const newId = yield this.core.initClient(this.config);
						this.id = parseInt(newId, 10);
						config.invocation.clientId = this.id;
						return yield this.core.invoke(config);
					}
					throw err;
				}
			});
		}
	};
	exports.InnerClient = InnerClient;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/version.js
var require_version = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/version.js": ((exports) => {
	Object.defineProperty(exports, "__esModule", { value: true });
	exports.SDK_VERSION = "0.4.0-beta.2";
	exports.SDK_BUILD_NUMBER = "0040002";
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/configuration.js
var require_configuration = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/configuration.js": ((exports) => {
	var __importDefault = exports && exports.__importDefault || function(mod) {
		return mod && mod.__esModule ? mod : { "default": mod };
	};
	Object.defineProperty(exports, "__esModule", { value: true });
	exports.getOsName = exports.clientAuthConfig = exports.DesktopAuth = exports.VERSION = exports.LANGUAGE = void 0;
	const os_1 = __importDefault(require("os"));
	const version_js_1 = require_version();
	exports.LANGUAGE = "JS";
	exports.VERSION = version_js_1.SDK_BUILD_NUMBER;
	/**
	* Setting that specifies that a client should use the desktop app to authenticate.
	*/
	var DesktopAuth$1 = class {
		constructor(accountName) {
			this.accountName = accountName;
		}
	};
	exports.DesktopAuth = DesktopAuth$1;
	/**
	* Creates a default client configuration.
	* @returns The client configuration to instantiate the client with.
	*/
	const clientAuthConfig = (userConfig) => {
		const defaultOsVersion = "0.0.0";
		let serviceAccountToken;
		let accountName;
		if (typeof userConfig.auth === "string") serviceAccountToken = userConfig.auth;
		else if (userConfig.auth instanceof DesktopAuth$1) accountName = userConfig.auth.accountName;
		return {
			serviceAccountToken: serviceAccountToken !== null && serviceAccountToken !== void 0 ? serviceAccountToken : "",
			accountName,
			programmingLanguage: exports.LANGUAGE,
			sdkVersion: exports.VERSION,
			integrationName: userConfig.integrationName,
			integrationVersion: userConfig.integrationVersion,
			requestLibraryName: "Fetch API",
			requestLibraryVersion: "Fetch API",
			os: (0, exports.getOsName)(),
			osVersion: defaultOsVersion,
			architecture: os_1.default.arch()
		};
	};
	exports.clientAuthConfig = clientAuthConfig;
	const getOsName = () => {
		const os_name = os_1.default.type().toLowerCase();
		if (os_name === "windows_nt") return "windows";
		return os_name;
	};
	exports.getOsName = getOsName;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/secrets.js
var require_secrets = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/secrets.js": ((exports) => {
	var __awaiter$8 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	var __classPrivateFieldSet$5 = exports && exports.__classPrivateFieldSet || function(receiver, state, value, kind, f) {
		if (kind === "m") throw new TypeError("Private method is not writable");
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
		return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
	};
	var __classPrivateFieldGet$5 = exports && exports.__classPrivateFieldGet || function(receiver, state, kind, f) {
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
		return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
	};
	var _Secrets_inner;
	Object.defineProperty(exports, "__esModule", { value: true });
	const core_js_1$2 = require_core();
	const types_js_1$5 = require_types();
	var Secrets = class {
		constructor(inner) {
			_Secrets_inner.set(this, void 0);
			__classPrivateFieldSet$5(this, _Secrets_inner, inner, "f");
		}
		/**
		* Resolve returns the secret the provided secret reference points to.
		*/
		resolve(secretReference) {
			return __awaiter$8(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$5(this, _Secrets_inner, "f").id,
					parameters: {
						name: "SecretsResolve",
						parameters: { secret_reference: secretReference }
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$5(this, _Secrets_inner, "f").invoke(invocationConfig), types_js_1$5.ReviverFunc);
			});
		}
		/**
		* Resolve takes in a list of secret references and returns the secrets they point to or errors if any.
		*/
		resolveAll(secretReferences) {
			return __awaiter$8(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$5(this, _Secrets_inner, "f").id,
					parameters: {
						name: "SecretsResolveAll",
						parameters: { secret_references: secretReferences }
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$5(this, _Secrets_inner, "f").invoke(invocationConfig), types_js_1$5.ReviverFunc);
			});
		}
		/**
		* Validate the secret reference to ensure there are no syntax errors.
		*/
		static validateSecretReference(secretReference) {
			const sharedCore = new core_js_1$2.SharedCore();
			const invocationConfig = { invocation: { parameters: {
				name: "ValidateSecretReference",
				parameters: { secret_reference: secretReference }
			} } };
			sharedCore.invoke_sync(invocationConfig);
		}
		static generatePassword(recipe) {
			const sharedCore = new core_js_1$2.SharedCore();
			const invocationConfig = { invocation: { parameters: {
				name: "GeneratePassword",
				parameters: { recipe }
			} } };
			return JSON.parse(sharedCore.invoke_sync(invocationConfig), types_js_1$5.ReviverFunc);
		}
	};
	exports.Secrets = Secrets;
	_Secrets_inner = /* @__PURE__ */ new WeakMap();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/items_shares.js
var require_items_shares = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/items_shares.js": ((exports) => {
	var __awaiter$7 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	var __classPrivateFieldSet$4 = exports && exports.__classPrivateFieldSet || function(receiver, state, value, kind, f) {
		if (kind === "m") throw new TypeError("Private method is not writable");
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
		return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
	};
	var __classPrivateFieldGet$4 = exports && exports.__classPrivateFieldGet || function(receiver, state, kind, f) {
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
		return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
	};
	var _ItemsShares_inner;
	Object.defineProperty(exports, "__esModule", { value: true });
	const types_js_1$4 = require_types();
	var ItemsShares = class {
		constructor(inner) {
			_ItemsShares_inner.set(this, void 0);
			__classPrivateFieldSet$4(this, _ItemsShares_inner, inner, "f");
		}
		/**
		* Get the item sharing policy of your account.
		*/
		getAccountPolicy(vaultId, itemId) {
			return __awaiter$7(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$4(this, _ItemsShares_inner, "f").id,
					parameters: {
						name: "ItemsSharesGetAccountPolicy",
						parameters: {
							vault_id: vaultId,
							item_id: itemId
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$4(this, _ItemsShares_inner, "f").invoke(invocationConfig), types_js_1$4.ReviverFunc);
			});
		}
		/**
		* Validate the recipients of an item sharing link.
		*/
		validateRecipients(policy, recipients) {
			return __awaiter$7(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$4(this, _ItemsShares_inner, "f").id,
					parameters: {
						name: "ItemsSharesValidateRecipients",
						parameters: {
							policy,
							recipients
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$4(this, _ItemsShares_inner, "f").invoke(invocationConfig), types_js_1$4.ReviverFunc);
			});
		}
		/**
		* Create a new item sharing link.
		*/
		create(item, policy, params) {
			return __awaiter$7(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$4(this, _ItemsShares_inner, "f").id,
					parameters: {
						name: "ItemsSharesCreate",
						parameters: {
							item,
							policy,
							params
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$4(this, _ItemsShares_inner, "f").invoke(invocationConfig), types_js_1$4.ReviverFunc);
			});
		}
	};
	exports.ItemsShares = ItemsShares;
	_ItemsShares_inner = /* @__PURE__ */ new WeakMap();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/items_files.js
var require_items_files = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/items_files.js": ((exports) => {
	var __awaiter$6 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	var __classPrivateFieldSet$3 = exports && exports.__classPrivateFieldSet || function(receiver, state, value, kind, f) {
		if (kind === "m") throw new TypeError("Private method is not writable");
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
		return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
	};
	var __classPrivateFieldGet$3 = exports && exports.__classPrivateFieldGet || function(receiver, state, kind, f) {
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
		return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
	};
	var _ItemsFiles_inner;
	Object.defineProperty(exports, "__esModule", { value: true });
	const types_js_1$3 = require_types();
	var ItemsFiles = class {
		constructor(inner) {
			_ItemsFiles_inner.set(this, void 0);
			__classPrivateFieldSet$3(this, _ItemsFiles_inner, inner, "f");
		}
		/**
		* Attach files to Items
		*/
		attach(item, fileParams) {
			return __awaiter$6(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").id,
					parameters: {
						name: "ItemsFilesAttach",
						parameters: {
							item,
							file_params: fileParams
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").invoke(invocationConfig), types_js_1$3.ReviverFunc);
			});
		}
		/**
		* Read file content from the Item
		*/
		read(vaultId, itemId, attr) {
			return __awaiter$6(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").id,
					parameters: {
						name: "ItemsFilesRead",
						parameters: {
							vault_id: vaultId,
							item_id: itemId,
							attr
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").invoke(invocationConfig), types_js_1$3.ReviverFunc);
			});
		}
		/**
		* Delete a field file from Item using the section and field IDs
		*/
		delete(item, sectionId, fieldId) {
			return __awaiter$6(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").id,
					parameters: {
						name: "ItemsFilesDelete",
						parameters: {
							item,
							section_id: sectionId,
							field_id: fieldId
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").invoke(invocationConfig), types_js_1$3.ReviverFunc);
			});
		}
		/**
		* Replace the document file within a document item
		*/
		replaceDocument(item, docParams) {
			return __awaiter$6(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").id,
					parameters: {
						name: "ItemsFilesReplaceDocument",
						parameters: {
							item,
							doc_params: docParams
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$3(this, _ItemsFiles_inner, "f").invoke(invocationConfig), types_js_1$3.ReviverFunc);
			});
		}
	};
	exports.ItemsFiles = ItemsFiles;
	_ItemsFiles_inner = /* @__PURE__ */ new WeakMap();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/items.js
var require_items = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/items.js": ((exports) => {
	var __awaiter$5 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	var __classPrivateFieldSet$2 = exports && exports.__classPrivateFieldSet || function(receiver, state, value, kind, f) {
		if (kind === "m") throw new TypeError("Private method is not writable");
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
		return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
	};
	var __classPrivateFieldGet$2 = exports && exports.__classPrivateFieldGet || function(receiver, state, kind, f) {
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
		return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
	};
	var _Items_inner;
	Object.defineProperty(exports, "__esModule", { value: true });
	const types_js_1$2 = require_types();
	const items_shares_js_1 = require_items_shares();
	const items_files_js_1 = require_items_files();
	var Items = class {
		constructor(inner) {
			_Items_inner.set(this, void 0);
			__classPrivateFieldSet$2(this, _Items_inner, inner, "f");
			this.shares = new items_shares_js_1.ItemsShares(inner);
			this.files = new items_files_js_1.ItemsFiles(inner);
		}
		/**
		* Create a new item.
		*/
		create(params) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsCreate",
						parameters: { params }
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
		/**
		* Create items in batch, within a single vault.
		*/
		createAll(vaultId, params) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsCreateAll",
						parameters: {
							vault_id: vaultId,
							params
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
		/**
		* Get an item by vault and item ID
		*/
		get(vaultId, itemId) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsGet",
						parameters: {
							vault_id: vaultId,
							item_id: itemId
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
		/**
		* Get items by vault and their item IDs.
		*/
		getAll(vaultId, itemIds) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsGetAll",
						parameters: {
							vault_id: vaultId,
							item_ids: itemIds
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
		/**
		* Update an existing item.
		*/
		put(item) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsPut",
						parameters: { item }
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
		/**
		* Delete an item.
		*/
		delete(vaultId, itemId) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsDelete",
						parameters: {
							vault_id: vaultId,
							item_id: itemId
						}
					}
				} };
				yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig);
			});
		}
		/**
		* Delete items in batch, within a single vault.
		*/
		deleteAll(vaultId, itemIds) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsDeleteAll",
						parameters: {
							vault_id: vaultId,
							item_ids: itemIds
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
		/**
		* Archive an item.
		*/
		archive(vaultId, itemId) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsArchive",
						parameters: {
							vault_id: vaultId,
							item_id: itemId
						}
					}
				} };
				yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig);
			});
		}
		/**
		* List items based on filters.
		*/
		list(vaultId, ...filters) {
			return __awaiter$5(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$2(this, _Items_inner, "f").id,
					parameters: {
						name: "ItemsList",
						parameters: {
							vault_id: vaultId,
							filters
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$2(this, _Items_inner, "f").invoke(invocationConfig), types_js_1$2.ReviverFunc);
			});
		}
	};
	exports.Items = Items;
	_Items_inner = /* @__PURE__ */ new WeakMap();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/vaults.js
var require_vaults = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/vaults.js": ((exports) => {
	var __awaiter$4 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	var __classPrivateFieldSet$1 = exports && exports.__classPrivateFieldSet || function(receiver, state, value, kind, f) {
		if (kind === "m") throw new TypeError("Private method is not writable");
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
		return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
	};
	var __classPrivateFieldGet$1 = exports && exports.__classPrivateFieldGet || function(receiver, state, kind, f) {
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
		return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
	};
	var _Vaults_inner;
	Object.defineProperty(exports, "__esModule", { value: true });
	const types_js_1$1 = require_types();
	var Vaults = class {
		constructor(inner) {
			_Vaults_inner.set(this, void 0);
			__classPrivateFieldSet$1(this, _Vaults_inner, inner, "f");
		}
		/**
		* List information about vaults that's configurable based on some input parameters.
		*/
		list(params) {
			return __awaiter$4(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$1(this, _Vaults_inner, "f").id,
					parameters: {
						name: "VaultsList",
						parameters: { params }
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$1(this, _Vaults_inner, "f").invoke(invocationConfig), types_js_1$1.ReviverFunc);
			});
		}
		getOverview(vaultUuid) {
			return __awaiter$4(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$1(this, _Vaults_inner, "f").id,
					parameters: {
						name: "VaultsGetOverview",
						parameters: { vault_uuid: vaultUuid }
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$1(this, _Vaults_inner, "f").invoke(invocationConfig), types_js_1$1.ReviverFunc);
			});
		}
		get(vaultUuid, vaultParams) {
			return __awaiter$4(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$1(this, _Vaults_inner, "f").id,
					parameters: {
						name: "VaultsGet",
						parameters: {
							vault_uuid: vaultUuid,
							vault_params: vaultParams
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet$1(this, _Vaults_inner, "f").invoke(invocationConfig), types_js_1$1.ReviverFunc);
			});
		}
		grantGroupPermissions(vaultId, groupPermissionsList) {
			return __awaiter$4(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$1(this, _Vaults_inner, "f").id,
					parameters: {
						name: "VaultsGrantGroupPermissions",
						parameters: {
							vault_id: vaultId,
							group_permissions_list: groupPermissionsList
						}
					}
				} };
				yield __classPrivateFieldGet$1(this, _Vaults_inner, "f").invoke(invocationConfig);
			});
		}
		updateGroupPermissions(groupPermissionsList) {
			return __awaiter$4(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$1(this, _Vaults_inner, "f").id,
					parameters: {
						name: "VaultsUpdateGroupPermissions",
						parameters: { group_permissions_list: groupPermissionsList }
					}
				} };
				yield __classPrivateFieldGet$1(this, _Vaults_inner, "f").invoke(invocationConfig);
			});
		}
		revokeGroupPermissions(vaultId, groupId) {
			return __awaiter$4(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet$1(this, _Vaults_inner, "f").id,
					parameters: {
						name: "VaultsRevokeGroupPermissions",
						parameters: {
							vault_id: vaultId,
							group_id: groupId
						}
					}
				} };
				yield __classPrivateFieldGet$1(this, _Vaults_inner, "f").invoke(invocationConfig);
			});
		}
	};
	exports.Vaults = Vaults;
	_Vaults_inner = /* @__PURE__ */ new WeakMap();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/groups.js
var require_groups = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/groups.js": ((exports) => {
	var __awaiter$3 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	var __classPrivateFieldSet = exports && exports.__classPrivateFieldSet || function(receiver, state, value, kind, f) {
		if (kind === "m") throw new TypeError("Private method is not writable");
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
		return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
	};
	var __classPrivateFieldGet = exports && exports.__classPrivateFieldGet || function(receiver, state, kind, f) {
		if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
		if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
		return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
	};
	var _Groups_inner;
	Object.defineProperty(exports, "__esModule", { value: true });
	const types_js_1 = require_types();
	var Groups = class {
		constructor(inner) {
			_Groups_inner.set(this, void 0);
			__classPrivateFieldSet(this, _Groups_inner, inner, "f");
		}
		get(groupId, groupParams) {
			return __awaiter$3(this, void 0, void 0, function* () {
				const invocationConfig = { invocation: {
					clientId: __classPrivateFieldGet(this, _Groups_inner, "f").id,
					parameters: {
						name: "GroupsGet",
						parameters: {
							group_id: groupId,
							group_params: groupParams
						}
					}
				} };
				return JSON.parse(yield __classPrivateFieldGet(this, _Groups_inner, "f").invoke(invocationConfig), types_js_1.ReviverFunc);
			});
		}
	};
	exports.Groups = Groups;
	_Groups_inner = /* @__PURE__ */ new WeakMap();
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/client.js
var require_client = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/client.js": ((exports) => {
	Object.defineProperty(exports, "__esModule", { value: true });
	const secrets_js_1$1 = require_secrets();
	const items_js_1 = require_items();
	const vaults_js_1 = require_vaults();
	const groups_js_1 = require_groups();
	var Client = class {
		constructor(innerClient) {
			this.secrets = new secrets_js_1$1.Secrets(innerClient);
			this.items = new items_js_1.Items(innerClient);
			this.vaults = new vaults_js_1.Vaults(innerClient);
			this.groups = new groups_js_1.Groups(innerClient);
		}
	};
	exports.Client = Client;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/shared_lib_core.js
var require_shared_lib_core = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/shared_lib_core.js": ((exports) => {
	var __createBinding$1 = exports && exports.__createBinding || (Object.create ? (function(o, m, k, k2) {
		if (k2 === void 0) k2 = k;
		var desc = Object.getOwnPropertyDescriptor(m, k);
		if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) desc = {
			enumerable: true,
			get: function() {
				return m[k];
			}
		};
		Object.defineProperty(o, k2, desc);
	}) : (function(o, m, k, k2) {
		if (k2 === void 0) k2 = k;
		o[k2] = m[k];
	}));
	var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? (function(o, v) {
		Object.defineProperty(o, "default", {
			enumerable: true,
			value: v
		});
	}) : function(o, v) {
		o["default"] = v;
	});
	var __importStar = exports && exports.__importStar || (function() {
		var ownKeys = function(o) {
			ownKeys = Object.getOwnPropertyNames || function(o$1) {
				var ar = [];
				for (var k in o$1) if (Object.prototype.hasOwnProperty.call(o$1, k)) ar[ar.length] = k;
				return ar;
			};
			return ownKeys(o);
		};
		return function(mod) {
			if (mod && mod.__esModule) return mod;
			var result = {};
			if (mod != null) {
				for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding$1(result, mod, k[i]);
			}
			__setModuleDefault(result, mod);
			return result;
		};
	})();
	var __awaiter$2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	Object.defineProperty(exports, "__esModule", { value: true });
	const fs = __importStar(require("fs"));
	const os = __importStar(require("os"));
	const path = __importStar(require("path"));
	const errors_1 = require_errors();
	/**
	* Find the 1Password shared lib path by asking an the wasm core synchronously.
	*/
	const find1PasswordLibPath = () => {
		const platform = os.platform();
		path.dirname(process.execPath);
		let searchPaths = [];
		switch (platform) {
			case "darwin":
				searchPaths = ["/Applications/1Password.app/Contents/Frameworks/libop_sdk_ipc_client.dylib", path.join(os.homedir(), "/Applications/1Password.app/Contents/Frameworks/libop_sdk_ipc_client.dylib")];
				break;
			case "linux":
				searchPaths = [
					"/usr/bin/1password/libop_sdk_ipc_client.so",
					"/opt/1Password/libop_sdk_ipc_client.so",
					"/snap/bin/1password/libop_sdk_ipc_client.so"
				];
				break;
			case "win32":
				searchPaths = [
					path.join(os.homedir(), "/AppData/Local/1Password/op_sdk_ipc_client.dll"),
					"C:/Program Files/1Password/app/8/op_sdk_ipc_client.dll",
					"C:/Program Files (x86)/1Password/app/8/op_sdk_ipc_client.dll",
					path.join(os.homedir(), "/AppData/Local/1Password/app/8/op_sdk_ipc_client.dll")
				];
				break;
			default: throw new Error(`Unsupported platform: ${platform}`);
		}
		for (const addonPath of searchPaths) if (fs.existsSync(addonPath)) return addonPath;
		throw new Error("1Password desktop application not found");
	};
	/**
	* SharedLibCore: wrapper around the dynamically loaded shared library
	*/
	var SharedLibCore = class {
		constructor(accountName) {
			this.lib = null;
			try {
				const libPath = find1PasswordLibPath();
				const moduleStub = { exports: {} };
				process.dlopen(moduleStub, libPath);
				if (typeof moduleStub === "object" && moduleStub !== null && typeof moduleStub.exports === "object" && moduleStub.exports !== null && "sendMessage" in moduleStub.exports && typeof moduleStub.exports.sendMessage === "function") this.lib = moduleStub.exports;
				else throw new Error("Failed to initialize native library: sendMessage function not found on module.");
			} catch (e) {
				console.error("A critical error occurred while loading the native addon:", e);
				this.lib = null;
			}
			this.acccountName = accountName;
		}
		/**
		* callSharedLibrary - send string to native function, receive string back.
		*/
		callSharedLibrary(input, operation_type) {
			return __awaiter$2(this, void 0, void 0, function* () {
				if (!this.lib) throw new Error("Native library is not available.");
				if (!input || input.length === 0) throw new Error("internal: empty input");
				const inputEncoded = Buffer.from(input, "utf8").toString("base64");
				const req = {
					account_name: this.acccountName,
					kind: operation_type,
					payload: inputEncoded
				};
				const inputBuf = Buffer.from(JSON.stringify(req), "utf8");
				const nativeResponse = yield this.lib.sendMessage(inputBuf);
				if (!(nativeResponse instanceof Uint8Array)) throw new Error(`Native function returned an unexpected type. Expected Uint8Array, got ${typeof nativeResponse}`);
				const respString = new TextDecoder().decode(nativeResponse);
				const response = JSON.parse(respString);
				if (response.success) return Buffer.from(response.payload).toString("utf8");
				else {
					const errorMessage = Array.isArray(response.payload) ? String.fromCharCode(...response.payload) : JSON.stringify(response.payload);
					(0, errors_1.throwError)(errorMessage);
				}
			});
		}
		initClient(config) {
			return __awaiter$2(this, void 0, void 0, function* () {
				return this.callSharedLibrary(config, "init_client");
			});
		}
		invoke(invokeConfigBytes) {
			return __awaiter$2(this, void 0, void 0, function* () {
				return this.callSharedLibrary(invokeConfigBytes, "invoke");
			});
		}
		releaseClient(clientId) {
			this.callSharedLibrary(clientId, "release_client").catch((err) => {
				console.warn("failed to release client:", err);
			});
		}
	};
	exports.SharedLibCore = SharedLibCore;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/client_builder.js
var require_client_builder = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/client_builder.js": ((exports) => {
	var __awaiter$1 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	Object.defineProperty(exports, "__esModule", { value: true });
	const core_js_1$1 = require_core();
	const configuration_js_1$1 = require_configuration();
	const client_js_1 = require_client();
	const shared_lib_core_js_1 = require_shared_lib_core();
	const finalizationRegistry = new FinalizationRegistry((heldClient) => {
		heldClient.core.releaseClient(heldClient.id);
	});
	/**
	* Creates a 1Password SDK client with a given core implementation.
	* @returns The authenticated 1Password SDK client.
	*/
	const createClientWithCore = (config, core) => __awaiter$1(void 0, void 0, void 0, function* () {
		const authConfig = (0, configuration_js_1$1.clientAuthConfig)(config);
		if (authConfig.accountName) core.setInner(new shared_lib_core_js_1.SharedLibCore(authConfig.accountName));
		const clientId = yield core.initClient(authConfig);
		const inner = new core_js_1$1.InnerClient(parseInt(clientId, 10), core, authConfig);
		const client = new client_js_1.Client(inner);
		finalizationRegistry.register(client, inner);
		return client;
	});
	exports.createClientWithCore = createClientWithCore;
}) });

//#endregion
//#region ../../node_modules/@1password/sdk/dist/sdk.js
var require_sdk = /* @__PURE__ */ __commonJS({ "../../node_modules/@1password/sdk/dist/sdk.js": ((exports) => {
	var __createBinding = exports && exports.__createBinding || (Object.create ? (function(o, m, k, k2) {
		if (k2 === void 0) k2 = k;
		var desc = Object.getOwnPropertyDescriptor(m, k);
		if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) desc = {
			enumerable: true,
			get: function() {
				return m[k];
			}
		};
		Object.defineProperty(o, k2, desc);
	}) : (function(o, m, k, k2) {
		if (k2 === void 0) k2 = k;
		o[k2] = m[k];
	}));
	var __exportStar = exports && exports.__exportStar || function(m, exports$1) {
		for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports$1, p)) __createBinding(exports$1, m, p);
	};
	var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
		function adopt(value) {
			return value instanceof P ? value : new P(function(resolve) {
				resolve(value);
			});
		}
		return new (P || (P = Promise))(function(resolve, reject) {
			function fulfilled(value) {
				try {
					step(generator.next(value));
				} catch (e) {
					reject(e);
				}
			}
			function rejected(value) {
				try {
					step(generator["throw"](value));
				} catch (e) {
					reject(e);
				}
			}
			function step(result) {
				result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
			}
			step((generator = generator.apply(thisArg, _arguments || [])).next());
		});
	};
	Object.defineProperty(exports, "__esModule", { value: true });
	exports.createClient = exports.DesktopAuth = exports.Secrets = exports.DEFAULT_INTEGRATION_VERSION = exports.DEFAULT_INTEGRATION_NAME = void 0;
	const core_js_1 = require_core();
	const client_builder_js_1 = require_client_builder();
	exports.DEFAULT_INTEGRATION_NAME = "Unknown";
	exports.DEFAULT_INTEGRATION_VERSION = "Unknown";
	var secrets_js_1 = require_secrets();
	Object.defineProperty(exports, "Secrets", {
		enumerable: true,
		get: function() {
			return secrets_js_1.Secrets;
		}
	});
	__exportStar(require_client(), exports);
	__exportStar(require_errors(), exports);
	__exportStar(require_types(), exports);
	var configuration_js_1 = require_configuration();
	Object.defineProperty(exports, "DesktopAuth", {
		enumerable: true,
		get: function() {
			return configuration_js_1.DesktopAuth;
		}
	});
	/**
	* Creates a default 1Password SDK client.
	* @returns The authenticated 1Password SDK client.
	*/
	const createClient$1 = (config) => __awaiter(void 0, void 0, void 0, function* () {
		return (0, client_builder_js_1.createClientWithCore)(config, new core_js_1.SharedCore());
	});
	exports.createClient = createClient$1;
}) });

//#endregion
//#region src/index.ts
var import_sdk = /* @__PURE__ */ __toESM(require_sdk());
const _clients = {};
const CACHE_TTL_MS = 60 * 1e3;
const _cache = {};
async function op(args) {
	let authMethod;
	let hash;
	switch (args.values.authMethod) {
		case "desktop": {
			const account = args.values.token;
			if (typeof account !== "string" || !account) return { error: "Missing account name" };
			hash = node_crypto.default.createHash("sha256").update(`desktop:${account}`).digest("hex");
			authMethod = new import_sdk.DesktopAuth(account);
			break;
		}
		case "token": {
			const token = args.values.token;
			if (typeof token !== "string" || !token) return { error: "Missing service token" };
			hash = node_crypto.default.createHash("sha256").update(`token:${token}`).digest("hex");
			authMethod = token;
			break;
		}
		default: return { error: "Invalid authentication method" };
	}
	if (!_clients[hash]) try {
		_clients[hash] = await (0, import_sdk.createClient)({
			auth: authMethod,
			integrationName: "Yaak 1Password Plugin",
			integrationVersion: "v1.0.0"
		});
	} catch (e) {
		return { error: e };
	}
	return {
		client: _clients[hash],
		clientHash: hash
	};
}
async function getValue(args, vaultId, itemId, fieldId) {
	const res = await op(args);
	if ("error" in res) return { error: res.error };
	const clientHash = res.clientHash;
	const client = res.client;
	if (!vaultId || typeof vaultId !== "string") return { error: "No vault specified" };
	if (!itemId || typeof itemId !== "string") return { error: "No item specified" };
	if (!fieldId || typeof fieldId !== "string") return { error: "No field specified" };
	try {
		const cacheKey = `${clientHash}:item:${vaultId}:${itemId}:${fieldId}`;
		let value = getCached(cacheKey);
		if (!value) {
			value = await client.secrets.resolve(`op://${vaultId}/${itemId}/${fieldId}`);
			setCache(cacheKey, value);
		}
		return { value };
	} catch (e) {
		return { error: e };
	}
}
const plugin = { templateFunctions: [{
	name: "1password.item",
	description: "Get a secret",
	previewArgs: ["field"],
	args: [
		{
			type: "h_stack",
			inputs: [{
				name: "authMethod",
				type: "select",
				label: "Authentication Method",
				defaultValue: "token",
				options: [{
					label: "Service Account",
					value: "token"
				}, {
					label: "Desktop App",
					value: "desktop"
				}]
			}, {
				name: "token",
				type: "text",
				defaultValue: "${[1PASSWORD_TOKEN]}",
				dynamic(_ctx, args) {
					switch (args.values.authMethod) {
						case "desktop": return {
							label: "Account Name",
							description: "Account name can be taken from the sidebar of the 1Password App. Make sure you're on the BETA version of the 1Password app and have \"Integrate with other apps\" enabled in Settings > Developer."
						};
						case "token": return {
							label: "Token",
							description: "Token can be generated from the 1Password website by visiting Developer > Service Accounts",
							password: true
						};
					}
					return { hidden: true };
				}
			}]
		},
		{
			name: "vault",
			label: "Vault",
			type: "select",
			options: [],
			async dynamic(_ctx, args) {
				const res = await op(args);
				if ("error" in res) return { hidden: true };
				const clientHash = res.clientHash;
				const client = res.client;
				const cacheKey = `${clientHash}:vaults`;
				return { options: (getCached(cacheKey) ?? setCache(cacheKey, await client.vaults.list({ decryptDetails: true }))).map((vault) => {
					let title = vault.id;
					if ("title" in vault) title = vault.title;
					else if ("name" in vault) title = vault.name;
					return {
						label: `${title} (${vault.activeItemCount} Items)`,
						value: vault.id
					};
				}) };
			}
		},
		{
			name: "item",
			label: "Item",
			type: "select",
			options: [],
			async dynamic(_ctx, args) {
				const res = await op(args);
				if ("error" in res) return { hidden: true };
				const clientHash = res.clientHash;
				const client = res.client;
				const vaultId = args.values.vault;
				if (typeof vaultId !== "string") return { hidden: true };
				try {
					const cacheKey = `${clientHash}:items:${vaultId}`;
					return { options: (getCached(cacheKey) ?? setCache(cacheKey, await client.items.list(vaultId))).map((item) => ({
						label: `${item.title} ${item.category}`,
						value: item.id
					})) };
				} catch {
					return { hidden: true };
				}
			}
		},
		{
			name: "field",
			label: "Field",
			type: "select",
			options: [],
			async dynamic(_ctx, args) {
				const res = await op(args);
				if ("error" in res) return { hidden: true };
				const clientHash = res.clientHash;
				const client = res.client;
				const vaultId = args.values.vault;
				const itemId = args.values.item;
				if (typeof vaultId !== "string" || typeof itemId !== "string") return { hidden: true };
				try {
					const cacheKey = `${clientHash}:item:${vaultId}:${itemId}`;
					return { options: (getCached(cacheKey) ?? setCache(cacheKey, await client.items.get(vaultId, itemId))).fields.map((field) => ({
						label: field.title,
						value: field.id
					})) };
				} catch {
					return { hidden: true };
				}
			}
		}
	],
	async onRender(_ctx, args) {
		const vaultId = args.values.vault;
		const itemId = args.values.item;
		const fieldId = args.values.field;
		const res = await getValue(args, vaultId, itemId, fieldId);
		if ("error" in res) throw res.error;
		return res.value;
	}
}] };
function getCached(key) {
	const entry = _cache[key];
	if (entry && entry.expiresAt > Date.now()) return entry.data;
	if (entry) delete _cache[key];
}
function setCache(key, data) {
	_cache[key] = {
		data,
		expiresAt: Date.now() + CACHE_TTL_MS
	};
	return data;
}

//#endregion
exports.plugin = plugin;