You might be interested in this:
CiviCRM: Hide Activity Types (com.joinery.hideactivitytypes)
Hide activity types in one or more ways:
Remove the activity type from the "Actions" list on the Activity Summary.
On a per-contact-type basis: activity type will be removed from the "New Activity" list under a contact's Activities tab, based on the ...
This is typically handled by adding a webhook endpoint to your extension. The Mailchimp extension does this - see Webhook.php.
If you've already written your API action, it shouldn't be too tough to use a webhook to grab the data and push to API.
It sounds like maybe you're past this point, but https://lab.civicrm.org/dev/financial/issues/55 is an issue I ...
UPDATE: This answer won't work. See comments.
You can always access $_POST.
There is CRM_Utils_Request::retrieve() - it serves a different purpose but you could also use it, specifying method 'POST'. It's not technically a supported API call though. See https://github.com/civicrm/civicrm-core/blob/5.22.1/CRM/Utils/Request.php#L51
You should always use the API and only if there is no other route grab the SQL table. You do not need to connect to any CiviCRM database when using the API.
You can find more information on the API in the Developer Guide: https://docs.civicrm.org/dev/en/latest/api/
Do I understand correctly that you want to send data to your other application when a ...
If the tool is command-line only, it probably shouldn't be an extension.
If you need to bootstrap CiviCRM from the command line, and you can presume that the cv tool is in the path, and your tool is PHP-based, you can add the line:
cv php:boot --level=classloader
This should give you the ability to call CiviCRM classes ...