Skip to content
REST APINo API keyCORSJSON · PNG · HTML

MCAPI.TR Developer Platform

API Documentation

The complete MCAPI.TR developer guide for querying Minecraft Java, Legacy and Bedrock servers and using icons, banners, widgets, trends and platform statistics.

Base URLhttps://mcapi.tr/api/v1
Contents

01 — Quick start

Get your first response in seconds

No setup or keys. Pick a client, copy the example and run it.

curl
curl "https://mcapi.tr/api/v1/status/mc.hypixel.net"

02 — API Playground

Send a live request from your browser

The request goes directly to the MCAPI.TR API and the formatted response appears below.

03 — Endpoint Reference

All public endpoints

Open a card for parameters, caching behavior and runnable examples.

GET/api/v1/servers

Saved servers

Lists previously discovered servers using their latest snapshot. Fresh offline servers are excluded. A snapshot older than 24 hours or a missing snapshot produces status stale and online null. last_snapshot_online preserves the last observation. No live probe is performed. Results are ordered by server ID.

application/json
Authentication
No API key required
Cache
No application cache
Content-Type
application/json
Requests / minute / IP
60

Parameters

ParameterLocationTypeDefaultDescription
limitqueryinteger (1–100)501–100 servers per page, default 50.
pagequeryinteger (1–2147483647)1Page number, default 1. With limit=100, pages 1–10 can return 1,000 records. Continue with meta.nextPage; null means the last page. Do not combine page and cursor.
cursorqueryopaque string—meta.nextCursor from the previous response. Continue until meta.hasNext is false to retrieve every page.
editionqueryjava | bedrock—java or bedrock. Excludes entries whose edition has not been confirmed.
statusqueryonline | stale | offline—online, stale or offline. The default includes online and stale.
min_playersqueryinteger—Minimum player count on the latest snapshot.
max_snapshot_agequeryinteger—Maximum age of the latest snapshot in seconds (1–2592000).
sortqueryid | players | recent—id ascending; players and recent descending with UUID ascending on ties. Use a filtered cursor with the same filters within 24 hours.

Example request

bash
curl "https://mcapi.tr/api/v1/servers?limit=100&page=2"
curl "https://mcapi.tr/api/v1/servers?edition=java&status=online&min_players=10&max_snapshot_age=3600&sort=players"

Example response

json
{
  "success": true,
  "data": [
    {
      "server_id": "00000000-0000-4000-8000-000000000001",
      "hostname": "play.example.net",
      "address": "play.example.net:25565",
      "port": 25565,
      "status": "online",
      "online": true,
      "stale": false,
      "last_snapshot_online": true,
      "checked_at": "2026-11-05T12:00:00.000Z",
      "players_online": 20,
      "players_max": 100,
      "version": "1.21.11",
      "protocol": 774,
      "ping": 35
    }
  ],
  "meta": {
    "limit": 50,
    "page": 1,
    "nextPage": null,
    "hasNext": false,
    "nextCursor": null
  }
}

HTTP 429 · 503

POST/api/v1/status/bulk

Bulk server status

Checks up to 50 servers per request with at most 10 different targets in flight. Results retain input order and include the single-status response and status_code. Offline results use item code 404 and internal failures 500; a valid batch returns HTTP 200. Limited to 6 requests per minute per IP.

application/json
Authentication
No API key required
Cache
Same cache as single-server status
Content-Type
application/json
Requests / minute / IP
6

Parameters

ParameterLocationTypeDefaultDescription
servers*bodyobject[] (1–50)—1–50 server objects in the JSON body. An invalid item rejects the entire request with 400. Repeated identical targets reuse their result.
servers[].address*bodystring—Hostname or IP; an optional port may be appended: play.example.net:25565
servers[].legacy / bedrockbodybooleanfalseBoth false for Java. Set bedrock true for Bedrock or legacy true for older Java. They cannot both be true. Use JSON booleans.

Example request

