# Macroeconomic Indicator Cross-Country Comparison

> Macroeconomic Indicator Cross-Country Comparison is a paid API for AI agents from api.agentstools.dev, paid per call via x402, $0.02/call, status unknown (last checked 2026-10-11).

Compares a single macroeconomic indicator across multiple countries, returning latest values with computed signals: rank, highest, lowest, spread, and mean — each cited to its source.

## Facts

- Endpoint: GET https://api.agentstools.dev/macro/compare?utm_source=zero.xyz
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/macroeconomic-indicator-cross-country-comparison-429c00be
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap__Gcz4HrL9O7oXKZiE66Kk

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability macroeconomic-indicator-cross-country-comparison-429c00be
```

Example prompt: Compare inflation (CPI) across the US, Germany, Brazil, and India — show me the latest value for each, which country ranks highest, and what the spread is.

## When to prefer this

Use this endpoint when you need to benchmark or rank a single macroeconomic, demographic, environmental, or social indicator across two or more countries simultaneously, especially when you want not just raw values but computed comparative signals (rank, spread, mean). Prefer this over a single-country lookup when the user's question is inherently comparative ('which country is highest', 'how does X compare to Y').

## Known failure modes

- Unknown or misspelled indicator key returns an error or empty result
- Fewer than two valid countries recognized causes comparison to fail
- No data available for a country/indicator/year combination returns null values for that entry
- Invalid ISO country code returns an error or is silently excluded
- Year too far in the past or future with no available data returns empty

## How this service works

One indicator compared across several countries: the latest value for each plus computed signals — rank, highest and lowest, spread and mean. Each value is cited to its source.

## Output

A structured JSON object containing, for each requested country, the latest available value for the indicator (at or before the reference year), plus computed cross-country signals: rank ordering, the highest and lowest values among the set, spread (max minus min), and mean — all with source citations.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "indicator",
      "country"
     ],
     "properties": {
      "year": {
       "type": "integer",
       "description": "Reference year; the latest available value at or before it is used (default latest)"
      },
      "country": {
       "type": "string",
       "description": "Two or more countries as ISO-2, ISO-3 or names, comma-separated"
      },
      "indicator": {
       "type": "string",
       "examples": [
        "gdp_current_usd",
        "gdp_per_capita_usd",
        "gdp_growth",
        "gni_per_capita_atlas",
        "gross_savings_gdp",
        "inflation_cpi",
        "real_interest_rate",
        "broad_money_gdp",
        "unemployment",
        "labor_force",
        "govt_debt_gdp",
        "govt_health_exp_gdp",
        "govt_education_exp_gdp",
        "trade_balance_gdp",
        "current_account_gdp",
        "exports_gdp",
        "imports_gdp",
        "fdi_net_inflows_gdp",
        "population",
        "population_growth",
        "life_expectancy",
        "gini",
        "poverty_headcount_national",
        "urban_population_pct",
        "co2_per_capita",
        "renewable_energy_pct",
        "electricity_access_pct",
        "internet_users_pct",
        "mobile_subscriptions_per_100"
       ],
       "description": "Canonical indicator key or a raw World Bank code"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/macroeconomic-indicator-cross-country-comparison-429c00be/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.agentstools.dev](https://www.zero.xyz/host/api.agentstools.dev/llms.txt)
