Splunk Integration Guide
Send alerts through webhooks.
Configure Splunk alerts to send webhook notifications to Harness AI SRE when searches detect issues.
Before you begin
Harness webhook endpoint: Create a webhook in Harness AI SRE. Go to Create a Webhook to set up the custom webhook configuration that Splunk uses.
Splunk permissions: Access to create and modify alerts and webhook alert actions.
Webhook URL: Copy the webhook URL from your Harness webhook configuration.
Splunk webhook documentation: Go to Use a Webhook Alert Action to understand webhook alert action configuration.
Create webhook alert action
Navigate to alert actions
Navigate to Settings, then select Alert Actions.
Click Create New Alert Action.
Select Webhook.
Splunk Cloud requires using the Webhook Alert Action app or configuring via REST API.
Install the Webhook Alert Action app from Splunkbase.
Navigate to Apps, select Webhook Alert Action, then select Configuration.
Configure webhook alert action
Configure this field:
URL: Your Harness webhook URL.
https://<your-harness-instance>/gateway/ai-sre/api/webhooks/<webhook-id>
The webhook alert action does not expose fields for custom headers, authentication, HTTP method, or content type. Add the target URL to Splunk's webhook allow list if required by your Splunk deployment.
Webhook payload format
The webhook alert action sends a fixed JSON payload. Splunk does not support token substitution, custom templates, or configurable headers for this alert action; the payload structure below is always sent as-is.
result: The first result row of the triggered search, with keys matching the fields in your search results.sid: The search ID (SID) of the triggered saved search.results_link: A URL to the search results in Splunk.search_name: The name of the saved search, ornullif the search was not saved.owner: The owner of the saved search.app: The Splunk app context the search ran in.
Configure Splunk alert
Create or edit saved search
Save a search as an alert in Splunk:
Run your search query in Splunk.
Click Save As, then select Alert.
Configure alert settings
Alert Type: Real-time
Trigger Condition: Per-result (trigger for each result)
Throttle: 5 minutes
Use case: Immediate response to critical events
Alert Type: Scheduled
Cron Expression: 0 * * * * (hourly)
Trigger Condition: Number of results > 0
Use case: Periodic summary reports or batch analysis
Add webhook trigger action
Attach the webhook action to the alert:
In Trigger Actions, select Add Actions, then select Webhook.
Select the webhook alert action you created for Harness AI SRE.
Configure action-specific parameters.
Save the alert
Click Save to create the alert.
Configure field mapping in Harness
In your Harness webhook configuration, map the fixed Splunk payload fields (result, sid, results_link, search_name, owner, app) to alert properties.
Map basic fields
Use Mustache templates for simple field mapping:
Advanced field mapping with CEL
Use CEL for conditional logic and data transformation:
Because the payload does not include a severity or trigger-time field, derive severity and timing in Harness from the result object's fields (which mirror your search's output columns) or set a static severity for the webhook.
Test the integration
Test from Splunk
Trigger the saved search to confirm delivery:
Open the saved search configured with the webhook.
Click Run.
Wait for the alert to trigger, or manually trigger it if conditions are met.
Verify in Splunk
Confirm the webhook action executed:
Navigate to Activity, then select Triggered Alerts.
Find your alert and verify the webhook action executed successfully.
Check for HTTP response code (200 = success).
Verify in Harness
Confirm the alert arrived and mapped correctly:
Navigate to Alerts in Harness AI SRE.
Check that the alert appears.
Verify field mapping:
Alert title matches expected format.
Message includes search results.
Tags are populated correctly.
Link navigates to Splunk search results.
Webhook payload fields
The webhook alert action always sends these fields. There are no additional tokens available for this alert action:
result
The first result row of the triggered search
{"host": "web-01", "count": "8"}
sid
Search job ID
scheduler_admin_search_W2_at_14232356_132
results_link
URL to the search results
https://splunk.example.com/app/search/@go?sid=...
search_name
Saved search name, or null if unsaved
Prod Errors Search
owner
Owner of the saved search
admin
app
Splunk app context
search
Advanced configuration
Throttle real-time alerts
For continuous monitoring without overwhelming Harness:
Splunk alert configuration:
Harness CEL filter:
Scheduled batch analysis
For periodic summary reports:
Splunk alert configuration:
Harness field mapping:
Parse structured search result fields
Because result contains only the first row of the triggered search, design your search to surface the fields you need in that row (for example with stats or head 1):
Splunk search:
Harness field mapping:
Route by app
Create separate Harness webhooks for different Splunk apps:
Application logs webhook:
Security logs webhook:
Troubleshooting
Example: complete integration
This example shows a production-ready Splunk-to-Harness integration for application error monitoring.
Splunk saved search
Schedule: Real-time, trigger per-result, throttle 5 minutes
Splunk webhook payload
Splunk sends the fixed payload shape for every trigger, with result reflecting the columns from the saved search above:
Map fields in the Harness webhook
Next steps
Go to Route Alerts to route and deduplicate Splunk alerts.
Go to Use CEL in Webhooks to add advanced filtering and transformation logic.
Go to AI Agent to enable automated log analysis and correlation.
Related documentation
Splunk official documentation
Go to Use a Webhook Alert Action to configure the webhook alert action and understand the fixed payload format.
Go to Webhook Alert Action App to configure and install the Splunk Cloud webhook.
Last updated
Was this helpful?