bash
curl -X POST "https://mcapi.tr/api/v1/status/bulk" -H "Content-Type: application/json" -d '{"servers":[{"address":"mc.hypixel.net"},{"address":"play.example.net:19132","bedrock":true}]}'

Example response

json
{
  "success": true,
  "data": [
    {
      "address": "mc.hypixel.net",
      "status_code": 200,
      "data": {
        "online": true,
        "stale": false,
        "players": {
          "online": 52184,
          "max": 200000
        }
      }
    },
    {
      "address": "play.example.net:19132",
      "status_code": 404,
      "data": {
        "online": false,
        "stale": false,
        "error": "Failed to connect"
      }
    }
  ],
  "meta": {
    "count": 2
  }
}

HTTP 429 · 503

GET/api/v1/status

API health check

Verifies service availability, version and server time. A lightweight endpoint for uptime monitors.

application/json
Authentication
No API key required
Cache
None
Content-Type
application/json
Requests / minute / IP
300 (default)

Example request

bash
curl "https://mcapi.tr/api/v1/status"

Example response

json
{
  "status": "OK",
  "timestamp": "2026-09-08T20:12:00.000Z",
  "service": "mcapi.tr-engine",
  "version": "0.1.0"
}

HTTP 429 · 503

GET/api/v1/status/:address

Minecraft server status

Returns Java, Legacy Java or Bedrock availability with player, version, MOTD, favicon and latency data.

application/json
Authentication
No API key required
Cache
60 seconds by default
Content-Type
application/json
Requests / minute / IP
120

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Hostname or IP; an optional port may be appended: play.example.net:25565
legacyquerybooleanfalseForces the pre-1.7.2 Java ping protocol.
bedrockquerybooleanfalseUses the Bedrock Edition query; the default port becomes 19132.
editionqueryjava | bedrock | legacy | auto—Select an edition. auto tries both protocols. Do not combine with legacy or bedrock set to true.
fieldsquerystring—Comma separated. Status and freshness fields are always included.
queryqueryboolean—true runs Java UDP Query: adds software, plugins and query_data (map, game type, version, player list) when the server enables Query. Fields are omitted when unavailable.
queryPortqueryinteger (1–65535)—UDP port for Query when it differs from the game port. Requires query=true.

Example request

bash
curl "https://mcapi.tr/api/v1/status/mc.hypixel.net"
curl "https://mcapi.tr/api/v1/status/mc.hypixel.net?edition=auto&fields=online,players,version"
curl "https://mcapi.tr/api/v1/status/%5B2606:4700::1001%5D:25565?edition=java"
curl "https://mcapi.tr/api/v1/status/mc.hypixel.net?query=true"
curl "https://mcapi.tr/api/v1/status/play.example.net?query=true&queryPort=25575"

Example response

json
{
  "query": {
    "host": "mc.hypixel.net",
    "port": 25565,
    "legacy": false,
    "bedrock": false,
    "edition": "java"
  },
  "server_id": "f17d4f75-...",
  "ip_address": "209.222.115.11",
  "icmp": true,
  "online": true,
  "stale": false,
  "error": null,
  "reason_code": null,
  "checked_at": "2026-09-12T15:59:36.430Z",
  "observed_at": "2026-09-12T15:59:36.430Z",
  "last_attempt_at": "2026-09-12T15:59:36.430Z",
  "cache_expires_at": "2026-09-12T16:00:36.430Z",
  "version": { "name": "Requires MC 1.8 / 1.21", "protocol": 47 },
  "players": { "online": 52184, "max": 200000, "sample": [] },
  "motd": {
    "raw": "§aHypixel Network",
    "clean": "Hypixel Network",
    "html": "<span style=\"color:#55FF55\">Hypixel Network</span>",
    "raw_lines": ["§aHypixel Network"],
    "clean_lines": ["Hypixel Network"]
  },
  "favicon": "data:image/png;base64,...",
  "srvRecord": null,
  "roundTripLatency": 18
}

