Getting Data In

How to add data to splunk with custom source and sourceType value

phagunbaya
Explorer

My requirements are to save a csv formatted data into splunk from a custom app. I'm using django bindings.
Was not able to figure out which API should I use for inserting data with custom source and sourceType field values from within the python script.

0 Karma
1 Solution

phagunbaya
Explorer
0 Karma

richgalloway
SplunkTrust
SplunkTrust

If your data is formatted as CSV then you probably don't need a custom sourcetype. Use 'CSV'.

---
If this reply helps you, Karma would be appreciated.
0 Karma

phagunbaya
Explorer

That's the default behaviour. I was thinking of if I could change it. Also if I mention "source" and "sourcetype" column in my cvs data then these are renamed as "extracted_source" and "extracted_sourcetype".

0 Karma
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...