

- Minecraft server status api how to#
- Minecraft server status api code#
- Minecraft server status api Offline#
You may refer to the table below to see any major revisions from the past up until present time. As time goes on, we can no longer support previous revisions and have to shut them down. When this happens, we release a new major version of the API called a revision, which is why you see /v2 in the URL of all API requests. Over the lifetime of this service, there has been a few changes that breaks compatibility with existing users who rely on consistent and non-changing data. An example of a standard error is Invalid address value, returned if the server address provided is not in a recognized : or format.
Minecraft server status api code#
If you do receive a non-200 status code response, the body will always contain a plain text string describing the error, with the Content-Type header set to text/plain. Whether or not you expect it, you should always handle in case the server returns an error, always in the form of a non-200 status code response. You may encounter an error from any API endpoint if you attempt to use any malformed input, such as an incorrectly formatted server address or a strange value for a query parameter. If the server you specify does not use the standard port value ( 25565 for Java Edition, 19132 for Bedrock Edition), then you will need to specify the port by using the following format.
Minecraft server status api Offline#
Make sure you are using the correct endpoint when retrieving a server status, as attempting to use the Java Edition status route with a Bedrock Edition host (or vise-versa) will result in a response saying the server is offline unless the server explicitly has cross-play supported. Has anyone a Idea Try querying your server on this site and see what it says: If that site says its offline but my script says its online, Id like to find out why. Supported VersionsĪll Minecraft servers, including pre-netty rewrite Java Edition and Bedrock Edition servers, are supported. If you want to bypass the cache, we recommend that you self-host the ping-server available on our GitHub organization. No exceptions will be made to the cache duration. Any request made after this cache expiration time will result in fresh data being retrieved on our end. The response will also contain a X-Cache-Time-Remaining header if the cache was hit, which contains an integer with the amount of seconds remaining until the cache expires for this request. All routes with data retrieved from the cache will contain a header in the response with the key X-Cache-Hit which will contain a boolean value whether or not our service used a value from cache. Please note that adding query parameters to the request will not force a fresh request, it will still return the cached response. Each route has its own cache duration, unique to the pathname of the request. To reduce the amount of spam and deliberate denial-of-service attacks of our service, we implement a caching system for all of the data we fetch, including but not limited to status responses and server icons. You may learn more about the properties you receive from these routes by reading the documented response body from the route on this page. Retrieves the status of any Java Edition Minecraft server.
Minecraft server status api how to#
All JSON returned from this service will have whitespace and any unnecessary characters removed to reduce network bandwidth and wasted information. Detailed documentation about our API and how to fetch the status of any Minecraft server.

No other data formatting standard is available at this time, and there is currently no future plan to support anything other than JSON. All status endpoints return a response body in JSON format, except if the response status code is not in the 200-299 success range, in which the body will be plain text. You will never have to use POST or any other method with requires you to send body data or headers with your request.

We currently only support endpoints using the GET method. The majority of this API uses the standardized REST API, which in simple terms means you will be making HTTP requests to our service. If you believe there is anything missing, any typos, or incorrect information on this page, please reach out to me via email at. This page will go over everything you need to know before implementing our API into your service. GET /v2/status/java/ goal of this API documentation is to accurately and precisely describe the functionality of this service in plain terms.
