"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.listAllowedPortsDefinition = void 0;
exports.listAllowedPorts = listAllowedPorts;
const config_1 = require("../../config");
async function listAllowedPorts() {
    const config = await (0, config_1.getConfig)();
    if (!config.worker?.tunnel?.enabled) {
        return [];
    }
    return config.worker.tunnel.allowedPorts || [];
}
exports.listAllowedPortsDefinition = {
    type: "function",
    function: {
        name: "listAllowedPorts",
        description: "List all ports that are being forwarded through the worker tunnel. Returns an array of port numbers that can be accessed via the tunnel system.",
        parameters: {
            type: "object",
            properties: {},
            required: [],
        },
    },
};
//# sourceMappingURL=listAllowedPorts.js.map