Hello. We're trying to integrate our Golang application to splunk through APM by following this documentation
Is there any difference especially in terms of cost when sending the data directly to splunk compared to using the splunk collector?
Splunk license usage (apart from the rarely used "work-based license") is counted when the data is actually written to index on the indexer. It doesn't matter where the data comes from, or how it was processed "in transit" (for example - if you ingest 1GB of data from files/syslog/apps/whatever, then filter it and discard half of it so only 500MB gets written to indexes - only this 500MB counts against your license.
There is no difference.