Get Upgrade Information

Get Upgrade Information

GET /campaigns/{acc}/{campaignId}

Returns information about a specified upgrade, including the target date of the upgrade.

Uses and Requirements

The upgrade states are listed as follows:

  • CampaignRequestPending: The upgrade request has been accepted but is not scheduled yet.
    • If any parameter checks fail, the state changes to CampaignRequestFailed.
  • CampaignQueued: The upgrade request has passed a campaign eligibility check and campaign parameters validation. The upgrade is in the queue waiting to be scheduled.
    • You can cancel the campaign if it is in Queued status and if it is before the Start Date, which becomes CampaignCancelled state.
    • You can delete the campaign after the start date, which becomes CampaignAborted state.
  • CampaignFailed: The campaign scheduling API call has failed.
  • CampaignScheduled: The upgrade is scheduled. This appears before the campaign start date.
    • After the start date has passed and the upgrade is in progress you can abort the campaign. Some devices may have already started or completed the upgrade. Upgrades on remaining devices might not complete the upgrade.
  • CampaignEnded: The campaign end date has passed. No more devices are allowed to upgrade if they have checked in before the campaign end date.

Request Components

HTTP Request

GET https://thingspace.verizon.com/api/fota/v3/campaigns/{acc}/{campaignId}

Resource Path Parameters

Parameter Name Data Type Description
acc
required
string The billing name of the account. An account name is usually numeric, and must include any leading zeros.
campaignId
required
string Software upgrade identifier, returned in the "id" value of the POST /{campaigns}/acc response when the upgrade was scheduled.

Header Parameters

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.

Request Body

None

Example Request

Request a software upgrade.

curl https://thingspace.verizon.com/api/fota/v3/campaigns/$ACC/$CAMPAIGN_ID -H 'Authorization: Bearer $AUTH_TOKEN' -H 'VZ-M2M-Token: $M2M_TOKEN' -H 'Content-Type: application/json' -d

Success Responses

Status 200

tr>

Parameter Name Data Type Description
id string The campaign name.
accountName
string The ThingSpace billing account number
campaignName string The campaign name.
firmwareName string The name of the firmware to which you are upgrading.
protocol string The protocol of the firmware distribution. 
  • LWM2M
make string FOTA make of the device.
model string FOTA model of the device.
firmwareFrom string The name of the old firmware on the device.
firmwareTo string The name of the new firmware to which you are upgrading.
startDate string($date) Campaign start date.
endDate string($date) Campaign end date.
campaignTimeWindowList array  
   startTime
   required
integer Start hour in range [0-23], current hour >= startTime. When the current hour falls between the startTime and the endTime, it starts.
   endTime
   required
integer End hour in range [1-24], current hour < endTime. The endTime must be at least 4 hours after the startTime.
status string Campaign level status.

Example Success Response

{
    "id": "f858b8c4-2153-11ec-8c44-aeb16d1aa652",
    "accountName": "0642233522-00001",
    "campaignName": "Smart FOTA - test 4",
    "protocol": "LWM2M",
    "make": "SEQUANS Communications",
    "model": "GM01Q",
    "status": "CampaignPreScheduled",
    "startDate": "2021-09-29",
    "endDate": "2021-10-01",
    "firmwareName": "SEQUANSCommunications_GM01Q_SR1.2.0.0-10512_SR1.2.0.0-10657",
    "firmwareFrom": "SR1.2.0.0-10512",
    "firmwareTo": "SR1.2.0.0-10657",
    "timeWindowList": [
        {
            "startTime": 18,
            "endTime": 22
        }
    ]
}

Failure Responses

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.