# Clickpath step response time SLO

**URL:** <https://community.dynatrace.com/t/clickpath-step-response-time-slo/45286>\
**Category:** Synthetic Monitoring\
**Tags:** slo, browser-monitors, synthetic-monitoring\
**Created:** [April 24, 2024, 5:21pm UTC](https://community.dynatrace.com/t/clickpath-step-response-time-slo/45286 "2024-04-24T17:21:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![PaulE](https://avatars.discourse-cdn.com/v4/letter/p/f14d63/32.png) [@PaulE](https://community.dynatrace.com/u/PaulE)\
**Post date:** [April 24, 2024, 5:21pm UTC](https://community.dynatrace.com/t/clickpath-step-response-time-slo/45286/1 "2024-04-24T17:21:49Z")

</div>

I’m trying to create an SLO based off the load times for a single step in a clickpath synthetic. Its basically % of requests that load in less than a defined time. I cannot figure out how to create calculated metrics **successful request count** or&nbsp; **total request count** for the SLO calculation as I would for a service based response time SLO.&nbsp; Has anyone had success with a similar requirement?

---

<div class="post-metadata">

**Author:** ![Eric\_Yu](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/eric_yu/32/20360_2.png) [@Eric\_Yu](https://community.dynatrace.com/u/Eric_Yu)\
**Post date:** [April 24, 2024, 10:19pm UTC](https://community.dynatrace.com/t/clickpath-step-response-time-slo/45286/2 "2024-04-24T22:19:20Z")

</div>

Hi Paul,

You might wanna use the partition transformation in your metric selector.

> **[Metrics API - Metric selector](https://docs.dynatrace.com/docs/dynatrace-api/environment-api/metric-v2/metric-selector)**
>
> Configure the metric selector for the Metric v2 API.

Here’s a quick example:

Say you have this data but only want to count the # of requests above a certain load time (let’s say 3s):

 ![Eric_Yu_0-1713996660192.png](https://global.discourse-cdn.com/dynatrace/original/3X/f/a/fabe07d83933caff6b36afcc5b706cc0641bb027.png)

You’d have to use partition to split that data into a new dimension (let’s call it "Category):

```markup
builtin:synthetic.browser.event.actionDuration.load
:splitBy("dt.entity.synthetic_test_step"):auto
:partition("Category",
          value("good",lt(3000)),
          value("bad",gt(3000)))
:filter(and(or(in("dt.entity.synthetic_test_step",entitySelector("type(synthetic_test_step),entityName.equals(~"click on ~~~"Finish~~~"~")")))))
:sort(value(auto,descending))
:limit(20)

```

 ![Eric_Yu_1-1713996782115.png](https://global.discourse-cdn.com/dynatrace/original/2X/6/6d9f4d9c49ece575a11ca0ff0f9c835736ac7562.png)

And filter only the dimension you want:

```markup
:filter(eq("Category","bad"))

```

 ![Eric_Yu_2-1713997080788.png](https://global.discourse-cdn.com/dynatrace/original/2X/6/64aa34d2a83f4a296fa633dded9f088e7173cc82.png)

If you want to create an SLO based off of that just take the count() of those values and divide it between the total load actions.

Hope it helps!

---

<div class="post-metadata">

**Author:** ![pt\_A360](https://avatars.discourse-cdn.com/v4/letter/p/71c47a/32.png) [@pt\_A360](https://community.dynatrace.com/u/pt_A360)\
**Post date:** [September 24, 2024, 4:42pm UTC](https://community.dynatrace.com/t/clickpath-step-response-time-slo/45286/3 "2024-09-24T16:42:13Z")

</div>

The results of the of the partition into good and bad results works, but executing a count on that data and returning a single value of 3 if we use your example returns a single value that is the sum of the action duration load times from the 3 events. I could certainly be missing something, but I am just not able to return back a simple count of X number above X seconds.

---

<div class="post-metadata">

**Author:** ![Eric\_Yu](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/eric_yu/32/20360_2.png) [@Eric\_Yu](https://community.dynatrace.com/u/Eric_Yu)\
**Post date:** [September 25, 2024, 3:53pm UTC](https://community.dynatrace.com/t/clickpath-step-response-time-slo/45286/4 "2024-09-25T15:53:21Z")

</div>

Try adding a [fold transformation](https://docs.dynatrace.com/docs/shortlink/api-metrics-v2-selector#fold) on the query or the explorer:

 ![Eric_Yu_0-1727279583889.png](https://global.discourse-cdn.com/dynatrace/original/3X/5/d/5de6abd38c586b6a841aaee7c996c1b54211146a.png)