HTTP 404 · 429 · 503 — Avoid repeatedly retrying a 404 while the server is unavailable.

json
{
  "fresh": {
    "online": true,
    "stale": false,
    "reason_code": null,
    "observed_at": "2026-11-08T12:00:00.000Z",
    "last_attempt_at": "2026-11-08T12:00:00.000Z",
    "cache_expires_at": "2026-11-08T12:01:00.000Z",
    "players": {
      "online": 24,
      "max": 100
    }
  },
  "stale": {
    "online": true,
    "stale": true,
    "reason_code": "TIMEOUT",
    "observed_at": "2026-11-08T12:00:00.000Z",
    "last_attempt_at": "2026-11-08T12:05:00.000Z",
    "cache_expires_at": "2026-11-08T12:05:15.000Z",
    "players": {
      "online": 24,
      "max": 100
    }
  },
  "dns": {
    "error": "DNS_LOOKUP_FAILED",
    "online": false,
    "stale": false,
    "reason_code": "DNS_NO_RECORD",
    "observed_at": null,
    "last_attempt_at": "2026-11-08T12:00:00.000Z",
    "cache_expires_at": "2026-11-08T12:00:15.000Z"
  },
  "deadline": {
    "error": "Server status lookup timed out.",
    "reason_code": "LOOKUP_DEADLINE"
  },
  "limit": {
    "status": "error",
    "error": "Rate limit exceeded, retry in 1 minute"
  },
  "unavailable": {
    "error": "This service is temporarily unavailable. Please retry."
  }
}
GET/api/v1/badge/:address

SVG status badge

Shows online, offline, or stale status. Provide your own alt text when embedding it as an image.

image/svg+xml
Authentication
No API key required
Cache
Cache-Control / ETag
Content-Type
image/svg+xml
Requests / minute / IP
120

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Hostname or IP; an optional port may be appended: play.example.net:25565
editionqueryjava | bedrock | legacy | auto—Select an edition. auto tries both protocols. Do not combine with legacy or bedrock set to true.

Example request

bash
<img src="https://mcapi.tr/api/v1/badge/mc.hypixel.net" alt="Current Hypixel status and player count">

HTTP 429 · 503

GET/api/v1/simple/:address

Simple status (HTTP code)

Answers 200 with "online" or 404 with "offline" as plain text, for uptime monitors that only read the status code. A stale result (the last successful answer while an outage is not yet confirmed) counts as online; the X-MCAPI-State header says online, stale or offline. HEAD requests are supported.

text/plain
Authentication
No API key required
Cache
Cache-Control (up to 60 seconds)
Content-Type
text/plain
Requests / minute / IP
120

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Hostname or IP; an optional port may be appended: play.example.net:25565
editionqueryjava | bedrock | legacy | auto—Select an edition. auto tries both protocols. Do not combine with legacy or bedrock set to true.

Example request

bash
curl -i "https://mcapi.tr/api/v1/simple/mc.hypixel.net"
curl -I "https://mcapi.tr/api/v1/simple/play.example.net:19132?edition=bedrock"

Example response

json
HTTP/1.1 200 OK
Content-Type: text/plain; charset=utf-8
X-MCAPI-State: online

online

HTTP 404 · 429 · 503 — Avoid repeatedly retrying a 404 while the server is unavailable.

GET/api/v1/text/:address/:field

Single field as text

Returns one value as plain text, for overlays, signs, bots and shell scripts. Offline servers answer 404 "offline", except the online field, which answers 200 "false". A value the server did not report answers 404 "unavailable".

text/plain
Authentication
No API key required
Cache
Cache-Control (up to 60 seconds)
Content-Type
text/plain
Requests / minute / IP
120

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Hostname or IP; an optional port may be appended: play.example.net:25565
field*pathonline | players | max_players | version | protocol | motd | ping—Value to return: online, players, max_players, version, protocol, motd (without colour codes, may span lines) or ping (ms).
editionqueryjava | bedrock | legacy | auto—Select an edition. auto tries both protocols. Do not combine with legacy or bedrock set to true.

