The sentence has a lot of embedding. We can make better sense of it by abstracting out one or more complex parts of the sentence. I have put brackets around one complex phrase that forms a single unit:
What are the reasons that [its decision to open itself automatically or not] is based on?
This could be abstracted to:
What are the reasons that X is based on?
The above sentence could be put another way to be clearer, but have essentially the same meaning:
What reasons is X based on?
As you can see, the sentence is grammatical and parse-able. However, you are right in thinking it is an awkward sentence; it is written in a confusing way, even for native speakers.