Sample API Codes for Device Management