Skip to content

Commit

Permalink
chore: +add syntax highlighting to codeblocks
Browse files Browse the repository at this point in the history
  • Loading branch information
brnhensley committed May 25, 2023
1 parent 3eb2796 commit 007cb2d
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -20,20 +20,20 @@ Here is an example of how to use the New Relic API Explorer (v2) to get your app
The average response time (milliseconds) is the value that appears on the main chart for your app on the [APM **Summary** page](/docs/applications-menu/applications-overview). New Relic uses this formula to calculate response time:

```
Response time = HttpDispatcher:average_call_time + ((WebFrontend/Queue:call_count * WebFrontend/Queue:average_response_time)/ HttpDispatcher:call_count)
Response time = HttpDispatcher:average_call_time + ((WebFrontend/Queue:call_count * WebFrontend/Queue:average_response_time) / HttpDispatcher:call_count)
```

To obtain the metric values, use the following two commands.

In these examples, the same time period has been used for each, and they are both summarized (averaged).

```
```bash
curl -X GET "https://api.newrelic.com/v2/applications/${APPID}/metrics/data.xml" \
-H "X-Api-Key:${APIKEY}" -i \
-d 'names[]=HttpDispatcher&values[]=average_call_time&values[]=call_count&from=2014-03-01T20:59:00+00:00&to=2014-03-01T21:59:00+00:00&summarize=true'
```

```
```bash
curl -X GET "https://api.newrelic.com/v2/applications/${APPID}/metrics/data.xml" \
-H "X-Api-Key:${APIKEY}" -i \
-d 'names[]=WebFrontend/QueueTime&values[]=call_count&values[]=average_response_time&from=2014-03-01T20:59:00+00:00&to=2014-03-01T21:59:00+00:00&summarize=true'
Expand Down

0 comments on commit 007cb2d

Please sign in to comment.