Ir al contenido
ClockCrest

Servidor MCP de hora, fechas y días festivos

El Model Context Protocol (MCP) permite que un asistente de IA llame a herramientas de un servidor. ClockCrest mantiene un servidor MCP público con 16 herramientas de solo lectura —las mismas operaciones que la API JSON, ejecutadas por el mismo código— para que un asistente consulte horas, fechas y festivos en lugar de suponerlos.

Endpoint

  • URL: https://clockcrest.com/mcp — solo HTTP POST.
  • Transporte: Streamable HTTP, sin estado. Cada POST recibe una única respuesta JSON-RPC en application/json; no hay flujo SSE ni identificador de sesión.
  • Autenticación: ninguna. Todas las herramientas son de solo lectura y devuelven datos de referencia públicos o un cálculo, así que un token no tendría nada que proteger.
  • CORS está abierto, de modo que los clientes que se ejecutan en el navegador pueden conectarse.

Versiones del protocolo

El servidor anuncia estas versiones en su respuesta a server/discover (capturada el 2026-12-01): 2026-07-28, 2025-11-25, 2025-06-18, 2025-03-26.

  • 2026-07-28: sin saludo inicial. Cada petición lleva su versión del protocolo en params._meta y en las cabeceras MCP-Protocol-Version y Mcp-Method (además de Mcp-Name en tools/call), que se comparan con el cuerpo. server/discover está implementado.
  • 2025-11-25, 2025-06-18, 2025-03-26: el saludo inicial initialize y, después, peticiones simples. No se emite identificador de sesión.

Conectar un cliente

En cualquier cliente MCP que admita servidores remotos, añade un servidor de tipo «HTTP» (también llamado «Streamable HTTP») con la URL anterior y sin autenticación. Desde la línea de comandos de Claude Code:

claude mcp add --transport http clockcrest https://clockcrest.com/mcp

Muchos clientes leen en su lugar una entrada JSON con esta forma (el nombre de la clave y el del archivo cambian según el cliente):

{
  "mcpServers": {
    "clockcrest": {
      "type": "http",
      "url": "https://clockcrest.com/mcp"
    }
  }
}

Probarlo a mano

Una petición initialize y su respuesta real:

curl -X POST https://clockcrest.com/mcp \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json, text/event-stream' \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-11-25","capabilities":{},"clientInfo":{"name":"example-client","version":"1.0.0"}}}'
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "protocolVersion": "2025-11-25",
    "capabilities": {
      "tools": {}
    },
    "serverInfo": {
      "name": "clockcrest",
      "title": "ClockCrest time tools",
      "version": "1.1.0"
    },
    "instructions": "Time, date, calendar, holiday, astronomy, weather and market-hours tools from clockcrest.com. Public and read-only: no authentication. Zones are IANA names (Europe/Paris); countries are ISO 3166-1 alpha-2 codes (FR); dates are YYYY-MM-DD; coordinates are decimal degrees. Use find_timezone or search_city to turn a place name into a zone and coordinates. Holiday data covers 2025–2028 (source: Nager.Date); calculated prayer times and Hijri dates can differ from local announcements, exchange holidays are not modelled, and get_weather forwards rounded coordinates to MET Norway (credit \"Weather data from MET Norway\") — every result carries its source and notes."
  }
}

Después, una llamada a una herramienta. El resultado lleva los datos dos veces: en structuredContent y, como el mismo JSON, en un bloque de texto.

curl -X POST https://clockcrest.com/mcp \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json, text/event-stream' \
  -H 'MCP-Protocol-Version: 2025-11-25' \
  -d '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"calculate_business_days","arguments":{"country":"FR","start":"2026-12-01","end":"2026-12-31"}}}'
{
  "jsonrpc": "2.0",
  "id": 3,
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\"country\":\"FR\",\"countryName\":\"France\",\"start\":\"2026-12-01\",…"
      }
    ],
    "structuredContent": {
      "country": "FR",
      "countryName": "France",
      "start": "2026-12-01",
      "end": "2026-12-31",
      "endInclusive": true,
      "calendarDays": 31,
      "businessDays": 22,
      "weekend": ["Sunday", "Saturday"],
      "holidaysExcluded": [
        {
          "date": "2026-12-25",
          "name": "Christmas Day",
          "localName": "Noël"
        }
      ],
      "holidaysOnWeekend": [],
      "rules": "Weekend days and nationwide public holidays are excluded; regional holidays are not.",
      "source": "Nager.Date",
      "sourceUrl": "https://date.nager.at",
      "dataYears": [2025, 2026, 2027, 2028],
      "lastUpdated": "2026-11-30"
    },
    "isError": false
  }
}

Errores

Unos argumentos incorrectos son un error de la herramienta, no del protocolo: la llamada termina bien con isError: true y el objeto de error de la API como texto, para que el modelo pueda leerlo y corregirse.

curl -X POST https://clockcrest.com/mcp \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json, text/event-stream' \
  -H 'MCP-Protocol-Version: 2025-11-25' \
  -d '{"jsonrpc":"2.0","id":4,"method":"tools/call","params":{"name":"get_current_time","arguments":{"tz":"Mars/Olympus"}}}'
{
  "jsonrpc": "2.0",
  "id": 4,
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\"error\":{\"code\":\"invalid_timezone\",\"message\":\"Unknown time zone in \\\"tz\\\". Use an IANA name such as Europe/Paris.\"}}"
      }
    ],
    "isError": true
  }
}

