# PayAI Macro Compare — Cross-Country Indicator Comparison

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

Returns the latest value of a single macroeconomic indicator for multiple countries side-by-side, with computed signals: rank, highest, lowest, spread, mean, and source citations.

## Facts

- Endpoint: GET https://payai.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/payai-macro-compare-cross-country-indicator-comparison-fdba086b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_DOIViPmaohxQu3Zhv1ss7

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 payai-macro-compare-cross-country-indicator-comparison-fdba086b
```

Example prompt: Compare inflation_cpi for the US, Germany, Japan, and Brazil — give me the latest value for each country, ranked highest to lowest, plus the spread and mean.

## When to prefer this

Use this endpoint when you need to compare a single macroeconomic or development indicator across multiple countries simultaneously and want computed signals (rank, spread, mean) rather than raw time-series data. Prefer this over the single-country time-series endpoint when the task is benchmarking or ranking countries rather than tracking trends over time for one country.

## Known failure modes

- Unknown indicator key returns an error or empty result
- Invalid or unrecognized country code/name causes missing data for that country
- No data available for the requested indicator/country/year combination
- Requesting fewer than two countries may not produce meaningful comparison signals
- Year parameter too far in the past may have no data for some indicators

## 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 JSON object containing: the latest available value of the requested indicator for each specified country, a ranking of countries by that value, the highest and lowest values with corresponding countries, the spread (max minus min), the mean across all countries, and a source citation for each data point.

## 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/payai-macro-compare-cross-country-indicator-comparison-fdba086b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from payai.agentstools.dev](https://www.zero.xyz/host/payai.agentstools.dev/llms.txt)
