"use strict";
(() => {
var exports = {};
exports.id = 8575;
exports.ids = [8575];
exports.modules = {

/***/ 770640:
/***/ ((module) => {

module.exports = require("cookies");

/***/ }),

/***/ 439491:
/***/ ((module) => {

module.exports = require("assert");

/***/ }),

/***/ 714300:
/***/ ((module) => {

module.exports = require("buffer");

/***/ }),

/***/ 706113:
/***/ ((module) => {

module.exports = require("crypto");

/***/ }),

/***/ 809523:
/***/ ((module) => {

module.exports = require("dns");

/***/ }),

/***/ 582361:
/***/ ((module) => {

module.exports = require("events");

/***/ }),

/***/ 657147:
/***/ ((module) => {

module.exports = require("fs");

/***/ }),

/***/ 241808:
/***/ ((module) => {

module.exports = require("net");

/***/ }),

/***/ 371017:
/***/ ((module) => {

module.exports = require("path");

/***/ }),

/***/ 12781:
/***/ ((module) => {

module.exports = require("stream");

/***/ }),

/***/ 371576:
/***/ ((module) => {

module.exports = require("string_decoder");

/***/ }),

/***/ 924404:
/***/ ((module) => {

module.exports = require("tls");

/***/ }),

/***/ 257310:
/***/ ((module) => {

module.exports = require("url");

/***/ }),

/***/ 473837:
/***/ ((module) => {

module.exports = require("util");

/***/ }),

/***/ 257143:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "default": () => (/* binding */ handle)
/* harmony export */ });
/* harmony import */ var _cocalc_server_licenses_get_license__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(742626);
/* harmony import */ var _cocalc_server_licenses_get_license__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_cocalc_server_licenses_get_license__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var lib_account_get_account__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(677793);
/* harmony import */ var lib_api_is_post__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(447618);
/* Return information about a given license. */ 


async function handle(req, res) {
    if (!(0,lib_api_is_post__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z)(req, res)) return;
    try {
        res.json(await get(req));
    } catch (err) {
        res.json({
            error: err.message
        });
        return;
    }
};
async function get(req) {
    const account_id = await (0,lib_account_get_account__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)(req); // account_id = null is OK -- then get very minimal info about the license.
    const { license_id  } = req.body;
    return await _cocalc_server_licenses_get_license__WEBPACK_IMPORTED_MODULE_0___default()(license_id, account_id);
}


/***/ })

};
;

// load runtime
var __webpack_require__ = require("../../../../webpack-api-runtime.js");
__webpack_require__.C(exports);
var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
var __webpack_exports__ = __webpack_require__.X(0, [1970,2921,2185,2014,6652,1808,9738,8312,540,7793,4181,3563,164], () => (__webpack_exec__(257143)));
module.exports = __webpack_exports__;

})();