System Activity
During its operation, the Edge system generates various events that can be queried. These events provide insights into system activities, errors, and other significant occurrences.
Overview
The EdgeSession object has a property called system_activity that allows you to access system events.
There are three queries available through system_activity:
edge.system_activity.get_application_activityto get application-specific activity.edge.system_activity.get_user_activityto get user-specific activity.edge.system_activity.get_activityto query system activity using custom filters.
You must be a server administrator to see activity across all organizations, or an organization administrator to see
activity within your organization (and must specify the org_id parameter).
System activity is tagged by Kind, Feature, and Action, and in the general get_activity method you can filter by these
fields.
Activity Kind
The kind field categorizes the type of activity. Kinds include: agenticai, application, billing, budget, email,
feedback, file, home, invite, keycloak, kubernetes, license, organization, quay, secret, server, server_info, service,
user.
Activity Feature
The feature field sub-categorizes the activity within its kind. Features vary depending on the kind of activity.
Features include: approval, chat, profile, config, credentials_email, cron_job, download, file, image_puller,
inference_profile, k8s_job, keycloak, license, mcp_server, mcp_tool, namespace, node_class, node_pool, organization,
placeholder, preset, profile, prompt, quota, role, root_node, s3_file_uri, server, storage_class, template, thread,
timeout, type, upload, user, version, volume_claim.
Features by Kind
| Kind | Features |
|---|---|
| agenticai | chat, config, inference_profile, mcp_server, mcp_tool, preset, prompt, thread |
| application | (no feature), approval, profile, timeout, version |
| billing | (no feature) |
| budget | (no feature) |
| (no feature) | |
| feedback | (no feature) |
| file | (no feature), s3_file_uri, upload |
| invite | template |
| keycloak | role |
| kubernetes | (no feature), compute_profile, cron_job, image_puller, k8s_job, namespace, node_class, node_pool, placeholder, storage_class, volume_claim |
| license | file, quota, type |
| organization | (no feature), file, license, role, root_node, user |
| quay | (no feature) |
| secret | (no feature) |
| server | license |
| server_info | (no feature) |
| service | (no feature), approval |
| user | (no feature), credentials_email, license, role |
Constructor
Constructing these yourself is not recommended. You should make an
EdgeSession and access the .system_activity property, which
will return an EdgeSystemActivity object.
Methods
get_application_activity
get_application_activity(time_span, org_id, limit) -> dict[str, Sequence[SystemApplicationActivity]]
Retrieve activity related to application event kinds.
Parameters
time_span (timedelta)
The time span backwards from now to retrieve activity for, in single day granularity.timedelta(days=1)would retrieve activity for the previous day.org_id (str)
The organisation ID to retrieve activity for. Optional; if not provided, activity for all organisations will be returned.limit (int)
The maximum number of activity records to return. Optional; if not provided, defaults to 1000.
Returns
dict[str, Sequence[SystemApplicationActivity]]
A dictionary mapping application IDs to lists of SystemApplicationActivity records. This makes it easy to determine which applications were used during the time frame, which users accessed them, and the profiles used, among other details.
SystemApplicationActivity
@dataclass
class SystemApplicationActivity:
timestamp: datetime
org_id: str
user: str
feature: str
action: str
profile_id: str
Example
>>> from datetime import timedelta
>>> edge.system_activity.get_application_activity(timedelta(days=1), limit=3)
{'analysis': [SystemApplicationActivity(timestamp='2025-12-15T14:21:39', org_id='e2e', user='edge_e2e_testuser@enthought.com', feature='', action='start', profile_id='edge.medium'),
SystemApplicationActivity(timestamp='2025-12-15T14:23:24', org_id='e2e', user='edge_e2e_testuser@enthought.com', feature='', action='start', profile_id='edge.medium'),
SystemApplicationActivity(timestamp='2025-12-15T14:25:26', org_id='e2e', user='edge_e2e_testuser@enthought.com', feature='', action='start', profile_id='edge.medium')]}
get_user_activity
get_user_activity(time_span, org_id, limit) -> dict[str, Sequence[SystemUserActivity]]
Retrieve activity related to user event kinds.
Parameters
time_span (timedelta)
The time span backwards from now to retrieve activity for, in single day granularity.timedelta(days=1)would retrieve activity for the previous day.org_id (str)
The organisation ID to retrieve activity for. Optional; if not provided, activity for all organisations will be returned.limit (int)
The maximum number of activity records to return. Optional; if not provided, defaults to 1000.
Returns
dict[str, Sequence[SystemUserActivity]]
A dictionary mapping usernames to lists of SystemUserActivity records. This makes it easy to determine which users were active during the time frame, what actions they performed, and other details.
SystemUserActivity
@dataclass
class SystemUserActivity:
timestamp: datetime
org_id: str
kind: str
feature: str
action: str
resource_id: str
extra: str
Example
>>> from datetime import timedelta
>>> edge.system_activity.get_user_activity(timedelta(days=1), limit=3)
{'edge_e2e_testadmin@enthought.com': [SystemUserActivity(timestamp='2025-12-15T14:04:34', org_id='', kind='user', feature='', action='login', resource_id='', extra=''),
SystemUserActivity(timestamp='2025-12-15T14:08:02', org_id='', kind='user', feature='', action='login', resource_id='', extra='')],
'edge_e2e_testuser@enthought.com': [SystemUserActivity(timestamp='2025-12-15T14:08:16', org_id='', kind='user', feature='', action='login', resource_id='', extra='')]}
get_activity
get_activity(time_span, org_id, kind, feature, action, limit) -> Sequence[SystemActivity]
Retrieve activity over a given timespan.
Parameters
time_span (timedelta)
The time span backwards from now to retrieve activity for, in single day granularity.timedelta(days=1)would retrieve activity for the previous day.org_id (str)
The organisation ID to retrieve activity for. Optional; if not provided, activity for all organisations will be returned.kind (str) The kind of activity to filter by. Optional; if not provided, activity of all kinds will be returned.
feature (str) The feature to filter by. Optional; if not provided, activity for all features will be returned.
action (str) The action to filter by. Optional; if not provided, activity for all actions will be returned.
limit (int)
The maximum number of activity records to return. Optional; if not provided, defaults to 1000.
Returns
Sequence[SystemActivity]
A list of SystemActivity records.
SystemActivity
@dataclass
class SystemActivity:
timestamp: datetime
org_id: str
user: str
kind: str
feature: str
action: str
resource_id: str
extra: str
Example
>>> from datetime import timedelta
>>> edge.system_activity.get_activity(timedelta(days=1), limit=5)
[SystemActivity(timestamp='2025-12-15T13:42:41', org_id='', user='', kind='organization', feature='', action='audit', resource_id='', extra=''),
SystemActivity(timestamp='2025-12-15T13:42:41', org_id='', user='', kind='organization', feature='', action='create', resource_id='default', extra=''),
SystemActivity(timestamp='2025-12-15T13:42:41', org_id='', user='', kind='organization', feature='root_node', action='create', resource_id='default', extra=''),
SystemActivity(timestamp='2025-12-15T13:42:41', org_id='', user='', kind='user', feature='role', action='create', resource_id='', extra=''),
SystemActivity(timestamp='2025-12-15T13:42:41', org_id='', user='', kind='user', feature='role', action='create', resource_id='', extra='')]