Query editor
WITH perp_vol AS (SELECTfrom_unixtime(CAST(json_extract_scalar(item, '$[0]') AS bigint)) AS day,CAST(json_extract_scalar(item, '$[1]') AS double) AS perp_volumeFROM (SELECT json_parse(http_get('https://api.llama.fi/summary/derivatives/hyperliquid?dataType=dailyVolume')) AS parsed_data)CROSS JOIN UNNEST(CAST(json_extract(parsed_data, '$.totalDataChart') AS array(json))) AS t(item)),spot_vol AS (SELECTfrom_unixtime(CAST(json_extract_scalar(item, '$[0]') AS bigint)) AS day,CAST(json_extract_scalar(item, '$[1]') AS double) AS spot_volumeFROM (SELECT json_parse(http_get('https://api.llama.fi/summary/dexs/hyperliquid?dataType=dailyVolume')) AS parsed_data)CROSS JOIN UNNEST(CAST(json_extract(parsed_data, '$.totalDataChart') AS array(json))) AS t(item))SELECTCOALESCE(p.day, s.day) AS day,COALESCE(p.perp_volume, 0) AS perp_volume,COALESCE(s.spot_volume, 0) AS spot_volume,COALESCE(p.perp_volume, 0) + COALESCE(s.spot_volume, 0) AS total_volumeFROM perp_vol pFULL OUTER JOIN spot_vol s ON p.day = s.dayORDER BY day ASC