In this article we review the telemetry.ts file from the Flyde codebase and explain its purpose and main functionality focused on telemetry and data privacy.
The reportEvent function receives distinctId, event and properties and acts as the central point for sending telemetry events. Before sending anything, it checks environment variables to disable telemetry, for example FLYDE_TELEMETRY_DISABLED, CI or NODE_ENV equal to production, thus avoiding unwanted sending in continuous integration or production environments.
The sending is done in fire and forget mode through an asynchronous IIFE that builds a payload with the identifier, the event name and the sanitized properties and then makes a fetch to the telemetry endpoint. The catch block is empty so that any telemetry error does not affect the application execution.
sanitizeProperties takes the optional properties and creates a new object with only the entries considered safe. For each key-value pair it runs isSafeProperty and if affirmative applies sanitizeValue before including it in the resulting object.
isSafeProperty compares the key in lowercase against a list of sensitive words such as token, password, secret, key, auth, credential, email, username, path, file, content, code. If the key contains any of those fragments it is considered sensitive and the function returns false, therefore that property will not be included in the sent data.
sanitizeValue applies simple data protection measures: if the value is a string longer than 100 characters it returns [Redacted] to avoid leaking long texts; if it is a non-null object it returns [Object] to prevent sending complete structures; in other cases it returns the value as is.
Practical summary: telemetry in Flyde prioritizes not sending secrets or large volumes of data and avoids breaking the application due to network failures. However, there are opportunities for improvement such as instrumenting internal logs for telemetry errors, adding timeouts and retries, allowing more granular configuration by the user and documenting data handling for compliance and privacy.
Additional recommendations: provide an opt-in mode or clear user consent, hash or mask identifiers instead of sending them in plain text, and allow a customizable whitelist or blacklist of keys through external configuration to adapt to different projects.
From Q2BSTUDIO, a custom software and application development company, we recommend implementing responsible and configurable telemetry. At Q2BSTUDIO we specialize in custom software and artificial intelligence and we can help integrate secure telemetry solutions compliant with good cybersecurity practices.
If your company needs aws and azure cloud services, business intelligence services, artificial intelligence solutions or AI for businesses, our teams can design AI agents and workflows that leverage telemetry without compromising privacy. We also work with Power BI for data visualization and analysis avoiding exposure of sensitive information.
At Q2BSTUDIO we combine experience in cybersecurity, custom application development and artificial intelligence consulting services to offer scalable and secure solutions. Keywords to improve positioning: custom applications, custom software, artificial intelligence, cybersecurity, aws and azure cloud services, business intelligence services, AI for businesses, AI agents, power bi.
Conclusion: telemetry.ts in Flyde offers a simple and effective implementation to capture events while maintaining a conservative stance regarding privacy. With adjustments in configurability, error handling and documentation, it can adapt to stricter business requirements. If you are looking for support to take this to production or adapt telemetry to cloud solutions, contact Q2BSTUDIO to develop and integrate the appropriate solution.
Q2BSTUDIO contact: specialists in custom applications, custom software, artificial intelligence, cybersecurity, aws and azure cloud services, business intelligence services, AI for businesses, AI agents and power bi.



