import type { Nodes } from "@threefold/grid_client"; export async function gatewayNodes(nodes: Nodes) { const gwNodes = await nodes.getAccessNodes(); return gwNodes; } export async function getNodeDomain(nodes: Nodes, nodeId: number): Promise { const gwNodes = await gatewayNodes(nodes); const node = gwNodes[nodeId]; const domain = node["domain"]; return domain; }