It's always a good idea to include custom actions and filters in plugins that allows to modify the functionality of the plugin without the need of patching.
Larger sites often have additional data that is collected and stored for each order, so it makes sense to allow to post that data to sGTM instance.
Given the plugin is using wp_remote_post() it is possible to intercept the request and make change, but its not very efficient, because we need to parse / check what URL is called. The more elegant solution is apply_filters().
It's always a good idea to include custom actions and filters in plugins that allows to modify the functionality of the plugin without the need of patching.
Larger sites often have additional data that is collected and stored for each order, so it makes sense to allow to post that data to sGTM instance.
Given the plugin is using wp_remote_post() it is possible to intercept the request and make change, but its not very efficient, because we need to parse / check what URL is called. The more elegant solution is apply_filters().