"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.sendEmailBookDemo = exports.sendBookDemoJson = exports["default"] = void 0;

var _axios = _interopRequireDefault(require("axios"));

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }

var sendEmailBookDemo = function sendEmailBookDemo(_ref) {
  var title = _ref.title,
      content = _ref.content,
      code = _ref.code,
      yzmGuidVal = _ref.yzmGuidVal,
      source = _ref.source;
  return (0, _axios["default"])({
    method: "post",
    url: "".concat(window.location.origin, "/api/v1/markEmail/SendKefu"),
    data: {
      title: title,
      content: content,
      code: code,
      keyRandomV2: yzmGuidVal,
      source: source
    }
  });
};

exports.sendEmailBookDemo = sendEmailBookDemo;

var sendBookDemoJson = function sendBookDemoJson(data) {
  return (0, _axios["default"])({
    method: "POST",
    url: "https://tracker.tita.com/api/v1/demos/request",
    data: data,
    headers: {
      headers: {
        "Content-Type": "application/json"
      }
    }
  });
};

exports.sendBookDemoJson = sendBookDemoJson;
var _default = {
  sendEmailBookDemo: sendEmailBookDemo
};
exports["default"] = _default;