Regarding the PR, please fix the clang format checks by running clang-format on your files. I have also one question about the rtpengine_load_api(..) function, it should be placed in the module actually using the rtpengine API, and not in the module exporting the API, right?
As in:
https://github.com/kamailio/kamailio/blob/f5f7c913d4f008b9937677ae2c2d66baa0...
`sanity_load_api` function is defined in `sanity` module and is called in modules using the apis.
You are right, there are different patters on how this API is exposed. Thanks for the fixes regarding the format, but I think unfortunately its still failing. Did you executed in the main kamailio directory the clang-format tool? This is usually the easiest way to fix it.