# Get live service metrics

> Get live service metrics: TrueProxies customer API reference with the required scope, parameters, responses and code samples.

Source: https://docs.trueproxies.com/api/operations/get_v1_services_id_live_metrics/

`GET /v1/services/{id}/live-metrics`

**Fetch**

```js
const url = 'https://api.trueproxies.com/v1/services/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/live-metrics';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

**cURL**

```sh
curl --request GET \
  --url https://api.trueproxies.com/v1/services/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/live-metrics \
  --header 'Authorization: Bearer <token>'
```

Ten-second observed traffic rates in bits per second, UTC daily bytes and recorded proxy outcomes. Read last\_activity\_at for freshness; silence does not establish healthy idle traffic. Unavailable telemetry returns 503.

## Authorizations

- **[customerAPIKey](https://docs.trueproxies.com/api/#customerapikey)**

## Parameters

### Path Parameters

- **id**

  required

  string format: uuid

### Query Parameters

- **customer\_id**

  string format: uuid

  Owned sub-customer UUID. Resellers only; reads require reseller:read and writes reseller:purchase in addition to the operation scope. X-Customer-Id header is an alternative. Not allowed for me, wallet, trial, API keys, or reseller-management routes.

## Responses

### 200

Observed metrics; sample freshness is independent of query freshness.

Media type: `application/json`

object

- **completed\_connections**

  required

  Recorded proxy outcomes underlying success\_rate. Selected by event timestamp, not literal completion time; delayed or long-running connections can appear later.

  integer

- **connections\_per\_minute**

  required

  Sum of recorded usage connection deltas in the minute ending at window\_end.

  integer

- **download\_bps**

  required

  Customer download bits per second in the last complete series bucket, from bytes\_out. Zero is an absence of recorded bytes, not proof of healthy idle traffic.

  number

- **interval\_seconds**

  required

  integer

  Allowed value: 10

- **last\_activity\_at**

  required

  Latest non-system usage event before sampled\_at, scanned since the earlier of midnight UTC or window\_start. Null means no observation in that bounded interval. Samples are emitted only for activity; silence cannot distinguish idle traffic from unavailable collection. Treat current rates as unavailable when this is null or older than 60 seconds.

  string | null format: date-time

- **sampled\_at**

  required

  UTC query time; this does not prove collector health or data freshness.

  string format: date-time

- **series**

  required

  Array\<object>

  \>= 60 items <= 60 items

  object

  - **download\_bps**

    required

    number

  - **ts**

    required

    Inclusive UTC start of this ten-second bucket.

    string format: date-time

  - **upload\_bps**

    required

    number

- **success\_rate**

  required

  Recorded proxy outcomes without a proxy error divided by recorded outcomes whose event timestamps fall in the minute ending at window\_end. Outcomes that ended on the client side are not proxy errors; outcomes with no response are. These are proxy connection outcomes, not destination HTTP status. Null when no outcomes are recorded. Event timestamps may represent connection start rather than completion time.

  number | null

  <= 1

- **traffic\_today\_bytes**

  required

  Observed non-system upload plus download bytes from midnight UTC up to sampled\_at; delayed arrivals may revise totals.

  integer

- **upload\_bps**

  required

  Customer upload bits per second in the last complete series bucket, from bytes\_in.

  number

- **window\_end**

  required

  Exclusive UTC end, rounded down to ten seconds and delayed twenty seconds for collection and shipping. Later arrivals may revise observations.

  string format: date-time

- **window\_start**

  required

  Inclusive UTC start of the ten-minute rate series.

  string format: date-time

##### Example

```json
{
  "interval_seconds": 10
}
```

### 400

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 401

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 403

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 404

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 409

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 429

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 500

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### 503

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```

### default

Error

Media type: `application/json`

object

- **code**

  required

  string

  Allowed values: BAD\_REQUEST UNAUTHENTICATED FORBIDDEN NOT\_FOUND CONFLICT RATE\_LIMITED SERVICE\_UNAVAILABLE OFFER\_UNAVAILABLE CITY\_UNAVAILABLE CAPACITY\_UNAVAILABLE INVOICE\_NOT\_PAYABLE PROVIDER\_ERROR PIPE\_UNAVAILABLE TRIAL\_NOT\_ELIGIBLE EMAIL\_UNVERIFIED INTERNAL

- **details**

  What a client needs to act on the error (ids, flags), never display text.

  object

  - ***key***

    additional properties

    any

- **message**

  required

  string

##### Example

```json
{
  "code": "BAD_REQUEST"
}
```
