@gameye/sdk
Version:
Node.js SDK for Gameye
49 lines • 1.44 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
/**
* Start a match
* @param matchKey a unique identifier for this match, you will use this
* identifier to refer to this match in the future
* @param gameKey identifier of the game
* @param locationKeys list of location identifiers, if the first one is not
* available, the second one is tried and so on.
* @param templateKey identifier of the template for this game to use
* @param config configuration of the template
* @param endCallbackUrl url that gets called (via GET) after the match ended
*/
function commandStartMatch(matchKey, gameKey, locationKeys, templateKey, config, endCallbackUrl) {
return this.command("start-match", {
matchKey,
gameKey,
locationKeys,
templateKey,
config,
endCallbackUrl,
});
}
exports.commandStartMatch = commandStartMatch;
/**
* Stop a match
* @param matchKey Identifer of the match
*/
function commandStopMatch(matchKey) {
return this.command("stop-match", {
matchKey,
});
}
exports.commandStopMatch = commandStopMatch;
/**
* Fetch the match state
*/
function queryMatch() {
return this.query("match", {});
}
exports.queryMatch = queryMatch;
/**
* Subscribe to the match state
*/
function subscribeMatch() {
return this.subscribe("match", {});
}
exports.subscribeMatch = subscribeMatch;
//# sourceMappingURL=gameye-match.js.map