passport-telegram-web-app
Version:
A [Passport](https://www.passportjs.org/) strategy for [telegram web app (bots)](https://core.telegram.org/bots/webapps) authentication.
17 lines (16 loc) • 460 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ExtractHash = void 0;
var ExtractHash = /** @class */ (function () {
function ExtractHash() {
}
ExtractHash.fromHeaders = function (request) {
var hash = request.headers["tg-web-app-hash"];
if (!hash) {
return null;
}
return hash;
};
return ExtractHash;
}());
exports.ExtractHash = ExtractHash;