GET api/v2/addressbook/groups?count={count}&startIndex={startIndex}&summary={summary}

This method returns a list of all the groups stored on the customer’s account if no parameters are provided.

Request Information

URI Parameters

NameDescriptionTypeAdditional information
count

Determines how many roles to return. (Default: 20).

string

Required

startIndex

Determines where to start outputting the roles from the list returned from the database. (Default: 0).

string

Required

summary

If set to true, the response on returns basic information about groups, this has a performance advantage (Default: false).

boolean

Default value is False

Body Parameters

None.

Response Information

Resource Description

List of groups.

TwoSms.CustomerPortalRole.API.Misc.ResponseOfTwoSms.CustomerPortalRole.API.AddressBooks.GroupDetailsV2[]
NameDescriptionTypeAdditional information
Error

TwoSms.CustomerPortalRole.API.Misc.Error

None.

ResponseData

TwoSms.CustomerPortalRole.API.Misc.ResponseDataOfTwoSms.CustomerPortalRole.API.AddressBooks.GroupDetailsV2[]

None.

Response Formats

application/json, text/json

Sample:
{
  "Error": {
    "ErrorCode": "sample string 1",
    "ErrorReason": "sample string 2"
  },
  "ResponseData": {
    "Identification": {
      "UserId": "sample string 1"
    },
    "Result": "sample string 1",
    "Detail": [
      {
        "ID": "a7403d84-3cd1-4ff7-89c0-919937cae67c",
        "Name": "sample string 2",
        "DateCreated": "2024-04-18T16:00:45.7857208+00:00",
        "DateModified": "2024-04-18T16:00:45.7857208+00:00",
        "NumberOfContacts": 4,
        "NumberOfContactsWithEmails": 5,
        "NumberOfContactsWithSMS": 6,
        "LastModifiedBy": "sample string 7",
        "Inherited": true,
        "PermissionLevel": 0,
        "AccountID": "69882680-02d0-4737-b42a-b0da43e80ac9"
      },
      {
        "ID": "a7403d84-3cd1-4ff7-89c0-919937cae67c",
        "Name": "sample string 2",
        "DateCreated": "2024-04-18T16:00:45.7857208+00:00",
        "DateModified": "2024-04-18T16:00:45.7857208+00:00",
        "NumberOfContacts": 4,
        "NumberOfContactsWithEmails": 5,
        "NumberOfContactsWithSMS": 6,
        "LastModifiedBy": "sample string 7",
        "Inherited": true,
        "PermissionLevel": 0,
        "AccountID": "69882680-02d0-4737-b42a-b0da43e80ac9"
      }
    ]
  }
}

application/xml, text/xml

Sample:
<ResponseOfArrayOfGroupDetailsV2 xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <Error>
    <ErrorCode>sample string 1</ErrorCode>
    <ErrorReason>sample string 2</ErrorReason>
  </Error>
  <ResponseData>
    <Result>sample string 1</Result>
    <Identification>
      <UserId>sample string 1</UserId>
    </Identification>
    <Detail>
      <GroupDetailsV2>
        <ID>a7403d84-3cd1-4ff7-89c0-919937cae67c</ID>
        <Name>sample string 2</Name>
        <DateCreated>2024-04-18T16:00:45.7857208+00:00</DateCreated>
        <DateModified>2024-04-18T16:00:45.7857208+00:00</DateModified>
        <NumberOfContacts>4</NumberOfContacts>
        <NumberOfContactsWithEmails>5</NumberOfContactsWithEmails>
        <NumberOfContactsWithSMS>6</NumberOfContactsWithSMS>
        <LastModifiedBy>sample string 7</LastModifiedBy>
        <Inherited>true</Inherited>
        <PermissionLevel>NONE</PermissionLevel>
        <AccountID>69882680-02d0-4737-b42a-b0da43e80ac9</AccountID>
      </GroupDetailsV2>
      <GroupDetailsV2>
        <ID>a7403d84-3cd1-4ff7-89c0-919937cae67c</ID>
        <Name>sample string 2</Name>
        <DateCreated>2024-04-18T16:00:45.7857208+00:00</DateCreated>
        <DateModified>2024-04-18T16:00:45.7857208+00:00</DateModified>
        <NumberOfContacts>4</NumberOfContacts>
        <NumberOfContactsWithEmails>5</NumberOfContactsWithEmails>
        <NumberOfContactsWithSMS>6</NumberOfContactsWithSMS>
        <LastModifiedBy>sample string 7</LastModifiedBy>
        <Inherited>true</Inherited>
        <PermissionLevel>NONE</PermissionLevel>
        <AccountID>69882680-02d0-4737-b42a-b0da43e80ac9</AccountID>
      </GroupDetailsV2>
    </Detail>
  </ResponseData>
</ResponseOfArrayOfGroupDetailsV2>