Los problemas de protocolo usan códigos de error JSON-RPC:

  • -32700 — el cuerpo no es JSON válido
  • -32600 — no es una petición JSON-RPC 2.0, es un lote, el método, el tipo de contenido o el origen son incorrectos, o el cuerpo es demasiado grande
  • -32601 — método desconocido
  • -32602 — parámetros no válidos, o nombre de herramienta desconocido
  • -32603 — error interno
  • -32020 — falta una cabecera de protocolo o no coincide con el cuerpo
  • -32022 — versión del protocolo no admitida

Herramientas

Las 16 herramientas, en el orden en que las devuelve tools/list. La descripción es el texto en inglés que recibe el modelo. Cada herramienta está anotada como de solo lectura, idempotente y de mundo cerrado.

get_current_time

Hora actual en una zona horaria

Current date and time in an IANA time zone, with its UTC offset, abbreviation, whether daylight saving time is in effect, and the next offset change. Use find_timezone first if you only have a city or country name.

La misma operación por REST: GET /api/v1/time/now

Esquema de entrada
{
  "type": "object",
  "properties": {
    "tz": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "pattern": "^[A-Za-z0-9_+\\-/]+$",
      "description": "IANA time zone name, e.g. Europe/Paris"
    }
  },
  "required": [
    "tz"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":10,"method":"tools/call","params":{"name":"get_current_time","arguments":{"tz":"Europe/Paris"}}}

Resultado (structuredContent)

{
  "timeZone": "Europe/Paris",
  "local": "2026-12-01T14:46:27",
  "iso": "2026-12-01T14:46:27+01:00",
  "utcOffset": "+01:00",
  "utcOffsetMinutes": 60,
  "abbreviation": "CET",
  "isDst": false,
  "utc": "2026-12-01T13:46:27Z",
  "unixMs": 1796132787506,
  "nextTransition": {
    "at": "2027-03-28T01:00:00Z",
    "utcOffsetBefore": "+01:00",
    "utcOffsetAfter": "+02:00"
  },
  "source": "IANA tz database (runtime Intl)"
}

convert_timezone

Convertir una hora local entre zonas

Converts a wall-clock time from one IANA time zone to another. Says explicitly how a non-existent (daylight-saving gap) or repeated (overlap) time was resolved.

La misma operación por REST: GET /api/v1/time/convert · Nombre anterior, aún aceptado: convert_time

Esquema de entrada
{
  "type": "object",
  "properties": {
    "from": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "pattern": "^[A-Za-z0-9_+\\-/]+$",
      "description": "Source IANA time zone, e.g. America/New_York"
    },
    "to": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "pattern": "^[A-Za-z0-9_+\\-/]+$",
      "description": "Target IANA time zone, e.g. Asia/Tokyo"
    },
    "time": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}(:\\d{2})?$",
      "description": "Wall-clock time in the source zone, YYYY-MM-DDTHH:MM or YYYY-MM-DDTHH:MM:SS, without a UTC offset (1970–2100)"
    },
    "overlap": {
      "type": "string",
      "enum": [
        "earlier",
        "later"
      ],
      "default": "earlier",
      "description": "Which occurrence to use when the time happens twice. Default: earlier."
    }
  },
  "required": [
    "from",
    "to",
    "time"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":11,"method":"tools/call","params":{"name":"convert_timezone","arguments":{"from":"America/New_York","to":"Asia/Tokyo","time":"2026-12-25T09:00"}}}

Resultado (structuredContent)

{
  "input": {
    "from": "America/New_York",
    "to": "Asia/Tokyo",
    "time": "2026-12-25T09:00:00"
  },
  "from": {
    "timeZone": "America/New_York",
    "local": "2026-12-25T09:00:00",
    "iso": "2026-12-25T09:00:00-05:00",
    "utcOffset": "-05:00",
    "utcOffsetMinutes": -300,
    "abbreviation": "EST",
    "isDst": false
  },
  "to": {
    "timeZone": "Asia/Tokyo",
    "local": "2026-12-25T23:00:00",
    "iso": "2026-12-25T23:00:00+09:00",
    "utcOffset": "+09:00",
    "utcOffsetMinutes": 540,
    "abbreviation": "GMT+9",
    "isDst": false
  },
  "utc": "2026-12-25T14:00:00Z",
  "resolution": "exact",
  "note": "The source time exists exactly once in the source zone.",
  "source": "IANA tz database (runtime Intl)"
}

find_timezone

Buscar la zona horaria de una ciudad o un país por su nombre

Finds the IANA time zone of a city or country from its name (English, Arabic or local spelling) and returns the current local time there. Countries with several zones list each zone with its largest cities.

La misma operación por REST: GET /api/v1/time/find

Esquema de entrada
{
  "type": "object",
  "properties": {
    "q": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "description": "City or country name (any language the index knows, e.g. Cairo, القاهرة, Le Caire) or an ISO country code"
    },
    "limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 10,
      "description": "Maximum number of city matches (1–10). Default 5.",
      "default": 5
    }
  },
  "required": [
    "q"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":12,"method":"tools/call","params":{"name":"find_timezone","arguments":{"q":"Kathmandu","limit":2}}}

Resultado (structuredContent)

{
  "query": "Kathmandu",
  "at": "2026-12-01T13:46:27Z",
  "countries": [],
  "cities": [
    {
      "name": "Kathmandu",
      "nameAr": "كاتماندو",
      "alternateNames": ["كاتماندو", "काठमाडौं", "Katmandou", "Katmandú", "Катманду", "加德滿都"],
      "country": "NP",
      "countryName": "Nepal",
      "timeZone": "Asia/Kathmandu",
      "lat": 27.7,
      "lon": 85.32,
      "population": 1442271,
      "slug": "kathmandu",
      "url": "https://clockcrest.com/time/kathmandu/",
      "utcOffset": "+05:45",
      "local": "2026-12-01T19:31:27"
    }
  ],
  "notes": [
    "A country can span several time zones: each one is listed with its largest cities. City matches are ordered by relevance, then population.",
    "The index holds GeoNames populated places of 15,000+ people (about 34,000 cities). Smaller places are not in it.",
    // … 1 more
  ],
  "source": "GeoNames",
  "sourceUrl": "https://www.geonames.org",
  "license": "CC BY 4.0",
  "lastUpdated": "2026-11-30",
  "timeZoneSource": "IANA tz database (runtime Intl)"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

search_city

Buscar ciudades por nombre

Searches about 34,000 world cities by name (any case, accents optional, Arabic and local names understood) and returns each match's country, IANA time zone, coordinates and population. Use the coordinates and zone with get_sunrise_sunset or get_prayer_times.

La misma operación por REST: GET /api/v1/cities/search

Esquema de entrada
{
  "type": "object",
  "properties": {
    "q": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "description": "City name or the beginning of one, e.g. cairo, münchen, القاهرة"
    },
    "limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 25,
      "description": "Maximum number of results (1–25). Default 8.",
      "default": 8
    },
    "country": {
      "type": "string",
      "minLength": 2,
      "maxLength": 2,
      "pattern": "^[A-Za-z]{2}$",
      "description": "Only cities of this country (ISO 3166-1 alpha-2), e.g. EG"
    }
  },
  "required": [
    "q"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":13,"method":"tools/call","params":{"name":"search_city","arguments":{"q":"cairo","limit":3}}}

Resultado (structuredContent)

{
  "query": "cairo",
  "country": null,
  "count": 2,
  "results": [
    {
      "name": "Cairo",
      "nameAr": "القاهرة",
      "alternateNames": ["القاهرة", "Le Caire", "El Cairo", "Kairo", "Каир", "カイロ"],
      "country": "EG",
      "countryName": "Egypt",
      "timeZone": "Africa/Cairo",
      "lat": 30.06,
      "lon": 31.25,
      "population": 9606916,
      "slug": "cairo",
      "url": "https://clockcrest.com/time/cairo/"
    },
    // … 1 more
  ],
  "notes": [
    "The index holds GeoNames populated places of 15,000+ people (about 34,000 cities). Smaller places are not in it.",
    // … 1 more
  ],
  "source": "GeoNames",
  "sourceUrl": "https://www.geonames.org",
  "license": "CC BY 4.0",
  "lastUpdated": "2026-11-30"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

get_country_holidays

Días festivos de un país en un año

Public holidays of a country for one year (2025–2028), including regional ones flagged with their subdivisions. Source: Nager.Date.

La misma operación por REST: GET /api/v1/holidays · Nombre anterior, aún aceptado: get_public_holidays

Esquema de entrada
{
  "type": "object",
  "properties": {
    "country": {
      "type": "string",
      "minLength": 2,
      "maxLength": 2,
      "pattern": "^[A-Za-z]{2}$",
      "description": "ISO 3166-1 alpha-2 country code, e.g. FR"
    },
    "year": {
      "type": "integer",
      "minimum": 2025,
      "maximum": 2028,
      "description": "Four-digit year with data (2025–2028)"
    }
  },
  "required": [
    "country",
    "year"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":14,"method":"tools/call","params":{"name":"get_country_holidays","arguments":{"country":"FR","year":2026}}}

Resultado (structuredContent)

{
  "country": "FR",
  "countryName": "France",
  "year": 2026,
  "count": 11,
  "holidays": [
    {
      "date": "2026-01-01",
      "name": "New Year's Day",
      "localName": "Jour de l'an",
      "nationwide": true,
      "types": ["Public"]
    },
    // … 10 more
  ],
  "source": "Nager.Date",
  "sourceUrl": "https://date.nager.at",
  "dataYears": [2025, 2026, 2027, 2028],
  "lastUpdated": "2026-11-30"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

calculate_business_days

Contar los días hábiles entre dos fechas

Business days between two dates (both inclusive) in a country, excluding its weekend days and nationwide public holidays. Lists the holidays that were excluded. Holiday data covers 2025–2028.

La misma operación por REST: GET /api/v1/business-days · Nombre anterior, aún aceptado: count_business_days

Esquema de entrada
{
  "type": "object",
  "properties": {
    "country": {
      "type": "string",
      "minLength": 2,
      "maxLength": 2,
      "pattern": "^[A-Za-z]{2}$",
      "description": "ISO 3166-1 alpha-2 country code, e.g. FR"
    },
    "start": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "First day, YYYY-MM-DD"
    },
    "end": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Last day (inclusive), YYYY-MM-DD; at most 1500 days after start"
    }
  },
  "required": [
    "country",
    "start",
    "end"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":15,"method":"tools/call","params":{"name":"calculate_business_days","arguments":{"country":"FR","start":"2026-12-01","end":"2026-12-31"}}}

Resultado (structuredContent)

{
  "country": "FR",
  "countryName": "France",
  "start": "2026-12-01",
  "end": "2026-12-31",
  "endInclusive": true,
  "calendarDays": 31,
  "businessDays": 22,
  "weekend": ["Sunday", "Saturday"],
  "holidaysExcluded": [
    {
      "date": "2026-12-25",
      "name": "Christmas Day",
      "localName": "Noël"
    }
  ],
  "holidaysOnWeekend": [],
  "rules": "Weekend days and nationwide public holidays are excluded; regional holidays are not.",
  "source": "Nager.Date",
  "sourceUrl": "https://date.nager.at",
  "dataYears": [2025, 2026, 2027, 2028],
  "lastUpdated": "2026-11-30"
}

add_business_days

Sumar o restar días hábiles

Finds the date that is N business days after (or, with a negative N, before) a start date in a country, skipping its weekend days and nationwide public holidays. Holiday data covers 2025–2028; a calculation that leaves those years is refused rather than guessed.

La misma operación por REST: GET /api/v1/business-days/add

Esquema de entrada
{
  "type": "object",
  "properties": {
    "country": {
      "type": "string",
      "minLength": 2,
      "maxLength": 2,
      "pattern": "^[A-Za-z]{2}$",
      "description": "ISO 3166-1 alpha-2 country code, e.g. FR"
    },
    "start": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Start date, YYYY-MM-DD"
    },
    "days": {
      "type": "integer",
      "minimum": -1000,
      "maximum": 1000,
      "description": "Business days to add; negative to go back (−1000 to 1000)"
    }
  },
  "required": [
    "country",
    "start",
    "days"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":16,"method":"tools/call","params":{"name":"add_business_days","arguments":{"country":"EG","start":"2026-12-30","days":5}}}

Resultado (structuredContent)

{
  "country": "EG",
  "countryName": "Egypt",
  "start": "2026-12-30",
  "startWeekday": "Wednesday",
  "startIsBusinessDay": true,
  "days": 5,
  "result": "2027-01-06",
  "resultWeekday": "Wednesday",
  "calendarDays": 7,
  "weekend": ["Friday", "Saturday"],
  "holidaysSkipped": [],
  "rules": "Weekend days and nationwide public holidays are not business days; regional holidays are treated as business days. The start date itself is not counted: the result is the 5 business days after it.",
  "notes": ["The weekend used for EG is the one documented for that country."],
  "source": "Nager.Date",
  "sourceUrl": "https://date.nager.at",
  "lastUpdated": "2026-11-30",
  "dataYears": [2025, 2026, 2027, 2028]
}

get_calendar

Calendario de un mes con semanas ISO, fines de semana y festivos

A month as a grid of ISO weeks (Monday first) with ISO week numbers; with a country, its weekend days and public holidays are marked and the business days of the month are counted.

La misma operación por REST: GET /api/v1/calendar

Esquema de entrada
{
  "type": "object",
  "properties": {
    "year": {
      "type": "integer",
      "minimum": 1900,
      "maximum": 2100,
      "description": "Four-digit year (1900–2100; with a country, a year that has holiday data)"
    },
    "month": {
      "type": "integer",
      "minimum": 1,
      "maximum": 12,
      "description": "Month number, 1–12"
    },
    "country": {
      "type": "string",
      "minLength": 2,
      "maxLength": 2,
      "pattern": "^[A-Za-z]{2}$",
      "description": "Mark this country's weekend and public holidays (ISO 3166-1 alpha-2)"
    }
  },
  "required": [
    "year",
    "month"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":17,"method":"tools/call","params":{"name":"get_calendar","arguments":{"country":"FR","year":2026,"month":12}}}

Resultado (structuredContent)

{
  "year": 2026,
  "month": 12,
  "monthName": "December",
  "country": "FR",
  "countryName": "France",
  "weekStart": "Monday",
  "weekend": ["Sunday", "Saturday"],
  "daysInMonth": 31,
  "businessDays": 22,
  "weeks": [
    {
      "isoWeek": 49,
      "isoWeekYear": 2026,
      "days": [
        null,
        // … 6 more
      ]
    },
    // … 4 more
  ],
  "holidays": [
    {
      "date": "2026-12-25",
      "name": "Christmas Day",
      "localName": "Noël",
      "nationwide": true,
      "types": ["Public"]
    }
  ],
  "notes": [
    "Rows are ISO 8601 weeks (Monday to Sunday); null cells pad the first and last week. Week 1 is the week that contains the first Thursday of the year.",
    // … 2 more
  ],
  "source": "Nager.Date",
  "sourceUrl": "https://date.nager.at",
  "dataYears": [2025, 2026, 2027, 2028],
  "lastUpdated": "2026-11-30"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

convert_calendar

Convertir una fecha entre sistemas de calendario

Converts a date between the Gregorian, Hijri (Umm al-Qura), Persian (Solar Hijri) and Hebrew calendars. Hijri results are the calculated Umm al-Qura calendar: the day a religious month really begins depends on local moon sighting and can differ by a day or two.

La misma operación por REST: GET /api/v1/calendar/convert

Esquema de entrada
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Date in the source calendar as year-month-day with a four-digit year, e.g. 2026-12-01 or 1448-09-01"
    },
    "from": {
      "type": "string",
      "enum": [
        "gregorian",
        "islamic-umalqura",
        "persian",
        "hebrew"
      ],
      "description": "Source calendar"
    },
    "to": {
      "type": "string",
      "enum": [
        "gregorian",
        "islamic-umalqura",
        "persian",
        "hebrew"
      ],
      "description": "Target calendar"
    }
  },
  "required": [
    "date",
    "from",
    "to"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":18,"method":"tools/call","params":{"name":"convert_calendar","arguments":{"date":"2026-12-01","from":"gregorian","to":"islamic-umalqura"}}}

Resultado (structuredContent)

{
  "input": {
    "calendar": "gregorian",
    "year": 2026,
    "month": 12,
    "day": 1,
    "monthName": "December",
    "date": "2026-12-01"
  },
  "result": {
    "calendar": "islamic-umalqura",
    "year": 1448,
    "month": 6,
    "day": 21,
    "monthName": "Jumada II",
    "date": "1448-06-21"
  },
  "gregorian": "2026-12-01",
  "weekday": "Tuesday",
  "notes": [
    "Months are numbered by their position in the year. A Hebrew leap year has 13 months (Adar I = 6, Adar II = 7); month names are the English names from the runtime's CLDR data.",
    // … 3 more
  ],
  "supportedCalendars": ["gregorian", "islamic-umalqura", "persian", "hebrew"],
  "source": "ICU / CLDR calendars (runtime Intl)"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

calculate_date_difference

Diferencia entre dos fechas

Number of days between two calendar dates (end minus start), also as weeks + days and as years, months and days. Leap years are handled.

La misma operación por REST: GET /api/v1/date/difference

Esquema de entrada
{
  "type": "object",
  "properties": {
    "start": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "First date, YYYY-MM-DD"
    },
    "end": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Second date, YYYY-MM-DD"
    }
  },
  "required": [
    "start",
    "end"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":19,"method":"tools/call","params":{"name":"calculate_date_difference","arguments":{"start":"2024-02-29","end":"2026-12-01"}}}

Resultado (structuredContent)

{
  "start": "2024-02-29",
  "startWeekday": "Thursday",
  "end": "2026-12-01",
  "endWeekday": "Tuesday",
  "days": 1006,
  "negative": false,
  "weeks": {
    "weeks": 143,
    "days": 5
  },
  "calendar": {
    "years": 2,
    "months": 9,
    "days": 2
  },
  "notes": [
    "\"days\" is end minus start (the end date is not counted; negative when end is before start). \"weeks\" and \"calendar\" describe the absolute difference.",
    "\"calendar\" counts whole years and months first, then the remaining days; a month-end start is clamped (31 January + 1 month = 28 or 29 February)."
  ],
  "source": "Proleptic Gregorian calendar arithmetic"
}

add_duration

Sumar años, meses, semanas y días a una fecha

Adds or subtracts years, months, weeks and days to a calendar date and returns the resulting date with its weekday and ISO week. Give at least one unit. Month ends are clamped (31 January + 1 month = 28 or 29 February).

La misma operación por REST: GET /api/v1/date/add

Esquema de entrada
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Start date, YYYY-MM-DD"
    },
    "years": {
      "type": "integer",
      "minimum": -9999,
      "maximum": 9999,
      "description": "Years to add (may be negative)"
    },
    "months": {
      "type": "integer",
      "minimum": -120000,
      "maximum": 120000,
      "description": "Months to add (may be negative)"
    },
    "weeks": {
      "type": "integer",
      "minimum": -520000,
      "maximum": 520000,
      "description": "Weeks to add (may be negative)"
    },
    "days": {
      "type": "integer",
      "minimum": -3650000,
      "maximum": 3650000,
      "description": "Days to add (may be negative)"
    }
  },
  "required": [
    "date"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":20,"method":"tools/call","params":{"name":"add_duration","arguments":{"date":"2024-01-31","months":1}}}

Resultado (structuredContent)

{
  "date": "2024-01-31",
  "weekday": "Wednesday",
  "added": {
    "years": 0,
    "months": 1,
    "weeks": 0,
    "days": 0
  },
  "result": "2024-02-29",
  "resultWeekday": "Thursday",
  "resultIsoWeek": 9,
  "resultIsoWeekYear": 2024,
  "daysBetween": 29,
  "notes": [
    "Years and months are added first, clamping to the last day of the month when needed (31 January + 1 month = 28 or 29 February); weeks and days are added afterwards."
  ],
  "source": "Proleptic Gregorian calendar arithmetic"
}

get_sunrise_sunset

Salida y puesta del sol, mediodía solar y crepúsculos

Sunrise, sunset, solar noon, day length and twilight times for coordinates on a date, in the given time zone. Reports polar day or polar night explicitly instead of inventing times. Use search_city to get coordinates and the zone of a city.

La misma operación por REST: GET /api/v1/astronomy/sun

Esquema de entrada
{
  "type": "object",
  "properties": {
    "lat": {
      "type": "number",
      "minimum": -90,
      "maximum": 90,
      "description": "Latitude in decimal degrees, north positive (−90 to 90)"
    },
    "lon": {
      "type": "number",
      "minimum": -180,
      "maximum": 180,
      "description": "Longitude in decimal degrees, east positive (−180 to 180)"
    },
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Local date at the place, YYYY-MM-DD (1900–2100)"
    },
    "tz": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "pattern": "^[A-Za-z0-9_+\\-/]+$",
      "description": "IANA time zone of the place, e.g. Africa/Cairo"
    }
  },
  "required": [
    "lat",
    "lon",
    "date",
    "tz"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":21,"method":"tools/call","params":{"name":"get_sunrise_sunset","arguments":{"lat":30.06,"lon":31.25,"date":"2026-12-01","tz":"Africa/Cairo"}}}

Resultado (structuredContent)

{
  "date": "2026-12-01",
  "lat": 30.06,
  "lon": 31.25,
  "timeZone": "Africa/Cairo",
  "sunrise": {
    "utc": "2026-12-01T04:33:21Z",
    "local": "2026-12-01T06:33:21+02:00"
  },
  "sunset": {
    "utc": "2026-12-01T14:54:38Z",
    "local": "2026-12-01T16:54:38+02:00"
  },
  "solarNoon": {
    "utc": "2026-12-01T09:43:59Z",
    "local": "2026-12-01T11:43:59+02:00"
  },
  "dayLengthSeconds": 37277,
  "dayLength": "10:21:17",
  "polar": null,
  "polarNote": null,
  "twilight": {
    "civil": {
      "dawn": {
        "utc": "2026-12-01T04:07:21Z",
        "local": "2026-12-01T06:07:21+02:00"
      },
      "dusk": {
        "utc": "2026-12-01T15:20:38Z",
        "local": "2026-12-01T17:20:38+02:00"
      }
    },
    "nautical": {
      "dawn": {
        "utc": "2026-12-01T03:37:49Z",
        "local": "2026-12-01T05:37:49+02:00"
      },
      "dusk": {
        "utc": "2026-12-01T15:50:10Z",
        "local": "2026-12-01T17:50:10+02:00"
      }
    },
    "astronomical": {
      "dawn": {
        "utc": "2026-12-01T03:08:50Z",
        "local": "2026-12-01T05:08:50+02:00"
      },
      "dusk": {
        "utc": "2026-12-01T16:19:09Z",
        "local": "2026-12-01T18:19:09+02:00"
      }
    }
  },
  "notes": [
    "Sunrise and sunset are the moments the Sun's upper limb is on a sea-level horizon with standard refraction (centre 0.833° below it). Typical accuracy is 1–2 minutes below 72° latitude; terrain, elevation and unusual refraction are not modelled.",
    // … 2 more
  ],
  "source": "NOAA solar position algorithm (Jean Meeus, Astronomical Algorithms)",
  "sourceUrl": "https://gml.noaa.gov/grad/solcalc/calcdetails.html"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

get_moon_phase

Fase de la Luna, iluminación y próximas fases

Phase of the Moon (name, illuminated fraction, age in days) now or on a date, plus the times of the next new moon, first quarter, full moon and last quarter in UTC.

La misma operación por REST: GET /api/v1/astronomy/moon

Esquema de entrada
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Date, YYYY-MM-DD, evaluated at 12:00 UTC (1900–2100). Default: now."
    }
  },
  "required": [],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":22,"method":"tools/call","params":{"name":"get_moon_phase","arguments":{"date":"2026-12-01"}}}

Resultado (structuredContent)

{
  "date": "2026-12-01",
  "at": "2026-12-01T12:00:00Z",
  "phase": "last-quarter",
  "phaseName": "Last Quarter",
  "illumination": 0.4747,
  "illuminationPercent": 47.5,
  "ageDays": 22.21,
  "cycleAngle": 272.8,
  "waxing": false,
  "nextNewMoon": "2026-12-09T00:51:46Z",
  "nextFirstQuarter": "2026-12-17T05:42:35Z",
  "nextFullMoon": "2026-12-24T01:28:08Z",
  "nextLastQuarter": "2026-12-30T18:59:29Z",
  "notes": [
    "A date without a time is evaluated at 12:00:00 UTC.",
    "The phase is geocentric: it is the same everywhere on Earth at a given instant. Principal phases (new, quarters, full) are reported for about half a day either side of their exact moment.",
    // … 1 more
  ],
  "source": "Jean Meeus, Astronomical Algorithms (2nd ed.), chapters 48–49"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

get_prayer_times

Horarios de oración islámica

Calculated Islamic prayer times (Fajr, sunrise, Dhuhr, Asr, Maghrib, Isha) for coordinates on a date, with the method parameters used. These are calculations: local mosques and authorities may differ by a few minutes, so point users to their local timetable. Use search_city to get coordinates and the zone of a city.

La misma operación por REST: GET /api/v1/prayer-times

Esquema de entrada
{
  "type": "object",
  "properties": {
    "lat": {
      "type": "number",
      "minimum": -90,
      "maximum": 90,
      "description": "Latitude in decimal degrees, north positive (−90 to 90)"
    },
    "lon": {
      "type": "number",
      "minimum": -180,
      "maximum": 180,
      "description": "Longitude in decimal degrees, east positive (−180 to 180)"
    },
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Local date at the place, YYYY-MM-DD (1900–2100)"
    },
    "tz": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "pattern": "^[A-Za-z0-9_+\\-/]+$",
      "description": "IANA time zone of the place, e.g. Africa/Cairo"
    },
    "method": {
      "type": "string",
      "enum": [
        "mwl",
        "umm-al-qura",
        "egyptian",
        "karachi",
        "isna"
      ],
      "default": "mwl",
      "description": "Calculation method: mwl (Muslim World League), umm-al-qura, egyptian, karachi or isna. Default mwl."
    },
    "asr": {
      "type": "string",
      "enum": [
        "standard",
        "hanafi"
      ],
      "default": "standard",
      "description": "Asr rule: standard (Shafi'i, Maliki, Hanbali) or hanafi. Default standard."
    }
  },
  "required": [
    "lat",
    "lon",
    "date",
    "tz"
  ],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":23,"method":"tools/call","params":{"name":"get_prayer_times","arguments":{"lat":30.06,"lon":31.25,"date":"2026-12-01","tz":"Africa/Cairo","method":"egyptian"}}}

Resultado (structuredContent)

{
  "date": "2026-12-01",
  "lat": 30.06,
  "lon": 31.25,
  "timeZone": "Africa/Cairo",
  "times": {
    "fajr": {
      "utc": "2026-12-01T03:01:40Z",
      "local": "2026-12-01T05:01:40+02:00"
    },
    "sunrise": {
      "utc": "2026-12-01T04:33:21Z",
      "local": "2026-12-01T06:33:21+02:00"
    },
    "dhuhr": {
      "utc": "2026-12-01T09:43:59Z",
      "local": "2026-12-01T11:43:59+02:00"
    },
    "asr": {
      "utc": "2026-12-01T12:35:32Z",
      "local": "2026-12-01T14:35:32+02:00"
    },
    "maghrib": {
      "utc": "2026-12-01T14:54:38Z",
      "local": "2026-12-01T16:54:38+02:00"
    },
    "isha": {
      "utc": "2026-12-01T16:16:45Z",
      "local": "2026-12-01T18:16:45+02:00"
    }
  },
  "method": {
    "id": "egyptian",
    "name": "Egyptian General Authority of Survey",
    "fajrAngle": 19.5,
    "ishaAngle": 17.5,
    "ishaMinutesAfterMaghrib": null,
    "ramadan": null
  },
  "asr": {
    "school": "standard",
    "shadowFactor": 1
  },
  "highLatitudeApproximation": false,
  "polar": false,
  "notes": [
    "Calculated times. Mosques and local religious authorities may publish times that differ by a few minutes (rounding, safety margins, a different method or local practice); follow the local timetable where one exists.",
    // … 3 more
  ],
  "methods": ["mwl", "umm-al-qura", "egyptian", "karachi", "isna"],
  "source": "Solar position: NOAA algorithm (Jean Meeus); angles: the published parameters of each method"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

get_weather

Previsión del tiempo para un lugar (MET Norway)

Weather forecast from MET Norway for coordinates or a city: current temperature, symbol, wind, humidity and next-hour precipitation, 24 hourly steps and 7 daily summaries (low, high, precipitation). Values are SI (°C, m/s, mm). This tool calls MET Norway's public API (cached); credit "Weather data from MET Norway" when you show the data.

La misma operación por REST: GET /api/v1/weather

Esquema de entrada
{
  "type": "object",
  "properties": {
    "lat": {
      "type": "number",
      "minimum": -90,
      "maximum": 90,
      "description": "Latitude in decimal degrees, north positive (−90 to 90). Use with lon, instead of city."
    },
    "lon": {
      "type": "number",
      "minimum": -180,
      "maximum": 180,
      "description": "Longitude in decimal degrees, east positive (−180 to 180). Use with lat, instead of city."
    },
    "city": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "description": "City instead of coordinates: a city slug of clockcrest.com (e.g. new-york) or a name looked up in the city index (e.g. Oslo, القاهرة)"
    },
    "tz": {
      "type": "string",
      "minLength": 1,
      "maxLength": 64,
      "pattern": "^[A-Za-z0-9_+\\-/]+$",
      "description": "IANA time zone for local times and daily grouping. Default: the city's zone, or UTC with coordinates."
    }
  },
  "required": [],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":24,"method":"tools/call","params":{"name":"get_weather","arguments":{"lat":59.91,"lon":10.75,"tz":"Europe/Oslo"}}}

Resultado (structuredContent)

{
  "location": {
    "lat": 59.9,
    "lon": 10.8,
    "elevation": 138,
    "name": null,
    "country": null,
    "timeZone": "Europe/Oslo"
  },
  "updated": "2026-12-01T12:35:33Z",
  "expires": "2026-12-01T13:53:01Z",
  "current": {
    "time": "2026-12-01T13:00:00Z",
    "local": "2026-12-01T14:00:00+01:00",
    "temperature": 7.7,
    "symbol": "lightrain",
    "windSpeed": 5.8,
    "windDirection": 188,
    "humidity": 99.9,
    "cloudCover": 100,
    "pressure": 1014,
    "precipitationNextHour": 0.1
  },
  "hourly": [
    {
      "time": "2026-12-01T13:00:00Z",
      "local": "2026-12-01T14:00:00+01:00",
      "temperature": 7.7,
      "symbol": "lightrain",
      "windSpeed": 5.8,
      "windDirection": 188,
      "precipitation": 0.1,
      "humidity": 99.9
    },
    // … 23 more
  ],
  "daily": [
    {
      "date": "2026-12-01",
      "min": 6.7,
      "max": 7.7,
      "symbol": "lightrain",
      "precipitation": 1.1
    },
    // … 6 more
  ],
  "units": {
    "temperature": "celsius",
    "windSpeed": "m/s",
    "windDirection": "degrees",
    "precipitation": "mm",
    "humidity": "%",
    "cloudCover": "%",
    "pressure": "hPa"
  },
  "notes": [
    "Forecast for the coordinates snapped to a 0.1° grid (about 11 km); \"location\" gives the point used. \"current\" is the forecast step for the present hour, not a station observation.",
    // … 3 more
  ],
  "source": "MET Norway Locationforecast 2.0",
  "sourceUrl": "https://api.met.no/weatherapi/locationforecast/2.0/documentation",
  "attribution": "Weather data from MET Norway",
  "license": "CC BY 4.0",
  "licenseUrl": "https://creativecommons.org/licenses/by/4.0/"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

get_market_hours

Horario habitual de las bolsas y su estado

Regular trading hours of major stock exchanges and whether each is open right now according to its weekly timetable, with the next open and close in UTC. Exchange holidays and early closes are NOT modelled — tell the user to check the exchange calendar (sourceUrl) for those.

La misma operación por REST: GET /api/v1/markets/hours

Esquema de entrada
{
  "type": "object",
  "properties": {
    "exchange": {
      "type": "string",
      "enum": [
        "nyse",
        "nasdaq",
        "tsx",
        "lse",
        "euronext-paris",
        "xetra",
        "six",
        "bist",
        "tadawul",
        "dfm",
        "adx",
        "egx",
        "jse",
        "nse",
        "bse",
        "sgx",
        "hkex",
        "sse",
        "szse",
        "tse",
        "krx",
        "asx",
        "nzx"
      ],
      "description": "Only this exchange: nyse, nasdaq, tsx, lse, euronext-paris, xetra, six, bist, tadawul, dfm, adx, egx, jse, nse, bse, sgx, hkex, sse, szse, tse, krx, asx, nzx"
    }
  },
  "required": [],
  "additionalProperties": false
}
Ejemplo de llamada y resultado

Petición

{"jsonrpc":"2.0","id":25,"method":"tools/call","params":{"name":"get_market_hours","arguments":{"exchange":"nyse"}}}

Resultado (structuredContent)

{
  "at": "2026-12-01T13:46:27Z",
  "exchange": "nyse",
  "count": 1,
  "exchanges": [
    {
      "id": "nyse",
      "name": "NYSE",
      "fullName": "New York Stock Exchange",
      "city": "New York",
      "country": "US",
      "region": "americas",
      "timeZone": "America/New_York",
      "tradingDays": ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"],
      "open": "09:30",
      "close": "16:00",
      "lunchBreak": null,
      "closingAuction": null,
      "sourceUrl": "https://www.nyse.com/markets/hours-calendars",
      "status": {
        "state": "closed",
        "isOpen": false,
        "localTime": "2026-12-01T08:46:27-05:00",
        "nextEvent": {
          "kind": "open",
          "at": "2026-12-01T14:30:00Z",
          "local": "2026-12-01T09:30:00-05:00"
        },
        "nextOpen": "2026-12-01T14:30:00Z",
        "nextClose": "2026-12-01T21:00:00Z"
      }
    }
  ],
  "notes": [
    "Exchange holidays, early closes and unscheduled halts are NOT modelled: \"status\" is what the regular weekly timetable says. Check the exchange's own calendar (\"sourceUrl\") before relying on it.",
    // … 2 more
  ],
  "source": "Each exchange's published trading hours (see \"sourceUrl\" per exchange)",
  "lastUpdated": "2026-11-30"
}

Abreviado: las listas largas muestran su primer elemento y una línea «// … N more».

Límites

  • Cuerpos de petición de hasta 16 KB (16 384 bytes); los mayores reciben un HTTP 413.
  • Un solo mensaje JSON-RPC por POST: los lotes se rechazan.
  • Solo POST. GET responde 405, porque no hay ningún flujo del servidor al cliente que abrir.
  • Solo herramientas: el servidor no ofrece recursos, prompts ni sampling.
  • Los argumentos que una herramienta no declara se rechazan (su esquema de entrada es cerrado).
  • Sin límite de peticiones por cliente, y con las mismas condiciones de uso razonable que la API JSON: no llames a una herramienta en bucle para datos que no han cambiado.

Con qué se ha probado

Esta lista solo incluye lo que se ejecutó de verdad contra el código del servidor:

  • JSON-RPC sin más con curl: initialize, la notificación initialized, tools/list y tools/call en 2025-11-25, y un tools/call en 2026-07-28 con sus cabeceras.
  • fetch de Node.js: el script que capturó todos los ejemplos de esta página llama una vez a cada una de las 16 herramientas.
  • El cliente HTTP de Playwright en las pruebas de extremo a extremo, contra las funciones reales: los dos estilos del protocolo, las rutas de error, el límite de tamaño y la petición previa de CORS.
  • Pruebas unitarias que llaman directamente al gestor de peticiones para cada herramienta y comparan cada resultado con su esquema de salida.
  • Probado con el cliente TypeScript oficial de MCP (@modelcontextprotocol/sdk 1.32.2, transporte Streamable HTTP): initialize, ping, tools/list y tools/call para las 16 herramientas con argumentos válidos e inválidos; el SDK validó cada structuredContent con su esquema de salida.
  • Probado con MCP Inspector oficial en línea de comandos (@modelcontextprotocol/inspector 2.13.0): tools/list y tools/call, incluidos los errores de herramienta y una herramienta desconocida.

No se ha probado con ningún cliente de IA ni IDE concreto. Las instrucciones de conexión anteriores siguen la especificación de MCP y la configuración documentada de los clientes, pero no las hemos verificado dentro de esos productos.

El uso razonable, las fuentes de los datos y sus límites son los mismos que en la API: consulta el resumen para desarrolladores.