ordr.js is a Node.js module that allows you to easily interact with the o!rdr API and WebSocket.
- Promise-based
- Performant
- 100% coverage of the o!rdr API and WebSocket
- Install NodeJS
- Run
npm install ordr.js
import { Client } from "ordr.js"; const client = new Client(); const skins = await client.getSkins(); console.log(skins);
If you have an API key, you can specify it when initiating the client:
const client = new Client("API_KEY");
You can send a replay by doing the following:
client.sendRender({ ... replay: "https://domain.tld/path/to/your/file.osr", ... })
client.sendRender({ ... replay: "path/to/your/file.osr", ... })
const file = readFile("path/to/your/file.osr"); client.sendRender({ ... replay: file, ... })
const file = createReadStream("path/to/your/file.osr"); client.sendRender({ ... replay: file, ... })
import { Client, Events } from "ordr.js"; const client = new Client(); client.on(Events.Connected, () => console.log("Client connected!")); client.start();
List of events available here
See the license