Telemetry in Action 🧐: Track User Activities in BC 🔍(English version)
Telemetría en Acción 🧐: Rastrea las Actividades de los Usuarios en BC🔍
Tenemos algunas funcionalidades que nos permiten identificar operaciones diarias de los usuarios dentro de Business Central, como lo son:
- Monitorizar las conexiones de usuarios: User Permissions and Security in Business Central – Business Central | Microsoft Learn
- Análisis del Registro de Cambio: El registro de cambios permite realizar un seguimiento de todas las modificaciones directas que realiza un usuario a los datos de la base de datos. Auditing changes – Business Central | Microsoft Learn
- Supervisar los cambios de los campos confidenciales: Para agregar una capa de seguridad, puede monitorear campos importantes y recibir un correo electrónico cuando alguien cambia un valor. Monitor sensitive fields – Business Central | Microsoft Learn
Adicionalmente, tenemos la posibilidad de apoyarnos en la telemetría, ya que, existen algunos eventos que nos permiten seguir los movimientos de los usuarios en Business Central, como los siguientes:
- Page View Telemetry (CL0001) Se produce cuando se ha abierto una página en el cliente: Page View Telemetry – Business Central | Microsoft Learn
- Client action telemetry (CL0003) La telemetría de acciones del cliente recopila datos sobre las acciones que los usuarios seleccionan en las páginas del cliente Business Central, como UI.AnalysisMode.Disabled or UI.AnalysisMode.Enabled. Analyzing client action telemetry – Business Central | Microsoft Learn
- Authorization Trace Telemetry (RT0002, RT0004) La telemetría de autorización proporciona información sobre la autorización de los usuarios (o servicios) cuando intentan iniciar sesión en Business Central. Authorization Trace – Business Central | Microsoft Learn
- Report Telemetry (RT0006, RT0007, RT0011) La telemetría de informes recopila datos sobre los informes que se ejecutan en el entorno. Proporciona información sobre si el informe se ejecutó correctamente, falló o se canceló. Report Generation Telemetry – Business Central | Microsoft Learn
- Field Monitoring Telemetry (AL0000CTE, AL0000DD3, AL0000EMW) Para añadir una capa de seguridad, puede supervisar campos importantes cuando alguien modifica un valor. Analyzing Field Monitoring Telemetry – Business Central | Microsoft Learn
Las siguientes sentencias nos ayudarán a obtener las actividades realizadas por un usuario (user_ID), en una empresa determinada (companyName) y en una fecha y rango de horas determinadas (timestamp).
traces
| where datetime_utc_to_local(timestamp, 'Europe/Madrid') between(datetime('2025-03-24T00:00:00.000')..datetime('2025-03-28T23:59:00.000'))
| where customDimensions.eventId in ('CL0003','RT0002','RT0004','RT0003','RT0006','RT0007','RT0011','AL0000CTE','AL0000DD3','AL0000EMW')
| where user_Id == 'userguid'
| where customDimensions.clientType == 'WebClient'
| where customDimensions.companyName == 'company'
| project
timestamp
,message
,customDimensions.eventId
,customDimensions.alObjectId
,customDimensions.alObjectName
,customDimensions.companyName
,customDimensions.clientType
,user_Id
,customDimensions
| order by timestamp
pageViews
| where datetime_utc_to_local(timestamp, 'Europe/Madrid') between(datetime('2025-03-24T00:00:00.000')..datetime('2025-03-28T23:59:00.000'))
| where customDimensions.eventId == 'CL0001'
| where user_Id == 'userguid'
| project
timestamp
,name
,customDimensions.eventId
,customDimensions.alObjectId
,customDimensions.alObjectName
,customDimensions.hostType
,customDimensions.clientType
,user_Id
,customDimensions
| order by timestamp
Adicionalmente, a los eventos de telemetría mencionados anteriormente, no nos olvidemos de los eventos de telemetría personalizados, los cuales usamos en nuestras extensiones. Es decir, podríamos crear eventos de telemetría para que identifiquemos lo que hace un usuario en nuestra solución.
- Analize your extensions through custom telemetry – Gerardo Rentería Blog
- Creating custom telemetry events for Azure Application Insights – Business Central | Microsoft Learn
- Custom Telemetry | alguidelines.dev – Business Central Design Patterns
traces
| where datetime_utc_to_local(timestamp, 'Europe/Madrid') between(datetime('2025-03-24T00:00:00.000')..datetime('2025-03-28T23:59:00.000'))
| where user_Id == 'userguid'
| where customDimensions.eventId contains "GDRGDev_CustomTelemetry"
| order by timestamp
De todas maneras, extraño algunos eventos de telemetría adicionales que complementarían positivamente la traza de las operaciones de un usuario dentro de Business Central, estos son:
- Nuevos eventos relacionados con el seguimiento de la ejecución de las consultas (como los eventos de generación de informes RT0006, RT0007, RT0011).
- Nuevo evento relacionado con el cierre de la página.
- Nuevo evento o reutilizar el evento CL0003 para rastrear la ejecución de las acciones de la página. Es decir, por ejemplo, cuando un usuario presiona un botón.
Es por eso, que he agregado esta idea en el portal de Ideas de Dynamics 365, si te parece interesante te invito a votar por el mismo.
Espero que esta información te ayude.
Telemetry in Action 🧐: Track User Activities in BC 🔍
We have some features that allow us to identify the daily operations of users within Business Central, such as:
- Monitor user connections: User Permissions and Security in Business Central – Business Central | Microsoft Learn
- Change Log Analysis: The change log allows tracking of all direct modifications made by a user to database data. Auditing changes – Business Central | Microsoft Learn
- Monitor changes in sensitive fields: To add a layer of security, you can monitor important fields and receive an email when someone changes a value. Monitor sensitive fields – Business Central | Microsoft Learn
Additionally, we have the ability to rely on telemetry, as there are certain events that allow us to track user activities in Business Central, such as the following:
- Page View Telemetry (CL0001) Triggered when a page is opened in the client. Page View Telemetry – Business Central | Microsoft Learn
- Client action telemetry (CL0003) Captures data on actions users select on Business Central client pages, such as UI.AnalysisMode.Disabled or UI.AnalysisMode.Enabled. Analyzing client action telemetry – Business Central | Microsoft Learn
- Authorization Trace Telemetry (RT0002, RT0004) Provides information on user (or service) authorization attempts when logging into Business Central. Authorization Trace – Business Central | Microsoft Learn
- Report Telemetry (RT0006, RT0007, RT0011) Report telemetry collects data on reports executed within the environment. It provides information on whether the report was successfully executed, failed, or was canceled. Report Generation Telemetry – Business Central | Microsoft Learn
- Field Monitoring Telemetry (AL0000CTE, AL0000DD3, AL0000EMW) To add an extra layer of security, you can monitor critical fields when someone modifies a value. Analyzing Field Monitoring Telemetry – Business Central | Microsoft Learn
The following queries will help us obtain the activities performed by a user (user_ID) within a specific company (companyName) and during a given date and time range (timestamp).
traces
| where datetime_utc_to_local(timestamp, 'Europe/Madrid') between(datetime('2025-03-24T00:00:00.000')..datetime('2025-03-28T23:59:00.000'))
| where customDimensions.eventId in ('CL0003','RT0002','RT0004','RT0003','RT0006','RT0007','RT0011','AL0000CTE','AL0000DD3','AL0000EMW')
| where user_Id == 'userguid'
| where customDimensions.clientType == 'WebClient'
| where customDimensions.companyName == 'company'
| project
timestamp
,message
,customDimensions.eventId
,customDimensions.alObjectId
,customDimensions.alObjectName
,customDimensions.companyName
,customDimensions.clientType
,user_Id
,customDimensions
| order by timestamp
pageViews
| where datetime_utc_to_local(timestamp, 'Europe/Madrid') between(datetime('2025-03-24T00:00:00.000')..datetime('2025-03-28T23:59:00.000'))
| where customDimensions.eventId == 'CL0001'
| where user_Id == 'userguid'
| project
timestamp
,name
,customDimensions.eventId
,customDimensions.alObjectId
,customDimensions.alObjectName
,customDimensions.hostType
,customDimensions.clientType
,user_Id
,customDimensions
| order by timestamp
Additionally, beyond the previously mentioned telemetry events, let’s not forget about custom telemetry events, which we use in our extensions. This means we could create telemetry events to identify what a user is doing within our solution.
- Analize your extensions through custom telemetry – Gerardo Rentería Blog
- Creating custom telemetry events for Azure Application Insights – Business Central | Microsoft Learn
- Custom Telemetry | alguidelines.dev – Business Central Design Patterns
traces
| where datetime_utc_to_local(timestamp, 'Europe/Madrid') between(datetime('2025-03-24T00:00:00.000')..datetime('2025-03-28T23:59:00.000'))
| where user_Id == 'userguid'
| where customDimensions.eventId contains "GDRGDev_CustomTelemetry"
| order by timestamp
In any case, I miss some additional telemetry events that would positively complement the trace of a user’s activities within Business Central. These are:
- A new event or reuse event CL0003 to track the execution of page actions—for example, when a user presses a button.
- New events related to tracking query execution (such as report generation events RT0006, RT0007, RT0011).
- A new event related to page closing.
That is why I have added this idea to the Dynamics 365 Ideas portal. If you find it interesting, I invite you to vote for it.
I hope this information helps you.
Más información / More information:



Deja un comentario