require "json" # Парсинг строки value = JSON.parse("[1, 2, 3]") p! value[0]