with Splunk and Databricks (OAuth - Service Principal)?
Emit new event when a new alert is triggered in Splunk. See the documentation
Emit new event when a new search event is created. See the documentation
Emit new events when a search returns results in Splunk. See the documentation
Sends a new event to a specified Splunk index. See the documentation
Retrieve the status of a previously executed Splunk search job. See the documentation
Executes a Splunk search query and returns the results. See the documentation
import { axios } from "@pipedream/platform";
import https from "https";
export default defineComponent({
  props: {
    splunk: {
      type: "app",
      app: "splunk",
    }
  },
  async run({steps, $}) {
    const selfSigned = this.splunk.$auth.self_signed;
    const agent = new https.Agent({
		  rejectUnauthorized: !selfSigned
	  });
    return await axios($, {
      url: `${this.splunk.$auth.api_url}:${this.splunk.$auth.api_port}/services/authentication/current-context`,
      httpsAgent: agent,
      headers: {
        "content-type": `application/json`,
        "authorization": `Splunk ${this.splunk.$auth.api_token}`,
      },
      params: {
        output_mode: `json`,
      },
    })
  },
})import { axios } from "@pipedream/platform"
export default defineComponent({
  props: {
    databricks_oauth: {
      type: "app",
      app: "databricks_oauth",
    }
  },
  async run({steps, $}) {
    return await axios($, {
      url: `https://${this.databricks_oauth.$auth.deployment_name}.${this.databricks_oauth.$auth.domain}/api/2.0/clusters/list`,
      headers: {
        Authorization: `Bearer ${this.databricks_oauth.$auth.oauth_access_token}`,
      },
    })
  },
})