{
  "schemaVersion": "1.0.0",
  "id": "miqat",
  "name": "Miqat",
  "category": "Astronomy & Compass",
  "status": "operational",
  "description": "Accurate daily prayer times for your city, real-time 3D Kaaba compass, and Islamic calendar. Clean, peaceful, and works anywhere.",
  "runtime": "client-edge",
  "capabilities": [
    "Automatic city name and Indian postal PIN code geocoding resolution",
    "Solar ephemeris calculations (VSOP87 & astronomical twilight angles)",
    "Great Circle geodesic Kaaba azimuth bearing and compass quadrant",
    "Umm al-Qura Hijri lunar calendar bidirectional conversion",
    "Crescent moon visibility forecasting (Yallop/Odeh algorithm)",
    "Pre-calculated fasting schedule and countdowns (Sehri cut-off, Iftar)"
  ],
  "endpoints": [
    {
      "method": "GET",
      "path": "/v1/prayer-times",
      "summary": "Daily prayer times for city, postal PIN, or coordinates",
      "url": "https://api.xicae.dev/miqat/v1/prayer-times"
    },
    {
      "method": "GET",
      "path": "/v1/qibla",
      "summary": "Kaaba azimuth bearing, spherical distance, and quadrant",
      "url": "https://api.xicae.dev/miqat/v1/qibla"
    },
    {
      "method": "GET",
      "path": "/v1/hijri-date",
      "summary": "Gregorian to Umm al-Qura Hijri date conversion",
      "url": "https://api.xicae.dev/miqat/v1/hijri-date"
    },
    {
      "method": "GET",
      "path": "/v1/moon-phase",
      "summary": "Lunar illumination and crescent visibility forecast",
      "url": "https://api.xicae.dev/miqat/v1/moon-phase"
    }
  ],
  "mcp": {
    "url": "https://xicae.dev/miqat/mcp",
    "tools": [
      {
        "name": "miqat_get_prayer_times",
        "description": "Calculate verified daily prayer times (Fajr, Sunrise, Dhuhr, Asr, Maghrib, Isha), Suhoor end, Iftar, fasting duration, and Qibla bearing. Accepts city name (e.g. \"Delhi\", \"London\") or Indian 6-digit postal PIN code (e.g. \"110001\") with zero manual coordinates needed.",
        "parameters": {
          "type": "object",
          "properties": {
            "city_or_pin_code": {
              "type": "string",
              "description": "City name or Indian postal PIN code (auto-resolves coordinates, timezone, calculation method, and Asr school)"
            },
            "latitude": {
              "type": "number",
              "description": "Latitude in decimal degrees (optional if city_or_pin_code provided)"
            },
            "longitude": {
              "type": "number",
              "description": "Longitude in decimal degrees (optional if city_or_pin_code provided)"
            },
            "date": {
              "type": "string",
              "description": "Date in YYYY-MM-DD format (defaults to current date)"
            },
            "calculation_method": {
              "type": "string",
              "description": "Calculation standard convention (auto-selected by region if omitted)",
              "enum": [
                "UmmAlQura",
                "MuslimWorldLeague",
                "ISNA",
                "Egyptian",
                "Karachi",
                "Tehran"
              ]
            },
            "asr_school": {
              "type": "string",
              "description": "Asr calculation shadow ratio standard (Hanafi for South Asia, Shafi for others)",
              "enum": [
                "Shafi",
                "Hanafi"
              ]
            }
          },
          "required": []
        }
      },
      {
        "name": "miqat_calculate_qibla_vector",
        "description": "Calculate Great Circle geodesic forward azimuth bearing in degrees, compass quadrant, and distance in km from any city, PIN code, or coordinates to the Kaaba in Mecca.",
        "parameters": {
          "type": "object",
          "properties": {
            "city_or_pin_code": {
              "type": "string",
              "description": "City name or postal PIN code"
            },
            "latitude": {
              "type": "number",
              "description": "Observer latitude in decimal degrees"
            },
            "longitude": {
              "type": "number",
              "description": "Observer longitude in decimal degrees"
            }
          },
          "required": []
        }
      },
      {
        "name": "miqat_convert_hijri_date",
        "description": "Convert between Gregorian calendar and Umm al-Qura Islamic Hijri calendar with moon phase illumination and Islamic holiday detection.",
        "parameters": {
          "type": "object",
          "properties": {
            "date": {
              "type": "string",
              "description": "Gregorian date in YYYY-MM-DD format (defaults to today)"
            },
            "offset_days": {
              "type": "number",
              "description": "Manual lunar sighting offset (-2 to +2)"
            }
          },
          "required": []
        }
      },
      {
        "name": "miqat_crescent_visibility",
        "description": "Calculate astronomical lunar crescent visibility score using Odeh and Yallop criteria, moon lag time after sunset, and visibility classification (Zone A to Zone D) for Eid and month starts.",
        "parameters": {
          "type": "object",
          "properties": {
            "city_or_pin_code": {
              "type": "string",
              "description": "City name or postal PIN code"
            },
            "latitude": {
              "type": "number",
              "description": "Observer latitude in decimal degrees"
            },
            "longitude": {
              "type": "number",
              "description": "Observer longitude in decimal degrees"
            },
            "date": {
              "type": "string",
              "description": "Date in YYYY-MM-DD format"
            }
          },
          "required": []
        }
      },
      {
        "name": "miqat_sun_position_now",
        "description": "Calculate instantaneous solar altitude angle, solar azimuth bearing, solar zenith angle, equation of time, and sundial shadow length multiplier for any city or coordinates.",
        "parameters": {
          "type": "object",
          "properties": {
            "city_or_pin_code": {
              "type": "string",
              "description": "City name or postal PIN code"
            },
            "latitude": {
              "type": "number",
              "description": "Observer latitude in decimal degrees"
            },
            "longitude": {
              "type": "number",
              "description": "Observer longitude in decimal degrees"
            },
            "date": {
              "type": "string",
              "description": "Date and time in ISO format or YYYY-MM-DD"
            }
          },
          "required": []
        }
      }
    ]
  },
  "rateLimit": {
    "requestsPerMinute": 60,
    "quotaReset": "sliding-window"
  },
  "documentation": "https://xicae.dev/llms.txt"
}