So OP has to clarify on both layers: natural person himself, legal entity, and the relation between them. And the result is affected by the questions OP raised?
If you are a shareholder director (“Gesellschaftergeschäftsführer”) you have a contract but are still treated as self employed for most laws. The 183days rule does not apply in that case.