You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
495 B
23 lines
495 B
import genericProxyHandler from "utils/proxy/handlers/generic";
|
|
import { asJson } from "utils/proxy/api-helpers";
|
|
|
|
const widget = {
|
|
api: "{url}/{endpoint}/{domain}",
|
|
proxyHandler: genericProxyHandler,
|
|
mappings: {
|
|
status: {
|
|
endpoint: "2",
|
|
map: (data) => {
|
|
const jsonData = asJson(data);
|
|
return {
|
|
players: jsonData.players,
|
|
version: jsonData.version,
|
|
online: jsonData.online
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
export default widget;
|