{
  "name": "Virga API",
  "description": "Agent-first Weather API with autonomous onboarding, prepaid credits, and normalized weather data. Designed for fully autonomous agent consumption — no human intervention required for account creation, billing, or API usage.",
  "version": "1.0.0",
  "provider": {
    "organization": "Virga",
    "url": "https://virga.dev"
  },
  "documentation_url": "https://virga.dev/docs",
  "supported_interfaces": [
    {
      "url": "https://api.virga.dev",
      "protocol": "http/rest",
      "description": "RESTful JSON API"
    }
  ],
  "capabilities": {
    "streaming": false,
    "pushNotifications": false
  },
  "default_input_modes": ["application/json"],
  "default_output_modes": ["application/json"],
  "security_schemes": {
    "apiKey": {
      "type": "apiKey",
      "in": "header",
      "name": "X-API-Key",
      "description": "API key prefixed with sk_virga_stage_ or sk_virga_prod_. Obtained by creating an account via POST /api/v1/accounts."
    },
    "x402": {
      "type": "x402",
      "description": "x402 USDC micropayments on Base L2. No account or API key needed. Send PAYMENT-SIGNATURE header with USDC payment proof. Weather endpoints return 402 with payment requirements when accessed without auth.",
      "network": "eip155:8453",
      "asset": "USDC"
    }
  },
  "skills": [
    {
      "id": "create-account",
      "name": "Create Account",
      "description": "Create a new Virga account and receive a stage API key. No authentication required.",
      "tags": ["account", "onboarding"],
      "examples": [
        "Create an account to start using the weather API",
        "Sign up for Virga"
      ]
    },
    {
      "id": "get-current-weather",
      "name": "Get Current Weather",
      "description": "Get current weather conditions for any location by latitude and longitude. Costs 1 credit in production.",
      "tags": ["weather", "current"],
      "examples": [
        "What is the current weather in New York?",
        "Get temperature in London right now"
      ]
    },
    {
      "id": "get-hourly-forecast",
      "name": "Get Hourly Forecast",
      "description": "Get hourly weather forecast for up to 48 hours. Costs 2 credits in production.",
      "tags": ["weather", "forecast"],
      "examples": [
        "Will it rain in the next 6 hours in Seattle?",
        "Hourly forecast for Tokyo"
      ]
    },
    {
      "id": "get-daily-forecast",
      "name": "Get Daily Forecast",
      "description": "Get daily weather forecast for up to 7 days. Costs 2 credits in production.",
      "tags": ["weather", "forecast"],
      "examples": [
        "What's the weather this week in Paris?",
        "7-day forecast for San Francisco"
      ]
    },
    {
      "id": "get-historical-weather",
      "name": "Get Historical Weather",
      "description": "Get weather data for a past date. Costs 3 credits in production.",
      "tags": ["weather", "historical"],
      "examples": [
        "What was the weather in Chicago on January 1st?",
        "Historical temperature data for Berlin"
      ]
    },
    {
      "id": "batch-weather",
      "name": "Batch Weather Queries",
      "description": "Fetch weather for multiple locations in a single request. Max 25 locations.",
      "tags": ["weather", "batch"],
      "examples": [
        "Get current weather for 5 cities at once",
        "Batch forecast for all my office locations"
      ]
    },
    {
      "id": "topup-credits",
      "name": "Top Up Credits",
      "description": "Charge saved payment method off-session and add credits immediately. No checkout URL or browser redirect needed.",
      "tags": ["billing", "credits"],
      "examples": [
        "Top up 2000 credits using my saved card",
        "Add more credits to my account"
      ]
    },
    {
      "id": "configure-auto-topup",
      "name": "Configure Auto-Topup",
      "description": "Set up automatic credit replenishment. When credit balance drops below the threshold during API usage, credits are purchased automatically.",
      "tags": ["billing", "automation"],
      "examples": [
        "Enable auto-topup when my balance drops below 100 credits",
        "Disable automatic credit replenishment"
      ]
    }
  ]
}
