Customer Knowledge Base
Breadcrumbs

Milesight - Application & Device Debugging Training Module

image-20260203-111344.png

Milesight Development Platform


📋 Module Overview

Duration: ~7 minutes
Level:Intermediate
Prerequisites:Basic understanding of IoT platforms and API concepts

This training module is designed as a follow-along guide to the "Application & Device Debugging of Milesight Development Platform" video. Use this document alongside the video to maximize your learning experience.

Video Link: Watch The Full Demo Training Video

NOTE:
If you want to watch the video while following along with the training notes, then right click and open the video in a new split screen window and the video should appear on the right of this training guide, so that you can follow along.


🎯 Learning Objectives

By the end of this module, you will be able to:

  • Configure data storage settings for effective debugging

  • Create and manage demo devices in the Application module

  • Use the Device Simulation Panel to test data communication

  • Debug OpenAPI calls using the visual interface

  • Simulate and validate Webhook pushes


Chapter 1: Demo Devices Management & Device Simulation Panel

Video Timeline: 0:11 - 4:42

1.1 Initial Platform Setup (0:17 - 0:36)

Before you begin working with the Application module, you need to configure your platform's data storage settings.

⚠️ Important Setup Step:

By default, the Milesight Development Platform does not retain device-reported data. To facilitate debugging:

  1. Navigate to Platform Settings

  2. Locate Data Storage Settings

  3. Set data retention to 1 day (recommended for debugging)

![Screenshot: Platform Settings - Data Storage Configuration]

📚 Related Documentation: Platform Settings Guide


1.2 Application Module Overview (0:36 - 1:06)

The Application module provides three key capabilities:

  • Third-party Integration - Connect external applications

  • Device Simulation - Test without physical hardware

  • API & Webhook Debugging - Validate integration features

Navigation:

  • Use the left menu to create new applications or review existing ones

  • Select an application to view comprehensive details in the middle area

![Screenshot: Application Module Navigation]

📚 Related Documentation: Application Module Overview


1.3 Application Settings (1:07 - 1:14)

Under the Application Settings tab, you'll find:

  • Basic settings for the selected application

  • Authorization information

  • Configuration options

![Screenshot: Application Settings Tab]


1.4 Adding Demo Devices (1:15 - 1:58)

Demo devices allow you to test functionality without physical hardware.

Steps to Add a Demo Device:

  1. Click the Application Devices tab

  2. Click "Add A Demo Device"

  3. In the pop-up window, review device information (left to right):

    • Product image

    • Product name

    • Profile version

    • TSL version

  4. Select your desired device model

  5. Confirm the addition

Result: Demo devices are automatically associated with the current application.

![Screenshot: Add Demo Device Dialog]

📚 Related Documentation: Device Models & TSL Reference


1.5 Managing Application Devices (1:59 - 2:18)

Viewing Devices:

  • All devices appear on the Application Devices page

  • Demo devices display a [Simulate] label on the device card

Removing Demo Devices:

Method 1: Click the top-right corner of the device card → Select "Remove from the Application"

Method 2: Select the device card → Click "Remove Device" button

![Screenshot: Application Devices Page with Demo Device Labels]


1.6 Device Simulation Panel (2:19 - 3:30)

The Device Simulation Panel is your primary tool for testing data communication between devices and the platform.

Accessing the Panel:

  • Option 1: Navigate through the main interface

  • Option 2: Click the floating button at the bottom-right corner

Supported Device Types:

  • ✅ Real devices

  • ✅ Demo devices

![Screenshot: Device Simulation Panel Interface]

Panel Layout:

Section

Function

Left Panel

Select device for debugging

Middle Section

Display available simulation/debugging data

Right Panel

Show reported data and raw Payload


1.7 Simulating Data Reports (2:56 - 3:30)

The simulation demonstrates device-to-platform communication.

Report Types Supported:

  • Telemetry data

  • Alarm events

Random Report Feature:

  1. Click "Random Report"

  2. System generates a random value within the defined data range

  3. Data is submitted as a report

  4. Triggers webhook to push data to configured endpoints

Viewing Results:

  • Right-side dialog displays:

    • Reported data (decoded)

    • Raw Payload data (undecoded)

![Screenshot: Random Report Execution and Results]


1.8 Custom Reporting (3:30 - 3:50)

For more control over test data, use Custom Report.

How to Use Custom Report:

  1. Copy the undecoded raw Payload data from a previous Random Report

  2. Paste into Custom Report field

  3. Ensure the decoded JSON matches the Random Report format

  4. Submit the custom report

💡 Tip: This is useful for testing specific edge cases or reproducing specific data scenarios.

![Screenshot: Custom Report Interface]


1.9 Simulation Send (3:51 - 4:42)

Simulation Send reverses the communication flow: platform → device.

Random Send Capabilities:

Service Functions:

  • Invoke device features and services

  • Test device responses to platform commands

Configure Settings:

  • Set device parameters

  • Modify device configuration

Example Demonstration (4:25 - 4:41):

The video demonstrates modifying a device's data reporting interval:

  1. Navigate to Configure settings

  2. Set "reporting cycle" parameter to 30 seconds

  3. Click Random Send

  4. System generates a random value within defined range

  5. Value is sent to device as configuration parameter

![Screenshot: Simulation Send - Configure Settings]

📚 Related Documentation: Device Services & Configuration Reference


Chapter 2: OpenAPI Debugging

