protected function execute(InputInterface $input, OutputInterface $output)
{
$this->validateInput($input);
$values = $this->getForm()->resolveOptions($input, $this->stdErr, $this->getHelper('question'));
$result = $this->getSelectedProject()->addIntegration($values['type'], $values);
/** @var Integration $integration */
$integration = $result->getEntity();
$this->stdErr->writeln("Created integration <info>{$integration->id}</info> (type: {$values['type']})");
$success = true;
if (!$input->getOption('no-wait')) {
$success = ActivityUtil::waitMultiple($result->getActivities(), $this->stdErr, $this->getSelectedProject());
}
$this->displayIntegration($integration, $input, $this->stdErr);
return $success ? 0 : 1;
}