| Crates.io | popo-cli |
| lib.rs | popo-cli |
| version | 0.1.0 |
| created_at | 2025-10-07 02:20:10.465466+00 |
| updated_at | 2025-10-07 02:20:10.465466+00 |
| description | PopocatΓ©petl volcano monitoring CLI and library |
| homepage | https://github.com/KyleEdwardDonaldson/PopoCLI |
| repository | https://github.com/KyleEdwardDonaldson/PopoCLI |
| max_upload_size | |
| id | 1871132 |
| size | 128,758 |
PopocatΓ©petl Volcano Monitoring CLI & Library
A fast, reliable command-line tool and Rust library for fetching real-time volcanic activity data from Mexico's CENAPRED monitoring system for PopocatΓ©petl volcano.
git clone https://github.com/KyleEdwardDonaldson/PopoCLI.git
cd PopoCLI
cargo install --path .
cargo install popo-cli
Fetch the latest volcano report (human-readable):
popo latest
Get data in JSON format:
popo json
Show detailed alert information:
popo alert
Fetch a specific historical date:
# Human-readable format
popo get 2022-03-22
# JSON format
popo get 2022-03-22 --json
Add to your Cargo.toml:
[dependencies]
popo-cli = "0.1.0"
Use in your Rust code:
use popo_cli::{Scraper, Result};
use chrono::NaiveDate;
fn main() -> Result<()> {
let scraper = Scraper::new();
// Fetch latest report
let report = scraper.fetch_latest()?;
println!("Alert Level: {:?}", report.alert_level);
println!("Exhalations (24h): {}", report.exhalations);
// Fetch historical date
let date = NaiveDate::from_ymd_opt(2022, 3, 22).unwrap();
let historical = scraper.fetch_date(date)?;
println!("Historical tremor: {}", historical.tremor_minutes_total);
Ok(())
}
Since popo outputs clean JSON, you can easily use it from any language:
Python:
import subprocess
import json
result = subprocess.run(['popo', 'json'], capture_output=True, text=True)
data = json.loads(result.stdout)
print(f"Alert Level: {data['alert_level']}")
Node.js:
const { execSync } = require('child_process');
const data = JSON.parse(execSync('popo json').toString());
console.log(`Alert Level: ${data.alert_level}`);
Go:
cmd := exec.Command("popo", "json")
output, _ := cmd.Output()
var data map[string]interface{}
json.Unmarshal(output, &data)
Each report includes:
popo latest)βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β POPOCATΓPETL VOLCANO MONITORING REPORT β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
π
Report Date: 2025-10-06
π Report Time: 2025-10-07 01:27:20 UTC
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SEISMIC ACTIVITY (Last 24 Hours)
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
π¨ Exhalations: 15
π₯ Explosions: 0
π Volcanotectonic events: 0
β±οΈ Total tremor: 53 minutes
ββ High frequency: 39 minutes
ββ Harmonic: 14 minutes
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
ALERT STATUS
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
π‘ Alert Level: Yellow
π Phase: AMARILLO - FASE 2
popo json){
"date": "2025-10-06",
"exhalations": 15,
"volcanotectonic_events": 0,
"tremor_minutes_total": 53,
"tremor_high_frequency_minutes": 39,
"tremor_harmonic_minutes": 14,
"explosions": 0,
"alert_level": "YELLOW",
"alert_phase": "AMARILLO - FASE 2",
"wind_direction": "n-n-w",
"so2_emissions_tons_per_day": 2603.0,
"image_urls": ["https://www.cenapred.unam.mx/media/..."],
"video_urls": ["https://www.cenapred.unam.mx/media/..."]
}
The scraper is resilient to:
cargo test
All tests include:
cargo build --release
The optimized binary will be in target/release/popo.
popo get 2022-03-22)popo range --from 2025-01-01 --to 2025-01-31)Contributions welcome! This is an open-source project to provide better access to volcanic monitoring data.
cargo testcargo fmtcargo clippyMIT License - see LICENSE for details
This tool scrapes publicly available data from CENAPRED's website. It is not affiliated with or endorsed by CENAPRED or UNAM. For official volcanic alerts and safety information, always refer directly to CENAPRED's official sources.
Safety First: Volcano monitoring data should be used for informational purposes only. Always follow official evacuation orders and safety guidelines from local authorities.
Made with π¦ Rust and β€οΈ for volcano science