Phase 0: Python Warm-up
1. Install and Run the App
Set Up the Python Environment #
Navigate to the Phase 0 directory and create a virtual environment:
bash
cd ~/workshop/obi/01-obi-python
python3 -m venv .venv
source .venv/bin/activate
pip3 install -r requirements.txttext
Collecting flask>=3.0,<4.0
Downloading ...
Successfully installed flask-3.x.x ...Set Your Splunk Credentials #
Export your credentials as environment variables. Replace each placeholder with your actual values:
Exercise
Your environment should have values for ACCESS_TOKEN, REALM, and INSTANCE when you type env
If they do not exist export them as follows
bash
export ACCESS_TOKEN="<YOUR_TOKEN>"
export REALM="<YOUR_REALM>"
export INSTANCE="<YOUR_IDENTIFIER>"Run the App #
Start the Flask app in the background:
bash
python3 app.py &On startup the app sends a single app.heartbeat metric directly to the Splunk Ingest API. You should see:
text
Heartbeat sent to Splunk (200)
* Running on http://0.0.0.0:5150First hit return to get back to your prompt. Now hit the endpoint to confirm it’s working:
bash
curl -s http://localhost:5150/hello | jqYou should get back:
json
127.0.0.1 - - [04/May/2026 13:10:16] "GET /hello HTTP/1.1" 200 -
{
"host": "<YOUR_INSTANCE>",
"message": "Hello from the OBI Workshop warm-up!"
}Verify in Splunk #
- Open Splunk Observability Cloud UI
(url depends on your workshop location) and search for
app.heartbeatin Metric Finder (or make a chart ) - You should see the metric with a
host.nameattribute matching the value you set.

Note
At this point you have a running app and proof that Splunk can receive your data. But there are zero traces APM is empty. The app has no instrumentation code whatsoever.
