@slavmak2486/bx24ts
Version:
Library for bitrix24
36 lines (35 loc) • 1.07 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Bx24Hook = void 0;
const BX24_1 = require("./base/BX24");
class Bx24Hook extends BX24_1.baseBX24 {
constructor(url) {
super();
this.AUTH_EXPIRES = new Date().getTime() + 365 * 24 * 60 * 60 * 1000;
this.url = url;
}
refreshAuth(cb) {
this.logger.log('Dont use refresh auth for Bx24Hook');
if (cb)
cb(this.getAuth());
}
refreshAuthAsync() {
return new Promise(reject => {
this.logger.log('Dont use refresh auth for Bx24Hook');
reject({
access_token: '',
domain: this.url,
expires_in: 0,
member_id: '',
refresh_token: ''
});
});
}
runCallback(e) {
this.logger.log('Dont use runCallback for Bx24Hook', e);
}
sendMessage(cmd, params, cb) {
this.logger.log('Dont use sendMessage for Bx24Hook', [cmd, params, cb]);
}
}
exports.Bx24Hook = Bx24Hook;