title: Symfony 4: "Autowire: you should configure its value explicitly."
body: <p>I'm starting to working with Symfony4 and I meet the following error when I try to run my server: <strong>Cannot autowire service &quot;App\Controller\CharacterInformation&quot;: argument &quot;$region&quot; of method &quot;__construct()&quot; is type-hinted &quot;string&quot;, you should configure its value explicitly.</strong></p>
  <p>How I instantiate my class:</p>
  <pre><code> /**
   * @Route(&quot;/&quot;)
   * @return Response
   */
  function mainPage() {
      $characterInformation = new CharacterInformation('eu');
      return new Response($characterInformation-&gt;getCharacter());
  }
  </code></pre>
  <p>The constructor of CharacterInformation:</p>
  <pre><code> /**
   * @var int
   */
  public function __construct(string $region) {
          $this-&gt;apiInformation = new ApiContent($region);
  }
  </code></pre>
  <p>The constructor of ApiContent:</p>
  <pre><code>    public function __construct(string $region) {
      $apiToken = new ApiToken($region);
      $this-&gt;token = $apiToken-&gt;getToken();
      $this-&gt;region = $apiToken-&gt;getRegion();
  }
  </code></pre>