User:Eleanorsilly/API research

From MinecraftOnline
Jump to navigation Jump to search

MCO has an "API" ; the main endpoint is https://minecraftonline.com/cgi-bin/. This API has no documentation, and this page is meant to create some. Feel free to add content.

Player related

Note: None of these are case sensitive.

Time connected


First seen


Last seen


Ban reason

General information


Lists



Other




Location-related

Output of the getnearestplace API
  • Get nearest place : https://minecraftonline.com/cgi-bin/getnearestplace, returns a JSON output (see picture). The input works as follow :
      • If there is 1 number, it will assumed to be both the x and z coordinate.
      • If there are 2 numbers, the first number will be the x coordinate and the 2nd the z coordinate (the 2 numbers are separated by commas)
      • If there are 3 numbers, the first number will be the x coordinate, the 2nd the y coordinate and the 3rd the z coordinate (the 3 numbers are separated by commas)
    • The system doesn't accept decimal numbers. If you put a . after a number and then another number, the 2 numbers will be multiplied. It does accepts negative number however (of course).
    • Example URL : https://minecraftonline.com/cgi-bin/getnearestplace?-6145,40,-18060

Map-related

Output of the getmapiteminfo API

Other

  • Get random render : https://minecraftonline.com/cgi-bin/getrandomrenders, returns 10 random renders out of a set of about 22.3K different renders as of September 2025.
  • The format consists of multiple parts (usually 12) separated by colons, but this may differ.
  1. username (3-16 characters consisting of letters, digits, and underscores)
  2. x-coordinate (decimal)
  3. y-coordinate (decimal)
  4. z-coordinate (decimal)
  5. pitch (decimal, -360 to 360)
  6. yaw (decimal, -90 to 90)
  7. dimension (int, one of [-1, 0, 1])
  8. timestamp render requested (UNIX timestamp)
  9. timestamp render started (UNIX timestamp)
  10. timestamp render ended (UNIX timestamp)
  11. imgur url (https://imgur.com/ID, ID consists of 7 characters)
  • The 10 renders are separated by line returns (LF, not CR+LF)
  • The decimals are sometimes in scientific notation (example: 200xth:-1394.8562961045045:84.0:-11005.000412592239:-142.32819:-3.4573078E-4:0:1533156330:1533158731:1533162396:https://i.imgur.com/fuHAi96)
  • Image URL is sometimes missing or "null" (513/22304 renders)
  • There are sometimes additional colons (example: Mechman007:-10529.511407626493:62.0:18303.455315672443:-163.8643341064453:-14.459343910217285:0:1632988236::1632992694::1632998519:1633003145:https://i.imgur.com/wrDd8qg)
  • The Imgur links of 2552 of the renders are broken and return an error, the size of the 19239 downloadable renders totals 7,3 GiB

Examples:

ScenarioPlanet:-10492.197816665686:106.0:18564.25155042393:4.799978733062744:12.750019073486328:0:1649867392:1649869494:1649870998:https://i.imgur.com/3DPC6ln
1Catnip:-4651.664585009763:63.0:9041.036211823024:327.89398:-8.689254:0:1581967557:1581967560:1581969471:https://i.imgur.com/3DPC6ln
DespawnedDiamond:-11019.714362717006:63.0:4292.996566996314:-17.699982:45.00005:0:1566917638:1566920402:1566921491:https://i.imgur.com/D8kRMSg
Mechman007:-1022.6012219891609:72.5:-103.50161529748631:-66.30278778076172:-3.682539939880371:1:1641496866:1641505458:1641506424:https://i.imgur.com/tmS7FH4
ScenarioPlanet:-116.30000001192093:65.0:395.11702711088753:81.79940795898438:-5.866550922393799:0:1673807889:1673810594:1673819821:https://i.imgur.com/J3ePR3J
Ziza_art:-12196.918715952588:63.5:-1200.3353441937084:342.08185:35.542236:0:1567437016:1567437022:1567441120:https://i.imgur.com/dWZRoGW
JSodil:3003.069242903392:72.0:-2541.925000011921:148.59271:0.75002074:0:1572954959:1572954973:1572957715:https://i.imgur.com/G2qMAvi
LewisD95:-90.69215620670178:65.0:391.9729882679219:-54.864136:6.523916:0:1533334451:1533334641:1533339149:https://i.imgur.com/d9YZqn9
2b2tisFull:312.4892151899962:28.0:-382.5857560400585:4.877460479736328:10.04332160949707:0:1645234397:1645235332:1645245080:https://i.imgur.com/3WYEIsj
ScarClaw72:-12982.497519614059:76.0:-3908.8817702126994:180.2503:13.949989:0:1556860094:1556862616:1556864877:https://i.imgur.com/5Tzek5b

  • Get the end of the Minecraft chat : https://minecraftonline.com/cgi-bin/tailminecraftlog.sh, returns the 20 last line of the chat, with [MCS], [DSC] and [IRC] prefixes (and likely a [TG] prefix too)
    • Every user, on Discord, MC and IRC, get their username with < and > around it, except in IRC and MC join messages
    • Note: this isn't very up-to-date most of the time, with delays like a minute possible. The script only updates the page when the last 20 lines have changed.
    • Note 2: special characters (accents etc) are formatted to be shown as in HTML. Also, every line finishes by <br /> AND a line return (LF, not CR+LF).
    • Note 3: this works even if the server is down/during time outs
    • Note 4: in case of hard fails, it returns \n

  • Generate the main page's content with no CSS (easy scraping): https://minecraftonline.com/cgi-bin/generatesideboxes.sh, returns a basic HTML page
    • Things that can be scraped from it:
      • Server status (may be incorrect in case of hard fails)
      • Player count (although that can be calculated from the player list) (may also be incorrect in case of hard fails)
      • Unique players from yesterday
      • Homes number
      • Admins/moderators number (same as player count, can be calculated through the list)
      • Random pictures from wiki

Do not work anymore



Notes

If any player related request is asked with an unknown player, it'll return NOTFOUND. Some can return INVALID if the data is incorrect (e.g. empty parameter), so look out for that.

Some of these may have trailing line returns, remember to clear those.