Free and Open Source Machine Translation API. 100% self-hosted, no limits, no ties to proprietary services. Run your own API server in just a few minutes. Playing with it a little, it seems like it might be interesting to experiment with. Supports a couple of languages right now, but at least they're useful ones.
API docs: https://libretranslate.com/docs/
Github: https://github.com/uav4geo/LibreTranslate
The back end appears to be written in Python. Examples of use are in Javascript, but that's not necessarily the way it has to be done.
Language models are kept in a different repo: https://github.com/uav4geo/LibreTranslate-Models