Example request

bash
curl "https://mcapi.tr/api/v1/text/mc.hypixel.net/players"
curl "https://mcapi.tr/api/v1/text/mc.hypixel.net/version"

Example response

json
52184

HTTP 404 · 429 · 503 — Avoid repeatedly retrying a 404 while the server is unavailable.

GET/api/v1/service-status

Service measurements

Health, Java, Bedrock, and media measurements, coverage, and incidents for the last 7 days.

application/json
Authentication
No API key required
Cache
30 seconds
Content-Type
application/json
Requests / minute / IP
60

Example request

bash
curl "https://mcapi.tr/api/v1/service-status"

HTTP 429 · 503

GET/api/v1/history/:address

Server history

Returns saved observations and their coverage.

application/json
Authentication
No API key required
Cache
60 seconds
Content-Type
application/json
Requests / minute / IP
30

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Hostname or IP; an optional port may be appended: play.example.net:25565
periodquery24h | 7d | 30d—History window.
bedrockqueryboolean—Uses the Bedrock Edition query; the default port becomes 19132.

Example request

bash
curl "https://mcapi.tr/api/v1/history/mc.hypixel.net?period=7d"

HTTP 404 · 429 · 503 — Avoid repeatedly retrying a 404 while the server is unavailable.

GET/api/v1/diagnostics/:address

Connection diagnostics

Shows separate DNS, SRV, transport, and Minecraft protocol steps.

application/json
Authentication
No API key required
Cache
60 seconds
Content-Type
application/json
Requests / minute / IP
6

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Hostname or IP; an optional port may be appended: play.example.net:25565
editionqueryjava | bedrock | legacy—Select an edition. auto tries both protocols. Do not combine with legacy or bedrock set to true.

Example request

bash
curl "https://mcapi.tr/api/v1/diagnostics/mc.hypixel.net?edition=java"

HTTP 429 · 503

GET/api/v1/stats

Global platform statistics

Provides totals for requests, checked servers, online rate, active players and recent checks.

application/json
Authentication
No API key required
Cache
60 seconds
Content-Type
application/json
Requests / minute / IP
300 (default)

Example request

bash
curl "https://mcapi.tr/api/v1/stats"

Example response

json
{
  "totalRequests": 1284502,
  "apiRequests": 612340,
  "serverQueries": 672162,
  "totalChecks": 672162,
  "onlineServers": 428,
  "offlineServers": 91,
  "activePlayers": 184205,
  "recentChecks": [],
  "onlineRate": 82.5
}

HTTP 429 · 503

GET/api/v1/icon/dynamic

Server icon

Returns a server favicon and falls back to the MCAPI.TR default image when unavailable.

image/png | image/webp
Authentication
No API key required
Cache
Browser 1 hour, CDN 1 day
Content-Type
image/png | image/webp
Requests / minute / IP
5,000

Parameters

ParameterLocationTypeDefaultDescription
address*querystring—Server address. server is accepted as a backwards-compatible alias.
sizequeryinteger80WebP output size, between 16 and 256 pixels.
formatquerypng | webppngProduces an optimized square image when set to webp.

Example request

bash
curl "https://mcapi.tr/api/v1/icon/dynamic?address=mc.hypixel.net&size=128&format=webp" --output server.webp

HTTP 429 · 503

GET/api/v1/icon/sharp

Rounded server icon

Produces a resized PNG server icon with rounded corners.

image/png
Authentication
No API key required
Cache
Browser 1 hour, CDN 1 day
Content-Type
image/png
Requests / minute / IP
5,000

Parameters

ParameterLocationTypeDefaultDescription
address*querystring—Server hostname or IP address.
sizequeryinteger128Output size between 32 and 512 pixels.

Example request

