framework
Version:
The (AI) Framework: turnkey, zero-config AI orchestration that wraps a coding-agent CLI (Claude Code) as a black box and takes you from an idea to a running app. Vite for AI.
12 lines • 652 B
JavaScript
import { pingRemote } from '../dashboard/remote-run.js';
function isDeviceCheck(value) {
const d = value;
return !!d && typeof d.id === 'string' && typeof d.url === 'string' && typeof d.token === 'string';
}
/** Ping each saved device and map its id to whether it answered (#1072). Bad entries are dropped. */
export async function checkDevices(devices) {
const valid = (Array.isArray(devices) ? devices : []).filter(isDeviceCheck);
const entries = await Promise.all(valid.map(async (d) => [d.id, await pingRemote({ url: d.url, token: d.token })]));
return Object.fromEntries(entries);
}
//# sourceMappingURL=devices.telefunc.js.map