<commit_before><commit_msg>GitHub #13 - Add command to scan for sensors<commit_after>'use strict';

/**
 * Start sensor scan command
 *
 * Start a scan for new sensors
 */
class StartSensorScan {
  /**
   * Invoke command
   *
   * @param {Client} client Client
   *
   * @return {Promise} Promise for chaining
   */
  invoke(client) {
    let options = {
      method: 'POST',
      path:   `api/${client.username}/sensors`
    };

    return client.getTransport()
      .sendRequest(options)
      .then(() => true);
  }
}

module.exports = StartSensorScan;
{'fraction_non_alphanumeric': 0.13416815742397137, 'fraction_numerical': 0.0035778175313059034, 'mean_word_length': 2.7583892617449663, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7033839', 'n_tokens_mistral': 176, 'n_tokens_neox': 174, 'n_words': 46}