bash
curl "https://mcapi.tr/api/v1/icon/sharp?address=mc.hypixel.net&size=256" --output icon.png

HTTP 429 · 503

GET/api/v1/banner/:address

Server status banner

Builds a shareable PNG banner with server name, players, MOTD, ping and favicon.

image/png
Authentication
No API key required
Cache
30 seconds
Content-Type
image/png
Requests / minute / IP
5,000

Parameters

ParameterLocationTypeDefaultDescription
address*pathstring—Server used to generate the banner.
sizequerysmall | normal | largenormalOutput dimensions: 400×130, 600×180 or 800×240.
stylequerymodern | classic | panoramamodernBanner appearance.
textColorqueryhex color#FFFFFFPrimary text color.
accentColorqueryhex color#10B981Player-count accent color.
showFavicon / showMotd / showPingquerybooleantrueToggles icon, MOTD and latency fields independently.
borderRadiusquerynumber0.5Corner-radius multiplier.
transparentquerybooleanfalseLeaves out the template background, border and decorations; text, icon, status and accent stay. On light pages, pair it with a dark textColor.
langqueryen | tr | de | esenLanguage of the labels drawn into the template banner (status, players, latency) and of its number format.

Example request

bash
curl "https://mcapi.tr/api/v1/banner/mc.hypixel.net?size=large&accentColor=%2310B981" --output banner.png

HTTP 429 · 503

GET/api/v1/banner/motd

MOTD text banner

Converts Minecraft-formatted MOTD text into an 800×180 PNG without querying a server.

image/png
Authentication
No API key required
Cache
No application cache
Content-Type
image/png
Requests / minute / IP
5,000

Parameters

ParameterLocationTypeDefaultDescription
motd*querystring—MOTD text up to 300 characters.
textColorqueryhex color#FFFFFFDefault text color.
accentColorqueryhex color#10B981Background accent color.

Example request

bash
curl "https://mcapi.tr/api/v1/banner/motd?motd=%C2%A7aWelcome" --output motd.png

HTTP 429 · 503

GET/api/v1/widget/:size/:address

Embeddable HTML widget

Returns customizable live server-status HTML for websites and dashboards.

text/html
Authentication
No API key required
Cache
60 seconds + stale-while-revalidate
Content-Type
text/html
Requests / minute / IP
5,000

Parameters

ParameterLocationTypeDefaultDescription
size*pathsmall | normal | large—Widget layout and default height.
address*pathstring—Server address; demo may be used for previewing.
themequerydark | lightdarkBase color theme.
showPlayers / showVersion / showMotdquerybooleantrueToggles the main information fields independently.
showLatency / showFaviconquerybooleantrueControls ping and favicon visibility.
showProtocol / showBorderquerybooleanfalseOptionally displays protocol and border.
bgColor / textColorqueryhex color—Widget background and text colors.
onlineColor / offlineColorqueryhex color#10b981 / #ef4444Online and offline state colors.
gradientBg / gradientFrom / gradientToqueryboolean / hexfalseGradient background controls.
statusIndicatorquerydot | text | badge | nonedotStatus indicator style.
iconSizequerysmall | medium | largemediumFavicon size.
fontquerysystem | sans | mono | Inter | Roboto | Montserrat | Poppins | Outfit | Open Sans | Lato | NunitosystemTypeface. system, sans and mono use fonts already on the device; the other names load the font from Google Fonts.
textAlignqueryleft | center | rightleftText alignment.
customHeightqueryCSS px—Custom height between 50 and 600 pixels.
borderRadius / borderWidthquerynumber0.75 / 1Corner and border measurements.
hoverEffect / glowEffect / boxShadowquerybooleanfalseEnables visual effects.
playerBarStylequerydefault | gradient | striped | animateddefaultPlayer capacity bar appearance.

Example request

bash
curl "https://mcapi.tr/api/v1/widget/normal/mc.hypixel.net?theme=dark&showFavicon=true"

HTTP 429 · 503

04 — Schema

