+ {isLLDPAvailable &&
+ (
+
+ )
}
diff --git a/ui/src/utils/jsonrpc.ts b/ui/src/utils/jsonrpc.ts
index 18659f00..848e8f7c 100644
--- a/ui/src/utils/jsonrpc.ts
+++ b/ui/src/utils/jsonrpc.ts
@@ -1,4 +1,4 @@
-import { useRTCStore } from "@/hooks/stores";
+import { LLDPNeighbor, useRTCStore } from "@/hooks/stores";
import { sleep } from "@/utils";
// JSON-RPC utility for use outside of React components
@@ -170,6 +170,14 @@ export async function getNetworkState() {
return response.result;
}
+export async function getLLDPNeighbors() {
+ const response = await callJsonRpc({ method: "getLLDPNeighbors" });
+ if (response.error) {
+ throw new Error(response.error.message);
+ }
+ return response.result;
+}
+
export async function renewDHCPLease() {
const response = await callJsonRpc({ method: "renewDHCPLease" });
if (response.error) {