priv8-cs
Version:
Multi-Platform Status API Module For XBL and PSN.
46 lines (37 loc) • 1.38 kB
JavaScript
/**
* @private
* @author Joker
* @name ConsoleStatus
* @copyright 2020, GTChecker.com, All rights reserved.
* @description Clean example of using this module.
* @returns JSON Objects of retrieved information.
* @license MIT
*/
const { XBL, PSN, RGS, TEST, debug } = require("./index");
/**
* @readonly
* @name XboxLiveStatus
* @description This endpoint allows you to retreive information about the world status of XBL.
*/
//XBL.status().then((r) => console.log(r[0])).catch((e) => console.log(e));
/**
* @readonly
* @name PlaystationNetworkStatus
* @description This endpoint allows you to change which region you want statuses from: EU or US - optional [defaults to EU].
*/
PSN.status("eu").then((r) => console.log(r)).catch((e) => console.log(e));
// PSN.countries("eu").then((r) => console.log(r)).catch((e) => console.log(e));
/**
* @readonly
* @name RockstarGamesStatus
* @description This endpoint allows you to change which region you want statuses from: UK, US, ES (many more coming) - optional [defaults to UK].
*/
//RGS.NetworkStatus().then((r) => console.log(r[0])).catch((e) => console.log(e));
//RGS.PS3GTAStatus().then((r) => console.log(r[0])).catch((e) => console.log(e));
RGS.NetworkStatus({
region: "ES"
}).then((r) => {
debug(r[0]);
}).catch((e) => {
console.log(e);
});