<commit_before><?php namespace DoubleOptIn\PhpCli\Console\Command;

use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;

/**
 * Class LogCommand
 *
 * @package DoubleOptIn\PhpCli\Console\Command
 */
class LogCommand extends ClientApiCommand
{
	protected function configure()
	{
		$this->setName('log')
			->setDescription('Logs an action')
			->addArgument('email', InputArgument::REQUIRED, 'email to log')
			->addOption('action', 'a', InputOption::VALUE_REQUIRED, 'action to log for email')
			->addOption('scope', 's', InputOption::VALUE_OPTIONAL, 'scope for logging', '');
	}

	protected function execute(InputInterface $input, OutputInterface $output)
	{
		$hash = $input->getArgument('email');
		$action = $input->getOption('action');
		$scope = $input->getOption('scope');

		$command = new \DoubleOptIn\ClientApi\Client\Commands\LogCommand($hash, $action, $scope);

		$output->writeln(print_r($this->client()->send($command), true));
	}
}<commit_msg>modified command configuration to have an action required as argument<commit_after><?php namespace DoubleOptIn\PhpCli\Console\Command;

use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;

/**
 * Class LogCommand
 *
 * @package DoubleOptIn\PhpCli\Console\Command
 */
class LogCommand extends ClientApiCommand
{
	protected function configure()
	{
		$this->setName('log')
			->setDescription('Logs an action')
			->addArgument('action', InputArgument::REQUIRED, 'action to log for email [e.g. register, approved; lowercased actions recommended]')
			->addArgument('email', InputArgument::REQUIRED, 'email to log')
			->addOption('scope', 's', InputOption::VALUE_OPTIONAL, 'scope for logging [e.g. newsletter, webspecial; lowercased scopes recommended]', '');
	}

	protected function execute(InputInterface $input, OutputInterface $output)
	{
		$hash = $input->getArgument('email');
		$action = $input->getArgument('action');
		$scope = $input->getOption('scope');

		$command = new \DoubleOptIn\ClientApi\Client\Commands\LogCommand($hash, $action, $scope);

		$output->writeln(print_r($this->client()->send($command), true));
	}
}
{'fraction_non_alphanumeric': 0.15162907268170425, 'fraction_numerical': 0.0, 'mean_word_length': 6.023460410557185, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 25, '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': '4021751', 'n_tokens_mistral': 745, 'n_tokens_neox': 714, 'n_words': 148}