POST /files/{acc}
Uploads a configuration/supplementary file for an account. ThingSpace generates a fileName after the upload and is returned in the response. You will use the generated file name when listing or scheduling a campaign for the file.
When uploading a configuration file, ThingSpace Software Management requires metadata about the file including the version, make, and model.
Support of this feature requires explicit direction from the Device OEM who is responsible for providing templates and documentation for the files. ThingSpace Software Management acts as a delivery mechanism of the file and is not responsible for any misconfiguration done to the device. Please do not use this feature if your OEM has not instructed you on how to do it.
Once the file has been uploaded, scheduling a file campaign follows a similar model of scheduling a software campaign.
See also:
Get a List of Available Files
Schedule a File Upgrade
POST https://thingspace.verizon.com/api/fota/v2/files/{acc}
Parameter Name | Data Type | Description |
---|---|---|
acc required |
string | Account identifier. |
The request header must contain a current ThingSpace authorization token and a current VZ-M2M-session token.
Parameter Name | Data Type | Description |
---|---|---|
Authorization required |
string | HTTP Authorization request header containing a valid Bearer token. |
VZ-M2M-Token required |
string | A valid session token returned by a Connectivity Management POST /session/login request. |
Parameter Name | Data Type | Description |
---|---|---|
fileupload required |
file | The file to upload. |
fileVersion required |
string | Version of the file. |
make required |
string | The software-applicable device make. |
model required |
string | The software-applicable device model. |
localTargetPath required |
string | Local target path on the device. |
Request a software upgrade.
curl --location --request POST 'https://thingspace.verizon.com/api/fota/v2/files/$ACC/' \
--header 'VZ-M2M-Token: $M2M_TOKEN' \
--header 'Authorization: Bearer $AUTH_TOKEN' \
--form 'fileupload=@"/Users/files/hello-world.txt"' \
--form 'fileVersion="1.0"' \
--form 'make="Verizon"' \
--form 'model="VZW1"' \
--form 'localTargetPath="/VZWFOTA/hello-world.txt"' \
--form 'releaseNote="Hello world initial file"'
Status 200
Parameter Name | Data Type | Description |
---|---|---|
fileName required |
string | ThingSpace-generated name of the file. You will use this name when listing or scheduling campaigns for the file. |
fileVersion required |
string | Version of the file. |
launchDate | string($date-time) | Software launch date. |
releaseNote required |
string | Software release note. |
make required |
string | The software-applicable device make. |
model required |
string | The software-applicable device model. |
localTargetPath required |
string | Local target path on the device. |
distributionType | string | Valid values include:
|
devicePlatformId required |
string | The platform (Android, iOS, etc.,) that the software can be applied to. |
{
"fileName": "configfile-Verizon_VZW1_hello-world.txt",
"fileVersion": "1.0",
"releaseNote": "Hello world initial file",
"make": "Verizon",
"model": "VZW1",
"localTargetPath": "/VZWFOTA/hello-world.txt",
"distributionType": "HTTP",
"devicePlatformId": "IoT"
}
Status 400
All error messages are returned in this format:
{
"errorCode": "error code string",
"errorMessage": "error message string"
}
Error codes and messages are listed on the Error Messages page, along with explanations and suggestions for corrective actions.