GET /plans/{accountname}
Returns a list of all data service plans that are associated with a specified billing account. When you send a request to /devices/actions/activate to activate a line of service you must specify the code for one of the service plans associated with your account.
GET https://thingspace.verizon.com/api/m2m/v1/plans/{accountname}
You must include the account name in the path.
Parameter Name | Data Type | Description |
---|---|---|
Parameter Nameaccountname required |
Data Typestring | DescriptionThe name of the account for which a list of service plans will be returned. An account name is usually numeric, and must include any leading zeros. |
The request header must contain a current ThingSpace authorization bearer token and a valid VZ-M2M session token, and must set the content-type to JSON.
Parameter Name | Data Type | Description |
---|---|---|
Parameter NameAuthorization required |
Data Typestring | DescriptionHTTP Authorization bearer token. |
Parameter NameVZ-M2M-Token required |
Data Typestring | DescriptionA valid session token returned by POST /session/login. |
Parameter NameContent-Type required |
Data Typestring | DescriptionMust be application/json . |
None.
Status 200 A successful request returns an array of servicePlan objects that contain these values:
Parameter Name | Data Type | Description |
---|---|---|
Parameter Namename | Data Typestring | DescriptionThe name of the service plan. |
Parameter Namecode | Data Typestring | DescriptionThe code of the service plan, which may not be the same as the name. |
Parameter NamesizeKb | Data Typeint64 | DescriptionThe size of the service plan in kilobytes. |
Parameter NamecarrierServicePlanCode | Data Typestring | DescriptionThe code that is used by the carrier for the service plan. |
Parameter NameextendedAttributes | Data Type | DescriptionAny extended attributes for the service plan, as Key and Value pairs. |
Parameter Name key | Data Typestring | DescriptionThe key for an extended attribute. |
Parameter Name value | Data Typestring | DescriptionThe value of an extended attribute. |
[
{
"name": "2MSHR5GB",
"code": "M2MSHR5GB",
"sizeKb": 0,
"carrierServicePlanCode": "84638"
},
{
"name": "TNTL200TALK",
"code": "NTL200TALK",
"sizeKb": 0,
"carrierServicePlanCode": "74644"
},
{
"name": "TNTL300SHR",
"code": "NTL300SHR",
"sizeKb": 0,
"carrierServicePlanCode": "85135"
},
{
"name": "2M250MB",
"code": "M2M250MB",
"sizeKb": 0,
"carrierServicePlanCode": "84641"
}
]
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.