export function omitUndefined(value) {
    return Object.fromEntries(Object.entries(value).filter(([, entry]) => entry !== undefined));
}
export function readObject(value) {
    return value && typeof value === 'object' && !Array.isArray(value) ? value : undefined;
}
export function readString(value) {
    return typeof value === 'string' ? value : undefined;
}
export function readBoolean(value) {
    return typeof value === 'boolean' ? value : undefined;
}
export function readNumber(value) {
    return typeof value === 'number' && Number.isFinite(value) ? value : undefined;
}
export function normalizeCommandText(value) {
    if (!value) {
        return undefined;
    }
    const trimmed = value.trim();
    if (!trimmed) {
        return undefined;
    }
    return trimmed.length > 2400 ? `${trimmed.slice(0, 2399)}…` : trimmed;
}
//# sourceMappingURL=control-plane-read-values.js.map