Splunk Dev

Splunk SDK for Python and .JS

ohbuckeyeio
Communicator

Anyone know of any examples on SplunkBase that have JavaScript-written commands using the Python SDK?

I’ve written about a dozen custom commands using Python and a familiar with that process.

The dev docs suggest the Splunk SDK for Python should be used for .JS commands but I’m not understanding how that’s possible without importing libraries like Flask.

https://dev.splunk.com/enterprise/docs/devtools/customsearchcommands/nonpythonscscs

Labels (2)
0 Karma

PickleRick
SplunkTrust
SplunkTrust

This is obviously a mistake on the docs page (unfortunately dev docs don't include the feedback form). How would you write JS code with Python SDK? It makes no sense.

0 Karma

ohbuckeyeio
Communicator

I agree that it makes no sense. I opened an SR and this is in the reply I got back from support:

The app  Splunk SDK for Python must work for .js as well as .py, please attempt using .js an let us know the outcome.

I thought, surely this can't be right. Especially on Python 3.7. There are packages built to allow for the import of Python libraries into Node.js, but the ones I know are designed for 3.8+.

0 Karma

PickleRick
SplunkTrust
SplunkTrust

I still think it's a mistake. There is a JS SDK separately downloadable from https://dev.splunk.com/enterprise/downloads

Get Updates on the Splunk Community!

New Year, New Changes for Splunk Certifications

As we embrace a new year, we’re making a small but important update to the Splunk Certification ...

[Puzzles] Solve, Learn, Repeat: Unmerging HTML Tables

[Puzzles] Solve, Learn, Repeat: Unmerging HTML TablesFor a previous puzzle, I needed some sample data, and ...

Enterprise Security (ES) Essentials 8.3 is Now GA — Smarter Detections, Faster ...

As of today, Enterprise Security (ES) Essentials 8.3 is now generally available, helping SOC teams simplify ...