All Collections
User Guides
Devices Types: Bulk device creation using a CSV file
Devices Types: Bulk device creation using a CSV file

Create Devices in bulk simply with a CSV file containing Device Names, API Labels, and Properties.

David Sepúlveda avatar
Written by David Sepúlveda
Updated over a week ago

Device Types are a great way to streamline large-scale deployments by quickly on-boarding hundreds or thousands of Devices in Ubidots. Not only will Device Types pre-configure the Properties, Variable Names, Icons and Synthetic Expressions of newly detected devices, but they also allow you to upload hundreds or thousands of devices with nothing more than a CSV file.

As an example, imagine you need to onboard 500 new devices for a service button application across 500 different locations. Using Device Type you can create these 500 devices in one fell swoop using a CSV containing some parameters:

  • Device Name (required)

  • Device Label (required)

  • Restaurant name (property entry)

  • Restaurant address (property entry)

  • Phone number (property entry)

1. Creating Devices in Bulk with a CSV Upload

To create devices in bulk using a CSV upload, simply follow the 7 Steps below.

  • Step 1: Create a new Device Type or locate a preexisting Device Type.

  • Step 2: Click on the device type settings and select the “Bulk upload devices” icon from the newly created or already existing Device Type.

  • Step 3: Click "Download template CSV file" to configure the CSV Device Template Upload for bulk creation. This file will contain the following empty columns requiring inputs:

  1. Device name (required): The name you wish to assign to your device

  2. Device Label (required): The device API label - a unique identifier for your device (being unique, please ensure that no two device Labels are the same.)

  3. Description (optional): An optional description for your device

  4. Tags (optional): A comma-separated list of tags for your device. Example: "button, restaurant, iot"

  5. _lat and _lng (optional): For stationary devices (i.e. a fixed-location smart button or weather station) you can provide latitude and longitude in degrees. Accepted range for latitude is between -90 and 90. Accepted range for longitude is between -180 and 180

  6. Properties (optional): The properties of your device type, so you can fill them at will according to your IoT application. learn more about device properties

  • Step 4: Configure your CSV file with the desired values. Following our example, let's use the CSV file to create ten (10) smart buttons, each with predefined configurations.

  • Step 5: With the configuration in the CSV complete, click on "Drop the CSV file here, or click to select one" to verify the file contents. You have the option to run device tasks configured during the creation.

If the file verification is successful, you will see a check mark next to the file name:

  • Step 6: Click on the green icon in the lower right corner to Bulk create the designated devices from the CSV uploaded file.

2. Results 

A blank device skeleton will be created according to the CSV parameters defined for each valid row in your CSV file:

IMPORTANT NOTE: In your devices' firmware, make sure to use the corresponding device API Label to send data to the right device.

Once created, your devices will contain the name, API label, location and properties specified in the CSV file:

Did this answer your question?