### Apache Airflow version

2.7.2

### What happened

Sent request without dry_run parameter to dags/{dag_id}/updateTaskInstancesState and got a 500 error.

### What you think should happen instead

I should be able to send a request to update task instances state and get a valid response.

### How to reproduce

You can see this by commenting out line 215 in tests/api_connexion/schemas/test_task_instance_schema.py and running tests. This is a similar error to #34563.

### Operating System

Ubuntu 20.04

### Versions of Apache Airflow Providers

_No response_

### Deployment

Docker-Compose

### Deployment details

_No response_

### Anything else

_No response_

### Are you willing to submit PR?

- [X] Yes I am willing to submit a PR!

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)

result = set_task_instance_state_form.load(self.current_input)
        expected_result = {
            "dry_run": True,
            "execution_date": dt.datetime(2020, 1, 1, 0, 0, tzinfo=dt.timezone(dt.timedelta(0), "+0000")),
            "include_downstream": True,
            "include_future": True,
            "include_past": True,
            "include_upstream": True,
            "new_state": "failed",
            "task_id": "print_the_context",
        }
        assert expected_result == result
    @pytest.mark.parametrize(
        "override_data",
        [
            {"task_id": None},
            {"include_future": "foo"},
            {"execution_date": "NOW"},
            {"new_state": "INVALID_STATE"},
            {"execution_date": "2020-01-01T00:00:00+00:00", "dag_run_id": "some-run-id"},
        ],
    )
    def test_validation_error(self, override_data):
        self.current_input.update(override_data)
        with pytest.raises(ValidationError):
            set_task_instance_state_form.load(self.current_input)