Video Timeline: 4:42 - 6:12

2.1 OpenAPI Debugging Overview (4:54 - 5:01)

OpenAPI Debugging provides a visual interface for testing API calls without writing code.

Key Features:

  • Visual interface for all supported APIs

  • Automatic CURL command generation

  • Real-time response validation

![Screenshot: OpenAPI Debugging Interface]


2.2 Exporting API Documentation (5:01 - 5:14)

Export Steps:

  1. Click the Export/Download button

  2. Download the OpenAPI documentation

  3. Documentation is Swagger-compatible

Use Cases:

  • Import into API testing tools (e.g., Postman, Insomnia)

  • Share with development team

  • Reference for integration development

![Screenshot: Export OpenAPI Documentation Button]

📚 Related Documentation: Complete OpenAPI Reference


2.3 Using the Debug Panel (5:21 - 5:38)

Workflow:

  1. Select an interface from the available list

  2. View the parameter table in the Debug Panel

  3. Fill in required parameters

  4. System auto-generates a CURL command

  5. Copy CURL command for use in API testing tools

💡 Pro Tip: The CURL command includes your credentials automatically, making it ready for immediate testing.

![Screenshot: Debug Panel Parameter Table]


2.4 Practical Example: Historical Data Inquiry (5:39 - 6:12)

Scenario: Query historical device data

Steps Demonstrated:

  1. Select the historical data inquiry endpoint

  2. Input required parameters (device ID, time range, etc.)

  3. Execute the API call

  4. Review the response

Response Validation:

  • The response matches data from recent Random Reports

  • Confirms successful data storage and retrieval

Debug Information Available:

  • Request content (what was sent)

  • Response results (what was received)

  • Status codes

  • Execution time

![Screenshot: Historical Data Query Results]

📚 Related Documentation: Data Query API Guide | Timestamp Formatting


Chapter 3: Webhook Simulation

Video Timeline: 6:12 - 6:55

3.1 Webhook Simulation Overview (6:16 - 6:33)

Webhooks enable real-time data pushing to external systems. The Webhook Simulation page helps you test this functionality.

What's Displayed:

  • Recorded Webhook push data

  • Push content

  • Push results (success/failure)

⚠️ Important Configuration:

Webhook data is only recorded and displayed when the recording switch is turned ON.

![Screenshot: Webhook Simulation Page with Recording Switch]

📚 Related Documentation: Webhook Configuration Guide | Webhook Payload Formats


3.2 Testing Temperature & Humidity Data (6:34 - 6:55)

Practical Test Scenario:

  1. Select a device in the Device Simulation Panel

  2. Click Random Report for temperature and humidity data

  3. Navigate to Webhook Simulation page

  4. Observe two new records appear in the list

Validation:

  • Data values in Webhook records match Device Simulation Panel

  • Confirms webhook trigger on data report

  • Verifies data consistency across platform

![Screenshot: Webhook Records Showing Temperature and Humidity Data]

💡 Use Case: This validation is crucial for:

  • Testing integration with third-party systems

  • Ensuring data reaches external applications

  • Debugging webhook configuration issues

📚 Related Documentation: Troubleshooting Webhook Failures


📝 Practice Exercises

Exercise 1: Complete Device Simulation Workflow

  1. Create a demo device for temperature monitoring

  2. Use Random Report to generate 5 data points

  3. Verify data appears in historical records using OpenAPI debugging

Exercise 2: Custom Scenario Testing

  1. Create a custom report with specific temperature value (e.g., 25°C)

  2. Configure device reporting interval to 60 seconds using Simulation Send

  3. Verify webhook receives the data correctly

Exercise 3: API Integration Preparation

  1. Export OpenAPI documentation

  2. Import into Postman or similar tool

  3. Execute at least 3 different API calls successfully


🔗 Additional Resources

Video Resources


💬 Support & Feedback

Need Help?

  • Contact the Milesight technical team

  • Submit questions through the support portal

  • Join the developer community forum

Enjoyed This Module?

  • 👍 Like the video

  • 📺 Subscribe for more Milesight Development Platform content

  • 💬 Share your thoughts and comments


✅ Knowledge Check

Test your understanding:

  • [ ] Can you explain the difference between Random Report and Custom Report?

  • [ ] What are the two methods for removing a demo device?

  • [ ] Why is it important to enable data storage settings before debugging?

  • [ ] What information does the Device Simulation Panel display in its three sections?

  • [ ] How do you export OpenAPI documentation for use in Postman?

  • [ ] What must be turned ON to record Webhook push data?


📌 Quick Reference Card

Task

Location

Key Action

Enable data storage

Platform Settings

Set to 1 day

Add demo device

Application Devices tab

Click "Add A Demo Device"

Open simulation panel

Bottom-right corner

Click floating button

Random device report

Device Simulation Panel

Select device → Random Report

Configure device

Simulation Send section

Modify parameters → Send

Test API call

OpenAPI Debugging

Select endpoint → Fill parameters

Export API docs

OpenAPI Debugging

Click export button

View webhook pushes

Webhook Simulation

Enable recording switch


Module Version: 1.0
Last Updated:February 2026
Compatible with:Milesight Development Platform (Latest Version)


Stay tuned for more training modules on the Milesight Products!


Presenter: Milesight
Series:Milesight IoT

YouTube: @MilesightIoT

image-20260203-111805.png

milesight.com