"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const integration_base_1 = require("@things-factory/integration-base");
const debug = require('debug')('aidoop:robotics:increment-count-get');
async function IncrementCounterGet(step, { logger, domain, closures, state }) {
    var { connection } = step;
    var connectionInstance = integration_base_1.ConnectionManager.getConnectionInstanceByName(domain, connection);
    if (!connectionInstance) {
        throw Error(`connection is not found : ${connectionInstance}`);
    }
    logger.info(`incrementCount: (${connectionInstance.incrementCount})`);
    return {
        data: connectionInstance.incrementCount
    };
}
IncrementCounterGet.parameterSpec = [];
IncrementCounterGet.help = 'robotics/task/increment-count-get';
integration_base_1.TaskRegistry.registerTaskHandler('increment-count-get', IncrementCounterGet);
//# sourceMappingURL=increment-counter-get.js.map