Accessing Webforms Parameters in hook_form_alter I got a webform which is embedded in a paragraph template. I do this via renderArray which works pretty well - the form is embedded. However I need to grab parameters - the only example I could find is about how to get &quot;GET&quot; parameters or about how to set default values via parameter. This is not what I need. I need the host paragraph as ID in my hook_form_alter. But I cannot find the value.
&lt;div class=&quot;paragraphs-container container&quot;&gt;
  &lt;div class=&quot;paragraphs-row&quot;&gt;
    &lt;div class=&quot;paragraphs-col&quot;&gt;
     {{ { 
       '#type': 'webform',
       '#webform': 'contact', 
       '#values': {
         'paragraph_context': 21
       },
       '#parameters':[{'a':'1122'}]
       } }}
    &lt;/div&gt;
  &lt;/div&gt;
 &lt;/div&gt;

The hook_form_alter $form array should contain either &quot;#values&quot; or '#parameters' but they are not included. - at least not in an easy findable location.

Are they in any deep sub sub sub location in the array?
or is there a mystic way to define the parameters for the webform, so hooks can pick them up?

Oh when you ask your self why I just don't use the default value to fill the value of a field directly... The reason would be, that I actually have to create the select form field options first. That's why I need the id to the paragraph - it contains all the holy data stored in its entity.
===================================== EDIT ================
After 3 hours of searching and heavy use of Xdebug I found it.
$form_state-&gt;build_info[&quot;callback_object&quot;]-&gt;originalData['value_name']

However it is a protected property. So I cannot access the value. There must be an easier way to get form parameters. Is there any?
I can't see a way to access the originalData property you mention. It's a protected property and there's no getter defined. See the callback_object's class in the webform module at src/WebformSubmissionForm.php.
I'd take a slightly different approach here. Since you are building custom values based on the paragraph id, it seems appropriate for the paragraph id to be included with the submission data. To do this, add a new hidden element to your webform for the paragraph id, e.g. with machine name paragraph_context.
Then, to provide a default value for your hidden field, update your twig like:
{{ { 
  '#type': 'webform',
  '#webform': 'contact', 
  '#default_data': {
    'paragraph_context': paragraph.id,
  },
} }}

(Note: I don't see any mention of the values or parameters options you're using in the How to embed a Webform documentation on d.o.)
Lastly, access your paragraph_context value via the #default_value key for your hidden element in your hook_form_alter(). For example:
mymodule_hook_form_alter(array &amp;$form, FormStateInterface $form_state, $form_id) {
  if ($form_id == 'my_form_id' &amp;&amp; !empty($form['elements']['paragraph_context'])) {
    $paragraph_context = $form['elements']['paragraph_context']['#default_value'];
  }
}