All the model companies except kind of Anthropic (and even they half-assedly do) implement the OpenAI API. It's not an open standard but, like the S3 API, it effectively is.
And, to answer your question, no. The existence of a common API makes it trivial to change zero code and send requests to a different model.
The Anthropic messages API is a competing standard (it's just better than the OpenAI API which even OpenAI has moved away from) and some Chinese providers use it as their standard.
Isn't this what LiteLLM is doing? And is Open Source? Maybe I am asking a dumb question because this is the age-old SaaS vs OSS debate, but I am struggling to find the angle here.