Invisible reCAPTCHA - Missing required parameters: sitekey

If you are here only for working Recaptcha Invisible v2 code example:
1. Put id="recaptcha" on your form button
2. Add JavaScript

var recaptchaCallback = function() {
        $("button#recaptcha").each(function () {
            var el = $(this);
            grecaptcha.render($(el).attr("id"), {
                "sitekey": 'YOUR_GOOGLE_RECAPTCHA_KEY',
                "size": "invisible",
                "badge": "bottomleft",
                "callback": function (token) {
                    $(el).closest("form").submit();
                }
            });
        });
    };
</script>
<script src="https://www.google.com/recaptcha/api.js?onload=recaptchaCallback&render=explicit" async defer></script>

You are missing an important part here. The api widget must rendered explicitly. Just add render=explicit to recaptcha api script.

<script src='https://www.google.com/recaptcha/api.js?
onload=onloadCallback
&render=explicit
&hl={{app.request.locale|default(defaultLang) }}' async defer>
</script>

Read the Google doc (reCAPTCHA V2 | reCAPTCHA - Explicitly render the reCAPTCHA widget).