"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getVideoUrl = void 0;
const getVideoUrl = (outputString) => {
    let videoUrl = '';
    try {
        const parsedOutput = JSON.parse(outputString);
        if (parsedOutput && typeof parsedOutput.trusys === 'object' && parsedOutput.trusys.output && Array.isArray(parsedOutput.trusys.output)) {
            for (const item of parsedOutput.trusys.output) {
                if (item.type === 'video_url' && typeof item.video_url === 'object') {
                    videoUrl = item.video_url?.url;
                    break;
                }
            }
        }
    }
    catch { }
    return videoUrl;
};
exports.getVideoUrl = getVideoUrl;
//# sourceMappingURL=utils.js.map