Agent Wranglers

IOT-44Recommended

Let owners read their device's data directly

Design every model so its owner can fetch the data it creates, with its metadata, in a documented machine-readable format at no charge. Offer it from the device or the app without a support request.

How to do it

Owners want to move to another app, check what the device recorded, or feed a home system. Build the export path into the first firmware and cloud API, since adding it later means a new data model. Use the fields from list every sensor and every field that leaves the device, so the export covers everything you collect. A local API on the device also keeps it useful when the cloud ends. In the EU, the Data Act asks this by design of products placed on the market after 12 September 2026. See give users the data from connected products. The account export itself follows self-service export.

Examples

Python example

def export_problems(export: dict, field_list: set[str]) -> list[str]:
    exported = {field for reading in export["readings"] for field in reading}
    return [f"field {name} is collected but not exported" for name in sorted(field_list - exported)]

Go example

func ExportProblems(readings []map[string]any, fieldList []string) []string {
	exported := map[string]bool{}
	for _, reading := range readings {
		for name := range reading {
			exported[name] = true
		}
	}
	var problems []string
	for _, name := range fieldList {
		if !exported[name] {
			problems = append(problems, "field "+name+" is collected but not exported")
		}
	}
	return problems
}

How to check

A test asks for the export of a test device and parses it against the published schema. Every field in the model's field list appears in it. The request needs no payment and no support ticket.

Sources

For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/connected-devices/sensor-data-and-privacy/owner-data-access">Agent Wranglers connected devices playbook</a>. In code you write, add a comment next to it with the same link.