Premium APIsSoftware ManagementSoftware Management V1API Reference V1

Get the subscription status

Retrieve an account’s subscription status

GET /subscriptions/{account}

Returns information about an account’s Software Management Services subscription status.

Request Components

HTTP Request

GET https://thingspace.verizon.com/api/fota/v1/subscriptions/{account}

Resource Path and Query Parameters

You must include the account name in the path.

Parameter NameData TypeDescription
account (required)stringThe name of the account for which you want the Software Management Services subscription status. An account name is usually numeric, and must include any leading zeros.

Header Parameters

The request header must set the content-type to JSON, contain a current ThingSpace authorization token and a current VZ-M2M session token. For more details on how to get these tokens, visit Getting Started.

Parameter NameData TypeDescription
Authorization (required)stringHTTP Authorization bearer token: Authorization: Bearer {token}
VZ-M2M-Token (required)stringA valid session token: VZ-M2M-Token: {M2Mtoken}
Content-Type (required)stringMust be application/json Content-Type: application/json

Request Body

None.

Example Request

Request the subscription status for an account:

curl https://thingspace.verizon.com/api/fota/v1/subscriptions/$ACCOUNT -H 'Authorization: Bearer $AUTH_TOKEN' -H 'VZ-M2M-Token: $M2M_TOKEN'

Success Responses

Status 200

A success response includes the type of Software Management Services subscription, the number of total licenses (if applicable), and the registered callback endpoint.

Parameter NameData TypeDescription
accountNamestringThe name (number) of the billing account.
purchaseTypestringComma-separated list of subscription models used by the account: TS-HFOTA-MRC - a monthly recurring contract for a fixed number of licenses; TS-HFOTA-EVNT - a post-pay plan in which the account is billed for the number of licenses used in each month (the number of events); both of the above
licenseCountintegerThe number of monthly licenses in an MRC subscription. This will be zero for accounts that only have Event subscriptions.
licenseUsedCountintegerThe number of licenses currently assigned to devices.
updateTimestringThe date and time of when the subscription was last updated.

Example Success Response

{  
  "accountName":"0402196254-00001",
  "purchaseType": "TS-HFOTA-EVNT,TS-HFOTA-MRC",
  "licenseCount": 9000,
  "licenseUsedCount": 1000,
  "updateTime": "2018-03-02 19:50:06.534 +0000 UTC"
}

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.

On this page