The developer documentation looks very comprehensive and what I followed to setup dev environment worked well.
I started with “Creating Your First Integration” and got to this line in 1st paragraph:
“The minimum is that you define a DOMAIN
constant that contains the domain of the integration”
As a developer of many years, the word ‘DOMAIN’ could mean many things. So I’m looking for a definition of what Home Assistant thinks it means.
First definition is that it the part of the component name before the period. (not a definition)
Integration Architecture says this:
For a list of defined domains, see entities.
The page it points to does not mention the word Domain.
The glossary uses an example of ‘light’ as a Domain name, which suggest these are predefined and I need to use the right one.
I found a number of posts asking the same question for a list of Domains, none I found had been answered (replies are not answers).
Then I ran the script “script.scaffold integration” to what it does with Domain.
It does this:
What is the domain?
> sonnenBatterieEvo
Error: Domains cannot contain spaces or special characters.
Clearly, that name contains no spaces or special characters. There is an undocumented length limit since it accepted ‘batterie’ as a domain name.
Now I’m confused as to whether the name I choose for Domain matters or not?
Is there a predefined list of Domains and I need to choose the correct domain for a batterie? If not, I’m still confused as to what the purpose of the Domain part of the name is for.