update readme
Some checks failed
Publish Package / build (push) Failing after 20s

This commit is contained in:
Lee 2024-04-17 17:51:39 +01:00
parent 3e020337e3
commit cbb534adf4
2 changed files with 5 additions and 5 deletions

@ -13,10 +13,9 @@ npm install mcutils-library
Get player:
```javascript
import { getPlayer } from "mcutils-library";
import { getPlayer, CachedPlayer } from "mcutils-library";
const cachedPlayer = await getPlayer(playerId);
const { player } = cachedPlayer;
console.log(player);
```
@ -24,11 +23,9 @@ console.log(player);
Get Server:
```javascript
import { getServer } from "mcutils-library";
import JavaMinecraftServer from "mcutils-library/dist/types/server/javaServer";
import { getServer, CachedJavaMinecraftServer } from "mcutils-library";
const cachedServer = await getServer(ServerPlatform.Java, "hypixel.net");
const { server } = cachedServer;
console.log(server);
```

@ -1,3 +1,6 @@
/**
* The base URL for the API.
*/
export const API_ENDPOINT = "https://api.mcutils.xyz";
// Methods