Server response fields

FieldTypeDescription
queryobjectResolved host, port and query mode.
server_idUUIDStable server identifier inside MCAPI.TR.
onlinebooleanWhether the Minecraft ping completed successfully.
stalebooleanWhether the response comes from the last known successful query rather than a fresh ping.
checked_atISO 8601For stale data, time of the successful observation. For a 404, time of the failed attempt.
observed_atISO 8601 | nullTime of the last successful Minecraft observation; null if none is known.
last_attempt_atISO 8601When the last network attempt ended. A cache hit does not change it.
cache_expires_atISO 8601Scheduled expiration of this cached response.
reason_codestring | nullMachine-readable failure reason; null for a successful observation.
modsstring[]Mod IDs when advertised by Java status.
mod_details{ id, version }[]Forge mods with their versions (FML1, FML2 and the compressed FML3 list of 1.18.2+). version is null for server-only mods.
pluginsstring[]Plugin names when published through Java Query.
softwarestringServer software reported by Java Query.
query_dataobjectJava Query full stat (with query=true): map, game type, version and the player list (at most 1000 names). The host IP the server reports is not exposed.
icmpbooleanICMP reachability result for the target IP.
versionobject | nullServer version label and protocol number.
playersobject | nullOnline count, capacity and optional player sample.
motdobject | nullRaw, clean and HTML MOTD forms plus line arrays.
favicondata URL | nullBase64-encoded server favicon.
srvRecordobject | nullResolved Minecraft SRV record details when discovery was used.
roundTripLatencynumber | nullMinecraft query latency in milliseconds.
latency_source"pong" | "status"How the latency was measured: pong (ping/pong packet) or status (time of the status response).
target{ ip, port }IP address and port the status request went to (after SRV resolution).
edition, serverGUID, serverID, gameMode, gameModeID, portIPv4, portIPv6BedrockOnly for Bedrock: edition (MCPE or MCEE), server GUID and ID, game mode and the advertised IPv4/IPv6 ports from the RakNet pong.
errorstring | nullSafe error summary for a failed query.
400: invalid input. 404: no response or record. 429: rate limited; honor Retry-After. 503: temporary unavailability or maintenance. See each endpoint for applicable codes.

HTTP

Status codes

200Request succeeded.
400Invalid address or query parameter.
404Server is offline or unreachable.
429Per-minute request limit exceeded.
500Unexpected server error.
503Maintenance mode is active, or the status lookup did not finish in time (LOOKUP_DEADLINE). Retry after the Retry-After header.

Policies

Limits and caching

  • Status:120 requests per minute per IP for status, badge, simple and text.
  • Default:300 requests per minute by default for general endpoints.
  • Media:Up to 5,000 requests per minute for icon, banner and widget endpoints.
  • CORS:Public API endpoints allow all browser origins.
  • Privacy:Request profiling does not retain raw IP addresses or user agents.

Official SDKs

Use the API in Node.js and Python

Official zero-dependency clients provide typed server queries, discovery, statistics and media helpers without requiring an API key.

Node.js

mcapitr

npm

A Promise-based Node.js client with complete TypeScript declarations and Buffer helpers for generated media.

bash
npm install mcapitr
Node.js 18+TypeScriptPromise API

Python

mcapitr

PyPI

Synchronous and asynchronous Python clients with typed exceptions, pagination and byte downloads.

bash
pip install mcapitr
Python 3.9+TypedSync + async
Server history →

Explore observed history on server profiles.

GET /api/v1/history/{address}?period=24h&bedrock=false
Connection diagnostics →

See which step of a connection is failing.

GET /api/v1/diagnostics/{address}?edition=java
Integration examples →

Use examples for different languages and environments.

Snapshots are stored on meaningful changes or hourly. This is not time-based uptime; empty buckets mean no observations. Checks run from the MCAPI probe location only. They do not test player login, authentication, whitelist or gameplay access. Results may be cached for 5 minutes.