text: "use strict";
  
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.getOperation = getOperation;
  exports.validateParams = validateParams;
  exports.getURL = getURL;
  exports.getRequestTimeout = getRequestTimeout;
  exports.isAuthSupported = isAuthSupported;
  exports.prepareParams = prepareParams;
  exports.handleResponse = handleResponse;
  
  var _flow_interfaces = require("../../flow_interfaces");
  
  var _operations = _interopRequireDefault(require("../../constants/operations"));
  
  function getOperation() {
    return _operations["default"].PNWhereNowOperation;
  }
  
  function validateParams(modules) {
    var config = modules.config;
    if (!config.subscribeKey) return 'Missing Subscribe Key';
  }
  
  function getURL(modules, incomingParams) {
    var config = modules.config;
    var _incomingParams$uuid = incomingParams.uuid,
        uuid = _incomingParams$uuid === void 0 ? config.UUID : _incomingParams$uuid;
    return "/v2/presence/sub-key/".concat(config.subscribeKey, "/uuid/").concat(uuid);
  }
  
  function getRequestTimeout(_ref) {
    var config = _ref.config;
    return config.getTransactionTimeout();
  }
  
  function isAuthSupported() {
    return true;
  }
  
  function prepareParams() {
    return {};
  }
  
  function handleResponse(modules, serverResponse) {
    if (!serverResponse.payload) {
      return {
        channels: []
      };
    }
  
    return {
      channels: serverResponse.payload.channels
    };
  }
  //# sourceMappingURL=where_now.js.map
  