GET /groups/{accountname}/name/{gname}
Returns the name, description, and list of devices in a device group.
See also:
Get a List of Device Groups
Update a Device Group
Create a Device Group
Delete a Device Group
GET https://thingspace.verizon.com/api/m2m/v1/groups/{accountname}/name/{gname}?next={deviceId}
You must specify the account name and group name in the resource path.
Parameter Name | Data Type | Description |
---|---|---|
Parameter Nameaccountname required |
Data Typestring | DescriptionThe name of the account that contains the device group. An account name is usually numeric, and must include any leading zeros. |
Parameter Namegname required |
Data Typestring | DescriptionThe name of the device group. |
Parameter Namenext optional |
Data Typeint64 | Description(Output paging parameter) Only return information about devices that have an ID greater than this value.
|
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 or 202 The devices in a device group are returned sorted by device ID, with the smallest ID first.
Parameter Name | Data Type | Description |
---|---|---|
Parameter Namename | Data Typestring | DescriptionThe name of the device group. |
Parameter Namedescription | Data Typestring | DescriptionThe description of the device group. |
Parameter Namedevices | Data TypeArray of deviceIds objects | DescriptionThe devices in the device group. |
Parameter Name kind | Data Typestring | DescriptionThe type of the device identifier. |
Parameter Name id | Data Typestring | DescriptionThe value of the device identifier. |
Parameter NamehasMoreData | Data Typeboolean | DescriptionFalse for a status 200 response. True for a status 202 response, indicating that there is more data to be retrieved. Send another request and include the next parameter to get the next block of records. |
{
"name":"Nebraska Trucks",
"description":"All service trucks in Nebraska",
"hasMoreData":false,
"devices":[
{
"deviceIds":[
{
"id":"12345",
"kind":"meid"
},
{
"id":"54321",
"kind":"mdn"
}
]
},
{
"deviceIds":[
{
"id":"456789",
"kind":"meid"
},
{
"id":"987654",
"kind":"mdn"
}
]
}
]
}
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.