# Get a RUM group

Get one of a RUM application's user groups, with its activity in a time range.

[endpoint]
method = "GET"
base_url = "https://errors.betterstack.com"
path = "/api/v4/applications/{application_id}/groups/{id}"

[[path_param]]
name = "application_id"
required = true
type = "string"
description = "The RUM application the group was seen in."

[[path_param]]
name = "id"
required = true
type = "string"
description = "The group's `id` from listing RUM groups. For a group sent without an ID, the `id` is its name."

[[query_param]]
name = "from"
type = "datetime"
description = "Start of the time range in ISO 8601. Defaults to 14 days before `to`. RUM data is kept for 90 days, so an earlier `from` counts from 90 days ago."

[[query_param]]
name = "to"
type = "datetime"
description = "End of the time range in ISO 8601. Defaults to now. Must be after `from` and within the last 90 days."

[[query_param]]
name = "team_id"
type = "string"
description = "Team to use, such as `t123`. Get the ID via [List teams](/docs/uptime/api/teams/list/). Required when you can access more than one team."

[[header]]
name = "Authorization"
description = "Bearer `$TOKEN`"
required = true
type = "string"
[/endpoint]

[responses]
[[response]]
status = 200
description = "Returns the RUM group."
body = '''
{
  "data": {
    "id": "456",
    "type": "rum_group",
    "attributes": {
      "application_id": "123456",
      "group_id": "456",
      "name": "Acme Inc.",
      "first_seen_at": "2026-11-10T08:12:44.000Z",
      "last_seen_at": "2026-11-23T17:03:56.000Z",
      "user_count": 12,
      "session_count": 40,
      "error_count": 7,
      "replay_count": 44,
      "users_url": "https://rum.betterstack.com/team/t12345/users#/?q=user.group_id%3D%22456%22&s=123456",
      "sessions_url": "https://rum.betterstack.com/team/t12345/sessions#/?q=user.group_id%3D%22456%22&s=123456"
    }
  }
}
'''

[[response]]
status = 401
description = "The API token is missing or invalid."
body = '''
{
  "errors": "Invalid Team API token. How to find your Team API token: https://betterstack.com/docs/logs/api/getting-started/#obtaining-a-logtail-api-token"
}
'''

[[response]]
status = 403
description = "Your role doesn't allow viewing this, or the token can't be used for this API."

[[response]]
status = 404
description = "No application with that ID, or the group wasn't seen in the time range."
body = '''
{
  "errors": "Resource with the provided ID was not found"
}
'''

[[response]]
status = 422
description = "A `from` or `to` that isn't ISO 8601, or a `to` that isn't after `from` or is more than 90 days ago. `invalid_values` names the attribute. An unknown query parameter is listed in `invalid_attributes`."
body = '''
{
  "errors": "Sorry, some values are incorrect",
  "invalid_values": {
    "to": "to must be after from."
  }
}
'''
[/responses]

[params]
title = "Response attributes"

[[param]]
name = "id"
type = "string"
description = "The ID of the RUM group, such as `456`."

[[param]]
name = "type"
type = "string"
description = "Always `rum_group`."

[[param]]
name = "application_id"
type = "string"
description = "The application the group was seen in."

[[param]]
name = "group_id"
type = "string or null"
description = "The group's ID as the application sent it. `null` for a group sent with a name only."

[[param]]
name = "name"
type = "string or null"
description = "The group's latest name. `null` when the application sent none."

[[param]]
name = "first_seen_at"
type = "datetime or null"
description = "When the group was first seen in the time range. In ISO 8601 format, such as `2026-07-01T12:00:00Z`."

[[param]]
name = "last_seen_at"
type = "datetime or null"
description = "When the group was last seen in the time range. In ISO 8601 format, such as `2026-07-01T12:00:00Z`."

[[param]]
name = "user_count"
type = "integer"
description = "Number of the group's users seen in the time range."

[[param]]
name = "session_count"
type = "integer"
description = "Number of the group's sessions with a session replay in the time range."

[[param]]
name = "error_count"
type = "integer"
description = "Number of errors the group's users ran into in the time range."

[[param]]
name = "replay_count"
type = "integer"
description = "Number of session replays recorded for the group in the time range."

[[param]]
name = "users_url"
type = "string"
description = "Link to the Users page in the Better Stack web app, filtered to this group."

[[param]]
name = "sessions_url"
type = "string"
description = "Link to the Sessions page in the Better Stack web app, filtered to this group."
[/params]

#### Example cURL

```shell
[label Get a group]
curl --request GET \
  --url https://errors.betterstack.com/api/v4/applications/123456/groups/456 \
  --header "Authorization: Bearer $TOKEN"
```
