workflow_utils/
ip.rs

1use crate::imports::*;
2
3pub async fn public() -> Result<String> {
4    Ok(http::get("https://api.ipify.org").await?)
5}
6
7#[cfg(not(target_arch = "wasm32"))]
8pub mod blocking {
9    use super::*;
10
11    pub fn public() -> Result<String> {
12        Ok(reqwest::blocking::get("https://api.ipify.org")?.text()?)
13    }
14}