WordPress API standard compliance and specification for external database [closed]

WordPress has the HTTP API that you could perhaps use to send POST (wp_remote_post) or GET (wp_remote_get) requests to an API, https://developer.wordpress.org/plugins/http-api/. But you could also use cURL to send the requests, I think.

If the API is developed by you, then it’s up to you to decide what kind of arguments the API accepts/expects and what kind of authentication it requires. If it’s some 3rd party API, then you need to consult the API documentation to see what is needed to get a response from it and in which form you’ll get the response – e.g. is it a JSON response.

Or if you can skip the API and connect directly to the database, then you could perhaps use $wpdb to do it as described here, Using wpdb to connect to a separate database